1
vote
1answer
148 views

Is the Key Bindings delay unavoidable in Java when pressing different directional keys quickly?

I've read just about every tutorial I can on why to use Key Bindings instead of implementing the KeyListener interface, including all the examples that show using a field to track the key event ...
2
votes
1answer
489 views

LibGDX Scene2D event handling and bounding box relative to the center of a TextureRegion

I'm experimenting with Scene2D to see if it fits fot the game I want to develop. Say I have an Actor with the origin in the center of its TextureRegion. My setup method contains this code: float ...
4
votes
5answers
1k views

Should my game handle collisions in the Player object?

I'm making a 2D platform game. Right now I'm just working on making a very generic Player class. I'm wondering if it would be more efficient/better practice to have an ActionListener within the Player ...
7
votes
2answers
548 views

Handling commands or events that wait for an action to be completed afterwards

Say you have two events: Action1 and Action2. When you receive Action1, you want to store some arbitrary data to be used the next time Action2 rolls around. Optimally, Action1 is normally a command ...
17
votes
3answers
5k views

Polling vs event driven input

I'm developing a game using polling for the input method. However, now that I'm delving deeper into the game menus and other UI components, I'm finding that I'd probably like to have event driven ...
1
vote
2answers
501 views

Problems with Creating Snake's Clone on Java

I'm creating Snake's clone. My app have too classes: Snake.java and Board.java. Right now I have three problems: 1) There are two constants - BOARDS_WIDTH, BOARDS_HEIGHT. They are meant to be ...