コード例 #1
0
        // should find some file and load from it
        public void loadGame(GameInit gameInit, ContentHandler content, TransitionHandler transitionHandler)
        {
            transitionHandler.createRegion(gameInit, content, 0, 0);

            gameInit.getParty().addPartyMember(gameInit.getCharacterFactory().createCharacter(0, 0));

            gameInit.getParty().getPartyMembers()[0].setXPosition(50);
            gameInit.getParty().getPartyMembers()[0].setYPosition(50);
            gameInit.getParty().getPartyMembers()[0].setHeight(2);
            gameInit.getParty().getPartyMembers()[0].setFacingDirection(0);
            gameInit.getFreeRoamState().getCurrentZone().addCharacter(gameInit.getParty().getPartyMembers()[0], 50, 50);
            gameInit.getMessageBlockFactory().createRegionCharacterBlocks(0);
            gameInit.getGameState().setFreeRoamState();
        }
コード例 #2
0
ファイル: LogicHandler.cs プロジェクト: rpallarino3/Tactics
 public void updateLogic(GameInit gameInit, KeyHandler keyHandler, ContentHandler content)
 {
     if (gameInit.getGameState().getState() == gameInit.getGameState().START_STATE)
     {
         updateStartLogic(gameInit, keyHandler, content);
     }
     else if (gameInit.getGameState().getState() == gameInit.getGameState().FREE_ROAM_STATE)
     {
         updateFreeRoamLogic(gameInit, keyHandler, content);
     }
     else if (gameInit.getGameState().getState() == gameInit.getGameState().BATTLE_STATE)
     {
         updateBattleLogic(gameInit, keyHandler, content);
     }
     else if (gameInit.getGameState().getState() == gameInit.getGameState().PAUSE_STATE)
     {
     }
 }
コード例 #3
0
ファイル: PaintHandler.cs プロジェクト: rpallarino3/Tactics
 public void draw(SpriteBatch spriteBatch, GameInit gameInit, ContentHandler contentHandler, Color color)
 {
     if (gameInit.getGameState().getState() == gameInit.getGameState().START_STATE)
     {
         drawStartState(spriteBatch, gameInit, contentHandler, color);
     }
     else if (gameInit.getGameState().getState() == gameInit.getGameState().FREE_ROAM_STATE)
     {
         drawFreeRoamState(spriteBatch, gameInit, contentHandler, color);
     }
     else if (gameInit.getGameState().getState() == gameInit.getGameState().BATTLE_STATE)
     {
         drawBattleState(spriteBatch, gameInit, contentHandler, color);
     }
     else if (gameInit.getGameState().getState() == gameInit.getGameState().PAUSE_STATE)
     {
         drawPauseState(spriteBatch, gameInit, contentHandler, color);
     }
 }