public Mediator_Player_Controls(Controls c_, H_Player p_) { p_avatar = p_; c_input = c_; shooter = Shoot_State.CHILL; jumper = Jump_State.ON_GROUND; AirTime = new Stopwatch(); AirTime.Reset(); AirTime.Stop(); cur_structure = 0; structure_wheel.Add(Structure_Type_e.HEALING_POOL); structure_wheel.Add(Structure_Type_e.SNOW_FACTORY); structure_wheel.Add(Structure_Type_e.FORT); structure_wheel.Add(Structure_Type_e.SNOWMAN); }
private void Handle_Shooting_State() { //Player functions to implement -- ChargeBall,ShootBall //SO need to have each state and act on it just like in the old player switch (shooter) { case Shoot_State.CHILL: if (c_input.State.shoot) shooter = Shoot_State.CHARGING; break; case Shoot_State.CHARGING: p_avatar.charge_ball(); if (!c_input.State.shoot) shooter = Shoot_State.FIRE; break; case Shoot_State.FIRE: p_avatar.throw_ball(); shooter = Shoot_State.CHILL; break; default: shooter = Shoot_State.CHILL; break; } }