Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

81
Vistas
Reading the javascript object

I'm trying to write a script for an auto bet (bustabit.com)

they have a manual about this on github

I want to read the "bust" object in the engine.history for writing an if statement

but I have no idea how javascript objects work ( i have not any experience in programming much )

I tried this but it's not working

if (engine.history(game.bust)=1.37){log("bust is 1.37")};

can someone help?

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

The equal character is for assignment.

You should use == for equality checks read this

if (engine.history(game.bust)==1.37){log("bust is 1.37")};

Then

history(game.bust) means that history is a function which is taking a param which is is the value of the property bust inside the game object

Reading what are you sharing history has a method in it, which is going to cast the history to an array.

engine.history.toArray()

After that you can use array methods in order to find the history item you are looking for, for instance

const engineHistory = engine.history.toArray()
const element = engineHistory.find(historyItem => historyItem.bust == 1.37)
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda