I wanted my character's life to be the same as the other game state. My other game state is different the from my original state. I wanted to link my int to my new game state to make it the same. How do I link an integer?
Tell me more
×
Game Development Stack Exchange is a question and answer site for
professional and independent game developers. It's 100% free, no registration required.
|
closed as not a real question by Jari Komppa, Jonathan Hobbs, michael.bartnett, Byte56, Josh Petrie Oct 16 '12 at 16:05
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, see the FAQ.
|
If you're using FX you could try using a SimpleIntegerProperty and then bind that to another one. This will cause any change in one to reflect a change in the other. It works well for counting how many frames have been run in my game. My engine class has an int bound to an int in my ui class and it works well. Does that sound like what you're trying to achieve? |
|||
|
|
|
You link to the other game state object, not to the integer directly. Then just |
|||
|
|