[Question] How to wait some seconds
-
@arabian
Here are some examples, each one is good for different use case.onEnable: mc.thePlayer.motionY = 1; timeout(1000, function () { mc.thePlayer.motionY = 0 }); onUpdate: if (timer.hasTimePassed(1000)) { timer.reset(); mc.thePlayer.motionY = 0; } timer = new MSTimer(); onEnable: ticks = 0 onUpdate: ticks++ if (ticks > 20) { mc.thePlayer.motionY = 0 }
(timeout and MSTimer aren't imported without Core)
You should just look at some scripts to see how to delay code.