Follow

gamedev 

Decided to organize my power up states into classes (state pattern). Seems to be a lot better than using switch statements everywhere. Design patterns are really useful, despite what the anti-OOP crowd may say.

· · Web · 1 · 0 · 2

gamedev 

Okay, maybe using the state pattern for power-up states wasn't good idea. I had to reconfigure a lot of code and since power-ups carry over levels, I had to assign the power-up state to the Game1 class and reference the player in each level. What a mess!

gamedev 

I still think the state design pattern is useful. I guess I went a little too overboard.

Sign in to participate in the conversation
Game Liberty Mastodon

Mainly gaming/nerd instance for people who value free speech. Everyone is welcome.