Ejemplo n.º 1
0
    protected override void InitAwake()
    {
        base.InitAwake();
        if (player == null)
        {
            player = transform;
        }

        moveControl = GetComponent <CharacterMoveControl>();

        instance = this;

        if (aniControl == null)
        {
            aniControl = GetComponentInChildren <CharacterAnimationControl>();
        }

        if (aniControl != null)
        {
            aniControl.Weapon = Weapon;
        }
        else
        {
            Debug.Log("[IcarusPlayerController][InitAwake]: CharacterAnimationControl is null!");
        }
    }
Ejemplo n.º 2
0
    void Start()
    {
        moveControl = GetComponent <CharacterMoveControl>();

        if (listCheckPoints.Count != 0)
        {
            for (int i = 0; i < listCheckPoints.Count; i++)
            {
                if (listCheckPoints[i] == null)
                {
                    listCheckPoints.Clear();
                    GameObject gobj = new GameObject();
                    gobj.transform.position = transform.position;
                    gobj.transform.rotation = transform.rotation;
                    listCheckPoints.Add(gobj.transform);
                    break;
                }
            }
        }
    }
Ejemplo n.º 3
0
 // Use this for initialization
 void Start()
 {
     playerMoveControl = IcarusPlayerController.player.GetComponent <CharacterMoveControl>();
 }