Disable switch and bubblegum for now in network

This commit is contained in:
Benau 2018-08-03 01:28:20 +08:00
parent 0a95900283
commit 8b07ec755a

View File

@ -32,6 +32,7 @@
#include "karts/controller/controller.hpp"
#include "karts/kart_properties.hpp"
#include "modes/world.hpp"
#include "network/network_config.hpp"
#include "network/rewind_manager.hpp"
#include "physics/triangle_mesh.hpp"
#include "tracks/track.hpp"
@ -567,6 +568,11 @@ void Powerup::hitBonusBox(const ItemState &item_state)
new_powerup = powerup_manager->getRandomPowerup(position, &n,
random_number);
// FIXME Disable switch and bubblegum for now in network
if (NetworkConfig::get()->isNetworking() &&
(new_powerup == PowerupManager::POWERUP_BUBBLEGUM ||
new_powerup == PowerupManager::POWERUP_SWITCH))
new_powerup = PowerupManager::POWERUP_BOWLING;
// Always add a new powerup in ITEM_MODE_NEW (or if the kart
// doesn't have a powerup atm).