Ejemplo n.º 1
0
            } // end NoviceVillage

            public void Initialize() {
                m_mainCanvas = new MainCanvas();
                m_mainAudio = new MainAudio();
                m_mainCamera = new MainCamera();
                ObjectTool.InstantiateGo("npc_transmitter", ResourcesTool.LoadPrefab("npc_transmitter"),
                    null, new UnityEngine.Vector3(0, 0, 10), new UnityEngine.Vector3(0, 270, 0), UnityEngine.Vector3.one).AddComponent<NPC_Transmitter2>();
                m_characterManager.factory.CreateMainCharacter(new UnityEngine.Vector3(0, 0, 0));
                m_characterManager.factory.CreateNPC("901001", new UnityEngine.Vector3(20, 0, 0));
                m_characterManager.factory.CreateNPC("902001", new UnityEngine.Vector3(20, 0, 10));
                m_characterManager.factory.CreateNPC("903001", new UnityEngine.Vector3(20, 0, 20));
                m_characterManager.factory.CreateNPC("904001", new UnityEngine.Vector3(10, 0, 20));
                m_characterManager.factory.CreateNPC("904002", new UnityEngine.Vector3(0, 0, 20));
                m_characterManager.factory.CreateNPC("904003", new UnityEngine.Vector3(-10, 0, 20));
                m_characterManager.factory.CreateNPC("904004", new UnityEngine.Vector3(-20, 0, 20));
                m_characterManager.factory.CreateNPC("904005", new UnityEngine.Vector3(-20, 0, 10));
                m_characterManager.factory.CreateNPC("904006", new UnityEngine.Vector3(-20, 0, 0));
                m_characterManager.factory.CreateNPC("904007", new UnityEngine.Vector3(-20, 0, -10));
                m_characterManager.factory.CreateNPC("904008", new UnityEngine.Vector3(-20, 0, -20));
                m_characterManager.factory.CreateNPC("904009", new UnityEngine.Vector3(-10, 0, -20));
                m_characterManager.factory.CreateNPC("904010", new UnityEngine.Vector3(0, 0, -20));
                m_characterManager.factory.CreateNPC("905001", new UnityEngine.Vector3(10, 0, -20));
                m_characterManager.factory.CreateNPC("905002", new UnityEngine.Vector3(20, 0, -20));
                m_characterManager.factory.CreateNPC("905003", new UnityEngine.Vector3(20, 0, -10));
                m_characterManager.factory.CreateNPC("906001", new UnityEngine.Vector3(30, 0, 0));
                m_characterManager.factory.CreateNPC("906002", new UnityEngine.Vector3(0, 0, 30));
                m_characterManager.factory.CreateNPC("906003", new UnityEngine.Vector3(-30, 0, 0));
                m_mainAudio.PlayBackgroundMusic("fight_scene_bgm");
                if (null == mainCharacter) {
                    DebugTool.LogError("NoviceVillage CreateMainCharacter is null!!");
                    return;
                } // end if
                m_mainCamera.SetTarget(mainCharacter);
                mainCharacter.fsm.PerformTransition("wait");
                uiPanelFSM.PerformTransition(new UIFightPanel());
            } // end Initialize
Ejemplo n.º 2
0
            } // end SelectRoleScene

            public void Initialize() {
                m_mainAudio = new MainAudio();
                m_mainCanvas = new MainCanvas();
                m_mainCamera = new MainCamera();
                m_mainAudio.PlayBackgroundMusic("select_role_scene_bgm");
                uiPanelFSM.PerformTransition(new UISelectRolePanel());
            } // end Initialize
Ejemplo n.º 3
0
            } // end LoginScene

            public void Initialize() {
                m_mainAudio = new MainAudio();
                m_mainCanvas = new MainCanvas();
                m_mainCamera = new MainCamera();
                m_mainAudio.PlayBackgroundMusic("login_scene_bgm");
                gameObject = ObjectTool.InstantiateGo("LoginSceneBg", ResourcesTool.LoadPrefabUI("login_scene_bg"), 
                    null, new Vector3(0, 0, 5.1f), Vector3.zero, Vector3.one);
                uiPanelFSM.PerformTransition(new UILoginPanel());
            } // end Initialize
Ejemplo n.º 4
0
            } // end NoviceVillage

            public void Initialize() {
                m_mainAudio = new MainAudio();
                m_mainCanvas = new MainCanvas();
                m_mainCamera = new MainCamera();
                m_characterManager.factory.CreateMainCharacter(new Vector3(0, 0, -20));
                m_mainAudio.PlayBackgroundMusic("novice_village_bgm");
                if (null == mainCharacter) {
                    DebugTool.LogError("NoviceVillage CreateMainCharacter is null!!");
                    return;
                } // end if
                ObjectTool.InstantiateGo("npc_grocery", ResourcesTool.LoadPrefab("npc_grocery"),
                    null, new Vector3(24, 0, 3), new Vector3(0, 210, 0), Vector3.one).AddComponent<NPC_Grocery>();
                ObjectTool.InstantiateGo("npc_forge", ResourcesTool.LoadPrefab("npc_forge"),
                    null, new Vector3(-5, 0, 2), new Vector3(0, 160, 0), Vector3.one).AddComponent<NPC_Forge>();
                ObjectTool.InstantiateGo("npc_transmitter", ResourcesTool.LoadPrefab("npc_transmitter"),
                    null, new Vector3(17, 0, -24), new Vector3(0, 270, 0), Vector3.one).AddComponent<NPC_Transmitter>();
                m_mainCamera.SetTarget(mainCharacter);
                mainCharacter.fsm.PerformTransition("idle");
                uiPanelFSM.PerformTransition(new UITownPanel());
            } // end Initialize