Exemplo n.º 1
0
        public static GameObject CreateCharacter(string name, Vector3 pos, Quaternion quat)
        {
            if (Instance == null)
            {
                Instance = Resources.Load <L_CharacterData>("SerializeableData/CharacterData");
            }
            GameObject prefab = Instance.GetCharacterPrefab(name) as GameObject;

            if (prefab == null)
            {
                return(null);
            }
            return(GameObject.Instantiate(prefab, pos, quat) as GameObject);
        }
Exemplo n.º 2
0
        public override void OnStart()
        {
            L_Actor_Door door = L_ActorManager.It.ActorRoot.GetComponentInChildren <L_Actor_Door>();

            L_CharacterData.CreateCharacter(0, door.EnterTran.position, door.EnterTran.rotation);
        }