- public final class EntitiesInterpolate extends Command<StateEntities> {
- private final float alpha;
- public EntitiesInterpolate(final float alpha) {
- super(StateEntities.class);
- this.alpha = alpha;
- }
- @Override
- public void execute(StateEntities listener) {
- listener.interpolate(alpha);
- }
- }
- //Nope
- currentState.execute(new EntitiesInterpolate(accumulatedTime / SECONDS_PER_FRAME));
- public final void execute(Command<StateComponent> command) {
- if (hasComponent(command.getListeningClass())) {
- for (StateComponent component : components) {
- if (command.getListeningClass().isInstance(component)) {
- command.execute(component);
- }
- }
- }
- }
- public final class StateEntities extends StateComponent {}
SHARE
TWEET
Untitled
a guest
Oct 10th, 2015
105
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy.

