public void SetEnvironment(EnvironmentType lastEnvironmentType, EnvironmentType activeEnvironmentType) { PowerUp.Action(); player.GetComponent <PlayerController>().SetState(activeEnvironmentType); if (lastEnvironmentType != activeEnvironmentType) { SetMap(lastEnvironmentType, activeEnvironmentType); } }