Back to project page SevenWonders.
The source code is released under:
Apache License
If you think the Android project SevenWonders listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
/** * /*from w ww .java 2 s. com*/ */ package skylight1.sevenwonders.levels; import skylight1.sevenwonders.services.SoundTracks; import skylight1.sevenwonders.view.GameMessagesDisplay; import skylight1.sevenwonders.view.SevenWondersGLRenderer; import skylight1.sevenwonders.view.GameMessagesDisplay.GameEvent; import android.os.Handler; final class RubyCollisionAction implements CollisionAction { private static final int TIME_ABLE_TO_PASS_THROUGH_SOLID_MILLIS = 30000; @Override public void collision(Handler aUiHandler, SevenWondersGLRenderer aSevenWondersGLRenderer) { // TODO add a different sound here SoundTracks.getInstance().play(SoundTracks.SPELL); // TODO have a level with a story title that explains this. // e.g. "An ankh is hidden within a pyramid! Find the magic red ruby to fly through its walls!" // TODO some sort of UI indicator as well. ruby icon on screen, dialog message, etc. aSevenWondersGLRenderer.getGameState().setRemainingPassThroughObstaclesTimeMillis(TIME_ABLE_TO_PASS_THROUGH_SOLID_MILLIS); GameMessagesDisplay.postMessage(GameEvent.RUBY_FOUND); } }