Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

262
Views
¿Cómo hacer que discord bot calcule con javascript?

Soy nuevo en esto, estoy buscando un comando matemático simple en discord.js. Estoy construyendo un bot simple para mí. Quiero que calcule una tarea simple como: Some Call! Calc 35.5 768.99 666566.3 y el bot calcula el primer Num1 con número preestablecido como !Calc 10.5 21 30.5 y responderá 10.5x3 ---> 31.5 , 21x10 ---> 210 , 30.5/3 ---> 10.16666666 el número preestablecido es *3 *10 y /3 ... I Ya estoy ejecutando un bot con la configuración básica que responde en !ping, etc. ¡Gracias de antemano!

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Puede intentar usar mathjs, puede descargarlo con nodejs. Por npm install maths en su terminal.

Puede consultar la documentación aquí.

Aquí está la plantilla que hice en referencia a mathjs.

 const math = require('mathjs'); client.on('messageCreate', (message) => { let Equation = message.content.substring(message.content.indexOf(" ")).slice(1); let resp = math.evaluate(Equation); })
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!