
-----------------------------------
Luffy123
Sun May 13, 2012 2:50 pm

how to use hasch?
-----------------------------------
So my program it needs to draw a heart and then when hasch it needs to continue and then erase the heart. So this is what I got so far.

heartObj -> draw
loop
    delay (100)
    exit when hasch
end loop
heartObj -> erase

Now my question is. Do I need to loop?

is there a way I can just wait until hasch to move on? or do i need to use a loop?

-----------------------------------
Amarylis
Sun May 13, 2012 3:04 pm

RE:how to use hasch?
-----------------------------------
you dont need that delay there...


What hasch does is that it checks to see if a key (any key) has been pressed. It'll return as true if there was a key pressed, and false otherwise (hence why you can use it on the exit when statement).

If your objective is to just wait until they have pressed something, then yes, just loop and exit when hasch

-----------------------------------
Raknarg
Sun May 13, 2012 6:08 pm

RE:how to use hasch?
-----------------------------------
Or use Input.Pause, no loop is needed
