void OnTriggerExit2D(Collider2D other) { if (other.tag == "fire") { print("regain"); moveFire fireStats = other.GetComponent <moveFire> (); fireStats.fireSpeed = fireStats.fireSpeed * 2; } }
void OnTriggerExit2D(Collider2D other) { if (other.tag == "fire") { moveFire firebar = other.GetComponent <moveFire> (); firebar.fireSpeed /= 2.5f; //firebar. } }
void OnTriggerEnter2D(Collider2D other) { if (other.tag == "fire") { print("slow"); moveFire fireStats = other.GetComponent <moveFire> (); fireStats.fireSpeed = fireStats.fireSpeed / 2; } }
void OnCollisionEnter2D(Collision2D coll) { if (coll.gameObject.tag == "fire") { if (heldByPlayer) { putWoodDown(); } moveFire firebar = coll.gameObject.GetComponent <moveFire> (); firebar.stopped = true; firebar.flickAnim.pauseFlicker = true; StartCoroutine("BurnWood"); } }