private void Start() { player_behaviour = new Player_Behaviour(); num_jellies = player_behaviour.jellybeancounter; movement_state = Random.Range(0, pointers.Length); waitTime = startWaitTime; }
public void StartPlayerTurn(Player_Behaviour player) { for (int i = 0; i < player.myUnits.Count; i++) { player.myUnits[i].exhausted = false; } if (clearHandAtTurnStart) { while (player.cardsInHand.Count > 0) { player.myHand.RemoveCardFromHand(player.myHand.cardObjects[0]); } } if (drawFullHandAtTurnStart) { while (player.cardsInHand.Count < handSize) { player.DrawCard(); } } else { player.DrawCard(); } }
//public AudioClip soundFile; //public float soundvolume; //AudioSource audio; // Use this for initialization void Start() { //audio = GetComponent<AudioSource>(); target = GameObject.FindWithTag("Player").GetComponent <Transform>(); anim = GetComponent <Animator>(); player = GameObject.FindWithTag("Player").GetComponent <Player_Behaviour>(); }
private void Awake() { enemyController = GameObject.FindWithTag("EnemyController").GetComponent <EnemyController>(); crowdController = GameObject.FindWithTag("CrowdController").GetComponent <crowdManager>(); player = GameObject.FindWithTag("Player").GetComponent <Player_Behaviour>(); startButton = GameObject.Find("Start"); resumeButton = GameObject.Find("Resume"); difficultySelector = GameObject.Find("DifficultySelector"); resumeButton.SetActive(false); difficultySelector.SetActive(false); }
void refreshStatus() { bool dancing = danceStarted || dancefinished; danceCamera.SetActive(dancing); mainCamera.SetActive(!dancing); if (currentFinishedDance) { player.GetComponent <Animator>().SetBool(currentFinishedDance.DanceName, dancefinished); } Player_Behaviour lBehaviour = player.GetComponent <Player_Behaviour>(); lBehaviour.dancing = dancing; lBehaviour.distanceWeapon.SetActive(!dancing); lBehaviour.meleeWeapon.SetActive(!dancing); if (enterDanceModeUI != null) { enterDanceModeUI.SetActive(!dancing); } if (danceUIContainer != null) { danceUIContainer.SetActive(dancing); } if (!dancing) { player.GetComponent <ParticleSystem>().Stop(); } if (!dancefinished) { currentFinishedDance = null; } }
private Vector3 smoothedPos; //The end result of the camerapositioning after smoothing private void Awake() //Get component on object { player = FindObjectOfType <Player_Behaviour>(); }
// Use this for initialization void Start() { player = GameObject.FindWithTag("Player").GetComponent <Player_Behaviour>(); }
// Use this for initialization void Start() { target = GameObject.FindWithTag("Player").transform; player = GameObject.FindWithTag("Player").GetComponent <Player_Behaviour>(); }