This should be an easy answer. (keyword: should)
For my current project, I would like to do an action depending on the Linear Velocity of an object. I am using
var howfast = object.physicsImpostor.getLinearVelocity(); console.log(howfast); so I can see how fast it is going.
Is there any way to use an if-else statement with the variable howfast? Like
if (howfast > 9001) console.log("It's over nine thousand!"); Pardon the dead meme.
Thanks for any help!