comp380team3 / PuzzlePathDimension

Class project for COMP 380 at California State University, Northridge
0 stars 0 forks source link

Game crash when Confirm pressed repeatedly after level selection #97

Closed bmarroquin closed 11 years ago

bmarroquin commented 11 years ago

Spam the confirm button to crash the game from the level select screen. Crashes when trying to leave editor mode. Can you guys recreate this?

Cause: Tries to launch GameplayScreen before editableLevel has been initialized

Not sure if there should be a better way of handling it but I am just going to exit the method if editable level is still null.

Jjp137 commented 11 years ago

That's odd. Maybe I'll look into a better way of fixing this bug tomorrow, but that band-aid should work for now.

(For the record, yes I'm able to reproduce this.)

Twisol commented 11 years ago

Great find! I just took a look, and I know exactly why this is happening. Doofus me decided to hook up the input events in the GameScreen constructor, instead of in LoadContent. That meant that the GameEditorScreen was listening for input before it had been properly set up! I'll push a fix shortly.

Twisol commented 11 years ago

Fixed in e569f2c.