realbasic-games
[Top] [All Lists]

Re: Key Presses on a Sprite Surface

To: REALbasic Games <realbasic-games at lists dot realsoftware dot com>
Subject: Re: Key Presses on a Sprite Surface
From: Floyd Resler <macmage at maccrafters dot com>
Date: Tue, 20 Dec 2005 10:58:11 -0500
Delivered-to: realbasic-games at lists dot realsoftware dot com
References: <C5E84E6A-C8A7-4EB6-B070-3E4A16F9C284 at maccrafters dot com> <A197B22C-017A-4692-9D80-9494FD5396D2 at freaksw dot com>
That's the method I use. However, when the right arrow key is being held down, it doesn't seem to recognize the spacebar. But, I think I just realized what I'm doing wrong. I use a FOR/NEXT loop to find out which key is being pressed and then a SELECT CASE to act on it. The FOR/NEXT loop is outside the SELECT CASE. I bet if I move the SELECT CASE inside the FOR/NEXT loop, it will probably work.

Thanks!
Floyd

On Dec 19, 2005, at 9:31 PM, Seth Willits wrote:

On Dec 19, 2005, at 5:35 PM, Floyd Resler wrote:

How can I determine when more than one key is being pressed. For example, the right arrow key is being held down and then the spacebar is pressed.

Use the SpriteSurface.KeyTest method, to ask if a specific key is down.

-- Seth
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


<Prev in Thread] Current Thread [Next in Thread>