
-----------------------------------
fear01
Tue Nov 22, 2005 5:47 pm

Pause and Continueing a Game
-----------------------------------
I have just started using turing this semester and was wondering how I could pause game motion and then continue it with two different keys. I am using the Input.Keydown command and using the keys "p" and "c" to do it, uh could anyone help out a newbie with this problem? I have tried using commands like delay and pause, but no luck. Any help would be great. Thanks.

-----------------------------------
Mystify
Tue Nov 22, 2005 5:51 pm


-----------------------------------
Are you trying to pause the whole thing or just something like a timer?

-----------------------------------
person
Tue Nov 22, 2005 6:06 pm


-----------------------------------

var chars : array char of boolean
loop
    Input.KeyDown (chars)
    if chars ('p') then
        loop
            Input.KeyDown (chars)
            drawfilloval (Rand.Int (1, 1000), Rand.Int (1, 1000), 3, 3, 1)
            exit when chars ('c')
        end loop
    end if
end loop


-----------------------------------
Mystify
Tue Nov 22, 2005 6:12 pm


-----------------------------------
There you go  :D

-----------------------------------
fear01
Tue Nov 22, 2005 9:07 pm


-----------------------------------
Thank you Mystify, it worked and I'm done! Now i have time to do nothing. I would hug you but your there and i'm here, so just a simple text of "thank you".

-----------------------------------
fear01
Tue Nov 22, 2005 9:13 pm


-----------------------------------
Ack! Sorry, i glanced at the code and didn't see the author, i would like to thank you too, uh "person". "HUGS" and "KISSES"!!!

-----------------------------------
The_Triangle
Thu Nov 24, 2005 4:15 pm


-----------------------------------
Ack! Sorry, i glanced at the code and didn't see the author, i would like to thank you too, uh "person". "HUGS" and "KISSES"!!!

watch yerself there bud


uh anyone know what the char of boolean for spacebar is ?

i tried KEY_SPACE, didnt do much.

-----------------------------------
person
Thu Nov 24, 2005 7:00 pm


-----------------------------------
32

-----------------------------------
GlobeTrotter
Thu Nov 24, 2005 7:15 pm


-----------------------------------
Ack! Sorry, i glanced at the code and didn't see the author, i would like to thank you too, uh "person". "HUGS" and "KISSES"!!!

watch yerself there bud


uh anyone know what the char of boolean for spacebar is ?

i tried KEY_SPACE, didnt do much.

(' ')

should do it.  Similarly, for a letter it's
('a')
('z')

-----------------------------------
codemage
Fri Nov 25, 2005 9:03 am


-----------------------------------
If you need to know what the code for a specific key is, run KeyDown1.t in the examples/fun directory of Turing.

-----------------------------------
r0ssar00
Fri Nov 25, 2005 2:48 pm


-----------------------------------
you could also look up an ascii table on the inet, theres so many, and i just find the one at the top of search results the most useful.  turing uses this table, so just save it to your desktop or something. its invaluable to have.

-----------------------------------
person
Fri Nov 25, 2005 6:52 pm


-----------------------------------
32

i already posted the chr
