I am trying to implement a tetris-like game where one object is falling down and it can fall into one out of three baskets. A life is lost if the object falls into the wrong basket.
I use the this.scheduleUpdate() function to simulate the fall of the object(Translate down by 0.6 basically) and to track when the object has fallen into the wrong basket in which event I immediately call this.scheduleOnce(this.score) The problem is that though only one life must be deducted on each call of this.score(), the deduction is erratic across different computers. On old machines, all lives are deducted at once, on some machines 2 lives are deducted at once and so on. Why's this? How can I fix the problem?