[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Problems with events and keys



I'll fix the timer thing after I figure this out:

In my code, it accepts any keystroke. How do I make it so that the textsprite class only accepts letters, numbers and numberpad input? I know there's a way to do that but I forgot how... Does anybody know what python doc that is in?

On 2/7/07, Charles Christie <sonicbhoc@xxxxxxxxx> wrote:
Uh.... Good question. :P Time to go look at the documentation again!
But I'll do that tomorrow, it's getting kinda late.

On 2/7/07, Lenard Lindstrom <len-l@xxxxxxxxx > wrote:
> Charles Christie wrote:
> >
> > The next thing is events. I haven't checked if the program acts
> > properly if the event GAME_OVER_W is sent after you type everything
> > because I never bothered to finish typing my cue - I am too busy now
> > trying to figure out why SUBTRACT_TIMER (which I should probably
> > rename COUNTDOWN later) won't work with the timer I set. I never had
> > luck with global variables before anyway.
> >
>
> Check your assumptions. When does the timer start?
>
> --
> Lenard Lindstrom
> < len-l@xxxxxxxxx>
>
>
>
>
>