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

Re: [pygame] Not Quiting



By code I mean any program that works otherwise, by it crashes I mean I have to quit using the taskmanager and endtask, and by how I quit I mean

keystate = pygame.key.get_pressed()
for event in pygame.event.get():
  if event.type == pygame.QUIT or keystate[K_ESCAPE]: 
    sys.exit()

On 6/30/07, Luke Paireepinart < rabidpoobear@xxxxxxxxx> wrote:
Ian Mallett wrote:
> I see the ================RESTART================== thing but it still
> crashes when I try to quit.
What code are you running, and what do you mean by 'it crashes,' and how
are you trying to quit?
-Luke
>
> On 6/30/07, *Luke Paireepinart* < rabidpoobear@xxxxxxxxx
> <mailto:rabidpoobear@xxxxxxxxx>> wrote:
>
>     Ian Mallett wrote:
>     > So what you're saying is run IDLE separately from my program (don't
>     > click on "Edit With IDLE") and doing something.  I don't know
>     what you
>     > mean- cutting and pasting the program into it?  It can't be
>     hitting F5
>     > because that opens a new IDLE window.  What DO you
>     mean?  Anyway, that
>     > seems harder than just running the program by clicking on its file
>     > (i.e. double click " program.py").
>     You open code in IDLE just like you open text documents in every GUI
>     text editor you've ever used.
>     You click on File and then Load, then you browse to the directory of
>     where your file is, and double click it.
>
>     Once your code is loaded, you can hit F5 to execute it.
>     No, this is not slower, because you do this _once_ when you start
>     editing your program, and from then on , you just execute the code
>     with F5.
>     The only difference than how you're doing it now is that you start
>     IDLE
>     without the right-click.
>     Once you're in IDLE, it works the same as before.
>     You don't have to reload the code every time you want to run it, you
>     just hit F5.
>     -Luke
>
>