forked from rosebudai/OpenRCT2-Web
Rename members of GameCommand
This commit is contained in:
89 files changed
+344
-344
No files matched your search
@@ -105,14 +105,14 @@ namespace OpenRCT2::GameActions
|
||||
const char* name{};
|
||||
};
|
||||
|
||||
using GameActionRegistry = std::array<GameActionEntry, EnumValue(GameCommand::Count)>;
|
||||
using GameActionRegistry = std::array<GameActionEntry, EnumValue(GameCommand::count)>;
|
||||
|
||||
template<GameCommand TId>
|
||||
static constexpr void Register(GameActionRegistry& registry, GameActionFactory factory, const char* name)
|
||||
{
|
||||
constexpr auto idx = static_cast<size_t>(TId);
|
||||
|
||||
static_assert(idx < EnumValue(GameCommand::Count));
|
||||
static_assert(idx < EnumValue(GameCommand::count));
|
||||
|
||||
registry[idx] = { factory, name };
|
||||
}
|
||||
|
||||
@@ -122,10 +122,10 @@ namespace OpenRCT2::GameActions
|
||||
// Remove ghost scenery so it doesn't interfere with incoming network command
|
||||
switch (queued.action->GetType())
|
||||
{
|
||||
case GameCommand::PlaceWall:
|
||||
case GameCommand::PlaceLargeScenery:
|
||||
case GameCommand::PlaceBanner:
|
||||
case GameCommand::PlaceScenery:
|
||||
case GameCommand::placeWall:
|
||||
case GameCommand::placeLargeScenery:
|
||||
case GameCommand::placeBanner:
|
||||
case GameCommand::placeScenery:
|
||||
SceneryRemoveGhostToolPlacement();
|
||||
break;
|
||||
default:
|
||||
|
||||
@@ -15,91 +15,91 @@ namespace OpenRCT2
|
||||
{
|
||||
enum class GameCommand : int32_t
|
||||
{
|
||||
SetRideAppearance,
|
||||
SetLandHeight,
|
||||
TogglePause,
|
||||
PlaceTrack,
|
||||
RemoveTrack,
|
||||
LoadOrQuit,
|
||||
CreateRide,
|
||||
DemolishRide,
|
||||
SetRideStatus,
|
||||
SetRideVehicles,
|
||||
SetRideName,
|
||||
SetRideSetting,
|
||||
PlaceRideEntranceOrExit,
|
||||
RemoveRideEntranceOrExit,
|
||||
RemoveScenery,
|
||||
PlaceScenery,
|
||||
SetWaterHeight,
|
||||
PlacePath,
|
||||
PlacePathLayout,
|
||||
RemovePath,
|
||||
ChangeSurfaceStyle,
|
||||
SetRidePrice,
|
||||
SetGuestName,
|
||||
SetStaffName,
|
||||
RaiseLand,
|
||||
LowerLand,
|
||||
EditLandSmooth,
|
||||
RaiseWater,
|
||||
LowerWater,
|
||||
SetBrakesSpeed,
|
||||
HireNewStaffMember,
|
||||
SetStaffPatrol,
|
||||
FireStaffMember,
|
||||
SetStaffOrders,
|
||||
SetParkName,
|
||||
SetParkOpen,
|
||||
BuyLandRights,
|
||||
PlaceParkEntrance,
|
||||
RemoveParkEntrance,
|
||||
SetMazeTrack,
|
||||
SetParkEntranceFee,
|
||||
SetStaffColour,
|
||||
PlaceWall,
|
||||
RemoveWall,
|
||||
PlaceLargeScenery,
|
||||
RemoveLargeScenery,
|
||||
SetCurrentLoan,
|
||||
SetResearchFunding,
|
||||
PlaceTrackDesign,
|
||||
StartMarketingCampaign,
|
||||
PlaceMazeDesign,
|
||||
PlaceBanner,
|
||||
RemoveBanner,
|
||||
SetSceneryColour,
|
||||
SetWallColour,
|
||||
SetLargeSceneryColour,
|
||||
SetBannerColour,
|
||||
SetLandOwnership,
|
||||
ClearScenery,
|
||||
SetBannerName,
|
||||
SetSignName,
|
||||
SetBannerStyle,
|
||||
SetSignStyle,
|
||||
SetPlayerGroup,
|
||||
ModifyGroups,
|
||||
KickPlayer,
|
||||
Cheat,
|
||||
PickupGuest,
|
||||
PickupStaff,
|
||||
BalloonPress,
|
||||
ModifyTile,
|
||||
EditScenarioOptions,
|
||||
PlacePeepSpawn,
|
||||
SetColourScheme,
|
||||
SetStaffCostume,
|
||||
PlaceFootpathAddition,
|
||||
RemoveFootpathAddition,
|
||||
GuestSetFlags,
|
||||
SetDate,
|
||||
Custom,
|
||||
ChangeMapSize,
|
||||
FreezeRideRating,
|
||||
SetGameSpeed,
|
||||
SetRestrictedScenery,
|
||||
setRideAppearance,
|
||||
setLandHeight,
|
||||
togglePause,
|
||||
placeTrack,
|
||||
removeTrack,
|
||||
loadOrQuit,
|
||||
createRide,
|
||||
demolishRide,
|
||||
setRideStatus,
|
||||
setRideVehicles,
|
||||
setRideName,
|
||||
setRideSetting,
|
||||
placeRideEntranceOrExit,
|
||||
removeRideEntranceOrExit,
|
||||
removeScenery,
|
||||
placeScenery,
|
||||
setWaterHeight,
|
||||
placePath,
|
||||
placePathLayout,
|
||||
removePath,
|
||||
changeSurfaceStyle,
|
||||
setRidePrice,
|
||||
setGuestName,
|
||||
setStaffName,
|
||||
raiseLand,
|
||||
lowerLand,
|
||||
editLandSmooth,
|
||||
raiseWater,
|
||||
lowerWater,
|
||||
setBrakesSpeed,
|
||||
hireNewStaffMember,
|
||||
setStaffPatrol,
|
||||
fireStaffMember,
|
||||
setStaffOrders,
|
||||
setParkName,
|
||||
setParkOpen,
|
||||
buyLandRights,
|
||||
placeParkEntrance,
|
||||
removeParkEntrance,
|
||||
setMazeTrack,
|
||||
setParkEntranceFee,
|
||||
setStaffColour,
|
||||
placeWall,
|
||||
removeWall,
|
||||
placeLargeScenery,
|
||||
removeLargeScenery,
|
||||
setCurrentLoan,
|
||||
setResearchFunding,
|
||||
placeTrackDesign,
|
||||
startMarketingCampaign,
|
||||
placeMazeDesign,
|
||||
placeBanner,
|
||||
removeBanner,
|
||||
setSceneryColour,
|
||||
setWallColour,
|
||||
setLargeSceneryColour,
|
||||
setBannerColour,
|
||||
setLandOwnership,
|
||||
clearScenery,
|
||||
setBannerName,
|
||||
setSignName,
|
||||
setBannerStyle,
|
||||
setSignStyle,
|
||||
setPlayerGroup,
|
||||
modifyGroups,
|
||||
kickPlayer,
|
||||
cheat,
|
||||
pickupGuest,
|
||||
pickupStaff,
|
||||
balloonPress,
|
||||
modifyTile,
|
||||
editScenarioOptions,
|
||||
placePeepSpawn,
|
||||
setColourScheme,
|
||||
setStaffCostume,
|
||||
placeFootpathAddition,
|
||||
removeFootpathAddition,
|
||||
guestSetFlags,
|
||||
setDate,
|
||||
custom,
|
||||
changeMapSize,
|
||||
freezeRideRating,
|
||||
setGameSpeed,
|
||||
setRestrictedScenery,
|
||||
setRideVisibility,
|
||||
Count,
|
||||
count,
|
||||
};
|
||||
}
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class CheatSetAction final : public GameActionBase<GameCommand::Cheat>
|
||||
class CheatSetAction final : public GameActionBase<GameCommand::cheat>
|
||||
{
|
||||
using ParametersRange = std::pair<std::pair<int64_t, int64_t>, std::pair<int64_t, int64_t>>;
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class FootpathAdditionPlaceAction final : public GameActionBase<GameCommand::PlaceFootpathAddition>
|
||||
class FootpathAdditionPlaceAction final : public GameActionBase<GameCommand::placeFootpathAddition>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class FootpathAdditionRemoveAction final : public GameActionBase<GameCommand::RemoveFootpathAddition>
|
||||
class FootpathAdditionRemoveAction final : public GameActionBase<GameCommand::removeFootpathAddition>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class FootpathLayoutPlaceAction final : public GameActionBase<GameCommand::PlacePathLayout>
|
||||
class FootpathLayoutPlaceAction final : public GameActionBase<GameCommand::placePathLayout>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class FootpathPlaceAction final : public GameActionBase<GameCommand::PlacePath>
|
||||
class FootpathPlaceAction final : public GameActionBase<GameCommand::placePath>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class FootpathRemoveAction final : public GameActionBase<GameCommand::RemovePath>
|
||||
class FootpathRemoveAction final : public GameActionBase<GameCommand::removePath>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class BalloonPressAction final : public GameActionBase<GameCommand::BalloonPress>
|
||||
class BalloonPressAction final : public GameActionBase<GameCommand::balloonPress>
|
||||
{
|
||||
EntityId _spriteIndex{ EntityId::GetNull() };
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class CustomAction final : public GameActionBase<GameCommand::Custom>
|
||||
class CustomAction final : public GameActionBase<GameCommand::custom>
|
||||
{
|
||||
private:
|
||||
std::string _id;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class GameSetSpeedAction final : public GameActionBase<GameCommand::SetGameSpeed>
|
||||
class GameSetSpeedAction final : public GameActionBase<GameCommand::setGameSpeed>
|
||||
{
|
||||
private:
|
||||
uint8_t _speed{ 1 };
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace OpenRCT2::GameActions
|
||||
closeSavePrompt
|
||||
};
|
||||
|
||||
class LoadOrQuitAction final : public GameActionBase<GameCommand::LoadOrQuit>
|
||||
class LoadOrQuitAction final : public GameActionBase<GameCommand::loadOrQuit>
|
||||
{
|
||||
private:
|
||||
LoadOrQuitModes _mode{};
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class MapChangeSizeAction final : public GameActionBase<GameCommand::ChangeMapSize>
|
||||
class MapChangeSizeAction final : public GameActionBase<GameCommand::changeMapSize>
|
||||
{
|
||||
public:
|
||||
MapChangeSizeAction() = default;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class PauseToggleAction final : public GameActionBase<GameCommand::TogglePause>
|
||||
class PauseToggleAction final : public GameActionBase<GameCommand::togglePause>
|
||||
{
|
||||
public:
|
||||
PauseToggleAction() = default;
|
||||
|
||||
@@ -41,7 +41,7 @@ namespace OpenRCT2::GameActions
|
||||
count
|
||||
};
|
||||
|
||||
class ScenarioSetSettingAction final : public GameActionBase<GameCommand::EditScenarioOptions>
|
||||
class ScenarioSetSettingAction final : public GameActionBase<GameCommand::editScenarioOptions>
|
||||
{
|
||||
private:
|
||||
ScenarioSetSetting _setting{ ScenarioSetSetting::count };
|
||||
|
||||
@@ -44,7 +44,7 @@ namespace OpenRCT2::GameActions
|
||||
count,
|
||||
};
|
||||
|
||||
class TileModifyAction final : public GameActionBase<GameCommand::ModifyTile>
|
||||
class TileModifyAction final : public GameActionBase<GameCommand::modifyTile>
|
||||
{
|
||||
private:
|
||||
CoordsXY _loc;
|
||||
|
||||
@@ -31,7 +31,7 @@ namespace OpenRCT2::GameActions
|
||||
count
|
||||
};
|
||||
|
||||
class NetworkModifyGroupAction final : public GameActionBase<GameCommand::ModifyGroups>
|
||||
class NetworkModifyGroupAction final : public GameActionBase<GameCommand::modifyGroups>
|
||||
{
|
||||
private:
|
||||
ModifyGroupType _type{ ModifyGroupType::count };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class PlayerKickAction final : public GameActionBase<GameCommand::KickPlayer>
|
||||
class PlayerKickAction final : public GameActionBase<GameCommand::kickPlayer>
|
||||
{
|
||||
private:
|
||||
Network::PlayerId_t _playerId{ -1 };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class PlayerSetGroupAction final : public GameActionBase<GameCommand::SetPlayerGroup>
|
||||
class PlayerSetGroupAction final : public GameActionBase<GameCommand::setPlayerGroup>
|
||||
{
|
||||
private:
|
||||
Network::PlayerId_t _playerId{ -1 };
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace OpenRCT2::GameActions
|
||||
count
|
||||
};
|
||||
|
||||
class LandBuyRightsAction final : public GameActionBase<GameCommand::BuyLandRights>
|
||||
class LandBuyRightsAction final : public GameActionBase<GameCommand::buyLandRights>
|
||||
{
|
||||
private:
|
||||
MapRange _range;
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace OpenRCT2::GameActions
|
||||
count
|
||||
};
|
||||
|
||||
class LandSetRightsAction final : public GameActionBase<GameCommand::SetLandOwnership>
|
||||
class LandSetRightsAction final : public GameActionBase<GameCommand::setLandOwnership>
|
||||
{
|
||||
private:
|
||||
MapRange _range;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkEntrancePlaceAction final : public GameActionBase<GameCommand::PlaceParkEntrance>
|
||||
class ParkEntrancePlaceAction final : public GameActionBase<GameCommand::placeParkEntrance>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkEntranceRemoveAction final : public GameActionBase<GameCommand::RemoveParkEntrance>
|
||||
class ParkEntranceRemoveAction final : public GameActionBase<GameCommand::removeParkEntrance>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkMarketingAction final : public GameActionBase<GameCommand::StartMarketingCampaign>
|
||||
class ParkMarketingAction final : public GameActionBase<GameCommand::startMarketingCampaign>
|
||||
{
|
||||
private:
|
||||
int32_t _type{};
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkSetDateAction final : public GameActionBase<GameCommand::SetDate>
|
||||
class ParkSetDateAction final : public GameActionBase<GameCommand::setDate>
|
||||
{
|
||||
private:
|
||||
int32_t _year{};
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkSetEntranceFeeAction final : public GameActionBase<GameCommand::SetParkEntranceFee>
|
||||
class ParkSetEntranceFeeAction final : public GameActionBase<GameCommand::setParkEntranceFee>
|
||||
{
|
||||
private:
|
||||
money64 _fee{ kMoney64Undefined };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkSetLoanAction final : public GameActionBase<GameCommand::SetCurrentLoan>
|
||||
class ParkSetLoanAction final : public GameActionBase<GameCommand::setCurrentLoan>
|
||||
{
|
||||
private:
|
||||
money64 _value{ kMoney64Undefined };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkSetNameAction final : public GameActionBase<GameCommand::SetParkName>
|
||||
class ParkSetNameAction final : public GameActionBase<GameCommand::setParkName>
|
||||
{
|
||||
private:
|
||||
std::string _name;
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace OpenRCT2::GameActions
|
||||
count
|
||||
};
|
||||
|
||||
class ParkSetParameterAction final : public GameActionBase<GameCommand::SetParkOpen>
|
||||
class ParkSetParameterAction final : public GameActionBase<GameCommand::setParkOpen>
|
||||
{
|
||||
private:
|
||||
ParkParameter _parameter{ ParkParameter::count };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ParkSetResearchFundingAction final : public GameActionBase<GameCommand::SetResearchFunding>
|
||||
class ParkSetResearchFundingAction final : public GameActionBase<GameCommand::setResearchFunding>
|
||||
{
|
||||
private:
|
||||
// TODO change to std::optional when C++17
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class GuestSetFlagsAction final : public GameActionBase<GameCommand::GuestSetFlags>
|
||||
class GuestSetFlagsAction final : public GameActionBase<GameCommand::guestSetFlags>
|
||||
{
|
||||
private:
|
||||
EntityId _peepId{ EntityId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class GuestSetNameAction final : public GameActionBase<GameCommand::SetGuestName>
|
||||
class GuestSetNameAction final : public GameActionBase<GameCommand::setGuestName>
|
||||
{
|
||||
private:
|
||||
EntityId _spriteIndex{ EntityId::GetNull() };
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace OpenRCT2::GameActions
|
||||
count
|
||||
};
|
||||
|
||||
class PeepPickupAction final : public GameActionBase<GameCommand::PickupGuest>
|
||||
class PeepPickupAction final : public GameActionBase<GameCommand::pickupGuest>
|
||||
{
|
||||
private:
|
||||
PeepPickupType _type{ PeepPickupType::count };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class PeepSpawnPlaceAction final : public GameActionBase<GameCommand::PlacePeepSpawn>
|
||||
class PeepSpawnPlaceAction final : public GameActionBase<GameCommand::placePeepSpawn>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _location;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class StaffFireAction final : public GameActionBase<GameCommand::FireStaffMember>
|
||||
class StaffFireAction final : public GameActionBase<GameCommand::fireStaffMember>
|
||||
{
|
||||
private:
|
||||
EntityId _spriteId{ EntityId::GetNull() };
|
||||
|
||||
@@ -19,7 +19,7 @@ namespace OpenRCT2::GameActions
|
||||
EntityId StaffEntityId = EntityId::GetNull();
|
||||
};
|
||||
|
||||
class StaffHireNewAction final : public GameActionBase<GameCommand::HireNewStaffMember>
|
||||
class StaffHireNewAction final : public GameActionBase<GameCommand::hireNewStaffMember>
|
||||
{
|
||||
private:
|
||||
bool _autoPosition{};
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class StaffSetColourAction final : public GameActionBase<GameCommand::SetStaffColour>
|
||||
class StaffSetColourAction final : public GameActionBase<GameCommand::setStaffColour>
|
||||
{
|
||||
private:
|
||||
uint8_t _staffType{};
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class StaffSetCostumeAction final : public GameActionBase<GameCommand::SetStaffCostume>
|
||||
class StaffSetCostumeAction final : public GameActionBase<GameCommand::setStaffCostume>
|
||||
{
|
||||
private:
|
||||
EntityId _spriteIndex{ EntityId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class StaffSetNameAction final : public GameActionBase<GameCommand::SetStaffName>
|
||||
class StaffSetNameAction final : public GameActionBase<GameCommand::setStaffName>
|
||||
{
|
||||
private:
|
||||
EntityId _spriteIndex{ EntityId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class StaffSetOrdersAction final : public GameActionBase<GameCommand::SetStaffOrders>
|
||||
class StaffSetOrdersAction final : public GameActionBase<GameCommand::setStaffOrders>
|
||||
{
|
||||
private:
|
||||
EntityId _spriteIndex{ EntityId::GetNull() };
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace OpenRCT2::GameActions
|
||||
clearAll
|
||||
};
|
||||
|
||||
class StaffSetPatrolAreaAction final : public GameActionBase<GameCommand::SetStaffPatrol>
|
||||
class StaffSetPatrolAreaAction final : public GameActionBase<GameCommand::setStaffPatrol>
|
||||
{
|
||||
private:
|
||||
EntityId _spriteId{ EntityId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class MazePlaceTrackAction final : public GameActionBase<GameCommand::PlaceMazeDesign>
|
||||
class MazePlaceTrackAction final : public GameActionBase<GameCommand::placeMazeDesign>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace OpenRCT2::GameActions
|
||||
fill,
|
||||
};
|
||||
|
||||
class MazeSetTrackAction final : public GameActionBase<GameCommand::SetMazeTrack>
|
||||
class MazeSetTrackAction final : public GameActionBase<GameCommand::setMazeTrack>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class RideCreateAction final : public GameActionBase<GameCommand::CreateRide>
|
||||
class RideCreateAction final : public GameActionBase<GameCommand::createRide>
|
||||
{
|
||||
private:
|
||||
ride_type_t _rideType{ kRideTypeNull };
|
||||
|
||||
@@ -19,7 +19,7 @@ namespace OpenRCT2::GameActions
|
||||
renew,
|
||||
};
|
||||
|
||||
class RideDemolishAction final : public GameActionBase<GameCommand::DemolishRide>
|
||||
class RideDemolishAction final : public GameActionBase<GameCommand::demolishRide>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class RideEntranceExitPlaceAction final : public GameActionBase<GameCommand::PlaceRideEntranceOrExit>
|
||||
class RideEntranceExitPlaceAction final : public GameActionBase<GameCommand::placeRideEntranceOrExit>
|
||||
{
|
||||
private:
|
||||
CoordsXY _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class RideEntranceExitRemoveAction final : public GameActionBase<GameCommand::RemoveRideEntranceOrExit>
|
||||
class RideEntranceExitRemoveAction final : public GameActionBase<GameCommand::removeRideEntranceOrExit>
|
||||
{
|
||||
private:
|
||||
CoordsXY _loc;
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace OpenRCT2::GameActions
|
||||
nausea,
|
||||
};
|
||||
|
||||
class RideFreezeRatingAction final : public GameActionBase<GameCommand::FreezeRideRating>
|
||||
class RideFreezeRatingAction final : public GameActionBase<GameCommand::freezeRideRating>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace OpenRCT2::GameActions
|
||||
sellingItemColourIsRandom
|
||||
};
|
||||
|
||||
class RideSetAppearanceAction final : public GameActionBase<GameCommand::SetRideAppearance>
|
||||
class RideSetAppearanceAction final : public GameActionBase<GameCommand::setRideAppearance>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class RideSetColourSchemeAction final : public GameActionBase<GameCommand::SetColourScheme>
|
||||
class RideSetColourSchemeAction final : public GameActionBase<GameCommand::setColourScheme>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class RideSetNameAction final : public GameActionBase<GameCommand::SetRideName>
|
||||
class RideSetNameAction final : public GameActionBase<GameCommand::setRideName>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class RideSetPriceAction final : public GameActionBase<GameCommand::SetRidePrice>
|
||||
class RideSetPriceAction final : public GameActionBase<GameCommand::setRidePrice>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace OpenRCT2::GameActions
|
||||
rideType,
|
||||
};
|
||||
|
||||
class RideSetSettingAction final : public GameActionBase<GameCommand::SetRideSetting>
|
||||
class RideSetSettingAction final : public GameActionBase<GameCommand::setRideSetting>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class RideSetStatusAction final : public GameActionBase<GameCommand::SetRideStatus>
|
||||
class RideSetStatusAction final : public GameActionBase<GameCommand::setRideStatus>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace OpenRCT2::GameActions
|
||||
count,
|
||||
};
|
||||
|
||||
class RideSetVehicleAction final : public GameActionBase<GameCommand::SetRideVehicles>
|
||||
class RideSetVehicleAction final : public GameActionBase<GameCommand::setRideVehicles>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace OpenRCT2::GameActions
|
||||
BannerIndex bannerId = BannerIndex::GetNull();
|
||||
};
|
||||
|
||||
class BannerPlaceAction final : public GameActionBase<GameCommand::PlaceBanner>
|
||||
class BannerPlaceAction final : public GameActionBase<GameCommand::placeBanner>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class BannerRemoveAction final : public GameActionBase<GameCommand::RemoveBanner>
|
||||
class BannerRemoveAction final : public GameActionBase<GameCommand::removeBanner>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace OpenRCT2::Drawing
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class BannerSetColourAction final : public GameActionBase<GameCommand::SetBannerColour>
|
||||
class BannerSetColourAction final : public GameActionBase<GameCommand::setBannerColour>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class BannerSetNameAction final : public GameActionBase<GameCommand::SetBannerName>
|
||||
class BannerSetNameAction final : public GameActionBase<GameCommand::setBannerName>
|
||||
{
|
||||
private:
|
||||
BannerIndex _bannerIndex{ BannerIndex::GetNull() };
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace OpenRCT2::GameActions
|
||||
count
|
||||
};
|
||||
|
||||
class BannerSetStyleAction final : public GameActionBase<GameCommand::SetBannerStyle>
|
||||
class BannerSetStyleAction final : public GameActionBase<GameCommand::setBannerStyle>
|
||||
{
|
||||
private:
|
||||
BannerSetStyleType _type{ BannerSetStyleType::count };
|
||||
|
||||
@@ -26,7 +26,7 @@ namespace OpenRCT2::GameActions
|
||||
BannerIndex bannerId = BannerIndex::GetNull();
|
||||
};
|
||||
|
||||
class LargeSceneryPlaceAction final : public GameActionBase<GameCommand::PlaceLargeScenery>
|
||||
class LargeSceneryPlaceAction final : public GameActionBase<GameCommand::placeLargeScenery>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class LargeSceneryRemoveAction final : public GameActionBase<GameCommand::RemoveLargeScenery>
|
||||
class LargeSceneryRemoveAction final : public GameActionBase<GameCommand::removeLargeScenery>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class LargeScenerySetColourAction final : public GameActionBase<GameCommand::SetLargeSceneryColour>
|
||||
class LargeScenerySetColourAction final : public GameActionBase<GameCommand::setLargeSceneryColour>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class ScenerySetRestrictedAction final : public GameActionBase<GameCommand::SetRestrictedScenery>
|
||||
class ScenerySetRestrictedAction final : public GameActionBase<GameCommand::setRestrictedScenery>
|
||||
{
|
||||
private:
|
||||
ObjectType _objectType;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class SignSetNameAction final : public GameActionBase<GameCommand::SetSignName>
|
||||
class SignSetNameAction final : public GameActionBase<GameCommand::setSignName>
|
||||
{
|
||||
private:
|
||||
BannerIndex _bannerIndex{ BannerIndex::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class SignSetStyleAction final : public GameActionBase<GameCommand::SetSignStyle>
|
||||
class SignSetStyleAction final : public GameActionBase<GameCommand::setSignStyle>
|
||||
{
|
||||
private:
|
||||
BannerIndex _bannerIndex{ BannerIndex::GetNull() };
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace OpenRCT2::GameActions
|
||||
uint8_t SceneryQuadrant{};
|
||||
};
|
||||
|
||||
class SmallSceneryPlaceAction final : public GameActionBase<GameCommand::PlaceScenery>
|
||||
class SmallSceneryPlaceAction final : public GameActionBase<GameCommand::placeScenery>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class SmallSceneryRemoveAction final : public GameActionBase<GameCommand::RemoveScenery>
|
||||
class SmallSceneryRemoveAction final : public GameActionBase<GameCommand::removeScenery>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class SmallScenerySetColourAction final : public GameActionBase<GameCommand::SetSceneryColour>
|
||||
class SmallScenerySetColourAction final : public GameActionBase<GameCommand::setSceneryColour>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace OpenRCT2::GameActions
|
||||
BannerIndex BannerId = BannerIndex::GetNull();
|
||||
};
|
||||
|
||||
class WallPlaceAction final : public GameActionBase<GameCommand::PlaceWall>
|
||||
class WallPlaceAction final : public GameActionBase<GameCommand::placeWall>
|
||||
{
|
||||
private:
|
||||
ObjectEntryIndex _wallType{ kObjectEntryIndexNull };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class WallRemoveAction final : public GameActionBase<GameCommand::RemoveWall>
|
||||
class WallRemoveAction final : public GameActionBase<GameCommand::removeWall>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class WallSetColourAction final : public GameActionBase<GameCommand::SetWallColour>
|
||||
class WallSetColourAction final : public GameActionBase<GameCommand::setWallColour>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace OpenRCT2::GameActions
|
||||
constexpr ClearableItems kSceneryFootpath = 1 << 2;
|
||||
} // namespace CLEARABLE_ITEMS
|
||||
|
||||
class ClearAction final : public GameActionBase<GameCommand::ClearScenery>
|
||||
class ClearAction final : public GameActionBase<GameCommand::clearScenery>
|
||||
{
|
||||
private:
|
||||
MapRange _range;
|
||||
|
||||
@@ -15,7 +15,7 @@ enum class MapSelectType : uint8_t;
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class LandLowerAction final : public GameActionBase<GameCommand::LowerLand>
|
||||
class LandLowerAction final : public GameActionBase<GameCommand::lowerLand>
|
||||
{
|
||||
private:
|
||||
CoordsXY _coords;
|
||||
|
||||
@@ -15,7 +15,7 @@ enum class MapSelectType : uint8_t;
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class LandRaiseAction final : public GameActionBase<GameCommand::RaiseLand>
|
||||
class LandRaiseAction final : public GameActionBase<GameCommand::raiseLand>
|
||||
{
|
||||
private:
|
||||
CoordsXY _coords;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class LandSetHeightAction final : public GameActionBase<GameCommand::SetLandHeight>
|
||||
class LandSetHeightAction final : public GameActionBase<GameCommand::setLandHeight>
|
||||
{
|
||||
private:
|
||||
CoordsXY _coords;
|
||||
|
||||
@@ -15,7 +15,7 @@ enum class MapSelectType : uint8_t;
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class LandSmoothAction final : public GameActionBase<GameCommand::EditLandSmooth>
|
||||
class LandSmoothAction final : public GameActionBase<GameCommand::editLandSmooth>
|
||||
{
|
||||
private:
|
||||
CoordsXY _coords;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class SurfaceSetStyleAction final : public GameActionBase<GameCommand::ChangeSurfaceStyle>
|
||||
class SurfaceSetStyleAction final : public GameActionBase<GameCommand::changeSurfaceStyle>
|
||||
{
|
||||
private:
|
||||
MapRange _range;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class WaterLowerAction final : public GameActionBase<GameCommand::LowerWater>
|
||||
class WaterLowerAction final : public GameActionBase<GameCommand::lowerWater>
|
||||
{
|
||||
private:
|
||||
MapRange _range;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class WaterRaiseAction final : public GameActionBase<GameCommand::RaiseWater>
|
||||
class WaterRaiseAction final : public GameActionBase<GameCommand::raiseWater>
|
||||
{
|
||||
private:
|
||||
MapRange _range;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class WaterSetHeightAction final : public GameActionBase<GameCommand::SetWaterHeight>
|
||||
class WaterSetHeightAction final : public GameActionBase<GameCommand::setWaterHeight>
|
||||
{
|
||||
private:
|
||||
CoordsXY _coords;
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class TrackDesignAction final : public GameActionBase<GameCommand::PlaceTrackDesign>
|
||||
class TrackDesignAction final : public GameActionBase<GameCommand::placeTrackDesign>
|
||||
{
|
||||
private:
|
||||
CoordsXYZD _loc;
|
||||
|
||||
@@ -19,7 +19,7 @@ namespace OpenRCT2::GameActions
|
||||
uint8_t GroundFlags{ 0 };
|
||||
};
|
||||
|
||||
class TrackPlaceAction final : public GameActionBase<GameCommand::PlaceTrack>
|
||||
class TrackPlaceAction final : public GameActionBase<GameCommand::placeTrack>
|
||||
{
|
||||
private:
|
||||
RideId _rideIndex{ RideId::GetNull() };
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class TrackRemoveAction final : public GameActionBase<GameCommand::RemoveTrack>
|
||||
class TrackRemoveAction final : public GameActionBase<GameCommand::removeTrack>
|
||||
{
|
||||
private:
|
||||
TrackElemType _trackType{};
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
namespace OpenRCT2::GameActions
|
||||
{
|
||||
class TrackSetBrakeSpeedAction final : public GameActionBase<GameCommand::SetBrakesSpeed>
|
||||
class TrackSetBrakeSpeedAction final : public GameActionBase<GameCommand::setBrakesSpeed>
|
||||
{
|
||||
private:
|
||||
CoordsXYZ _loc;
|
||||
|
||||
@@ -58,187 +58,187 @@ namespace OpenRCT2::Network
|
||||
STR_ACTION_TERRAFORM,
|
||||
"PERMISSION_TERRAFORM",
|
||||
{
|
||||
GameCommand::SetLandHeight,
|
||||
GameCommand::RaiseLand,
|
||||
GameCommand::LowerLand,
|
||||
GameCommand::EditLandSmooth,
|
||||
GameCommand::ChangeSurfaceStyle,
|
||||
GameCommand::setLandHeight,
|
||||
GameCommand::raiseLand,
|
||||
GameCommand::lowerLand,
|
||||
GameCommand::editLandSmooth,
|
||||
GameCommand::changeSurfaceStyle,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_SET_WATER_LEVEL,
|
||||
"PERMISSION_SET_WATER_LEVEL",
|
||||
{
|
||||
GameCommand::SetWaterHeight,
|
||||
GameCommand::RaiseWater,
|
||||
GameCommand::LowerWater,
|
||||
GameCommand::setWaterHeight,
|
||||
GameCommand::raiseWater,
|
||||
GameCommand::lowerWater,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_TOGGLE_PAUSE,
|
||||
"PERMISSION_TOGGLE_PAUSE",
|
||||
{
|
||||
GameCommand::TogglePause,
|
||||
GameCommand::togglePause,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_CREATE_RIDE,
|
||||
"PERMISSION_CREATE_RIDE",
|
||||
{
|
||||
GameCommand::CreateRide,
|
||||
GameCommand::createRide,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_REMOVE_RIDE,
|
||||
"PERMISSION_REMOVE_RIDE",
|
||||
{
|
||||
GameCommand::DemolishRide,
|
||||
GameCommand::demolishRide,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_BUILD_RIDE,
|
||||
"PERMISSION_BUILD_RIDE",
|
||||
{
|
||||
GameCommand::PlaceTrack,
|
||||
GameCommand::RemoveTrack,
|
||||
GameCommand::SetMazeTrack,
|
||||
GameCommand::PlaceTrackDesign,
|
||||
GameCommand::PlaceMazeDesign,
|
||||
GameCommand::PlaceRideEntranceOrExit,
|
||||
GameCommand::RemoveRideEntranceOrExit,
|
||||
GameCommand::placeTrack,
|
||||
GameCommand::removeTrack,
|
||||
GameCommand::setMazeTrack,
|
||||
GameCommand::placeTrackDesign,
|
||||
GameCommand::placeMazeDesign,
|
||||
GameCommand::placeRideEntranceOrExit,
|
||||
GameCommand::removeRideEntranceOrExit,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_RIDE_PROPERTIES,
|
||||
"PERMISSION_RIDE_PROPERTIES",
|
||||
{
|
||||
GameCommand::SetRideName,
|
||||
GameCommand::SetRideAppearance,
|
||||
GameCommand::SetRideStatus,
|
||||
GameCommand::SetRideVehicles,
|
||||
GameCommand::SetRideSetting,
|
||||
GameCommand::SetRidePrice,
|
||||
GameCommand::SetBrakesSpeed,
|
||||
GameCommand::SetColourScheme,
|
||||
GameCommand::setRideName,
|
||||
GameCommand::setRideAppearance,
|
||||
GameCommand::setRideStatus,
|
||||
GameCommand::setRideVehicles,
|
||||
GameCommand::setRideSetting,
|
||||
GameCommand::setRidePrice,
|
||||
GameCommand::setBrakesSpeed,
|
||||
GameCommand::setColourScheme,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_SCENERY,
|
||||
"PERMISSION_SCENERY",
|
||||
{
|
||||
GameCommand::RemoveScenery,
|
||||
GameCommand::PlaceScenery,
|
||||
GameCommand::SetBrakesSpeed,
|
||||
GameCommand::RemoveWall,
|
||||
GameCommand::PlaceWall,
|
||||
GameCommand::RemoveLargeScenery,
|
||||
GameCommand::PlaceLargeScenery,
|
||||
GameCommand::PlaceBanner,
|
||||
GameCommand::RemoveBanner,
|
||||
GameCommand::SetSceneryColour,
|
||||
GameCommand::SetWallColour,
|
||||
GameCommand::SetLargeSceneryColour,
|
||||
GameCommand::SetBannerColour,
|
||||
GameCommand::SetBannerName,
|
||||
GameCommand::SetSignName,
|
||||
GameCommand::SetBannerStyle,
|
||||
GameCommand::SetSignStyle,
|
||||
GameCommand::removeScenery,
|
||||
GameCommand::placeScenery,
|
||||
GameCommand::setBrakesSpeed,
|
||||
GameCommand::removeWall,
|
||||
GameCommand::placeWall,
|
||||
GameCommand::removeLargeScenery,
|
||||
GameCommand::placeLargeScenery,
|
||||
GameCommand::placeBanner,
|
||||
GameCommand::removeBanner,
|
||||
GameCommand::setSceneryColour,
|
||||
GameCommand::setWallColour,
|
||||
GameCommand::setLargeSceneryColour,
|
||||
GameCommand::setBannerColour,
|
||||
GameCommand::setBannerName,
|
||||
GameCommand::setSignName,
|
||||
GameCommand::setBannerStyle,
|
||||
GameCommand::setSignStyle,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_PATH,
|
||||
"PERMISSION_PATH",
|
||||
{
|
||||
GameCommand::PlacePath,
|
||||
GameCommand::PlacePathLayout,
|
||||
GameCommand::RemovePath,
|
||||
GameCommand::PlaceFootpathAddition,
|
||||
GameCommand::RemoveFootpathAddition,
|
||||
GameCommand::placePath,
|
||||
GameCommand::placePathLayout,
|
||||
GameCommand::removePath,
|
||||
GameCommand::placeFootpathAddition,
|
||||
GameCommand::removeFootpathAddition,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_CLEAR_LANDSCAPE,
|
||||
"PERMISSION_CLEAR_LANDSCAPE",
|
||||
{
|
||||
GameCommand::ClearScenery,
|
||||
GameCommand::clearScenery,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_GUEST,
|
||||
"PERMISSION_GUEST",
|
||||
{
|
||||
GameCommand::SetGuestName,
|
||||
GameCommand::PickupGuest,
|
||||
GameCommand::BalloonPress,
|
||||
GameCommand::GuestSetFlags,
|
||||
GameCommand::setGuestName,
|
||||
GameCommand::pickupGuest,
|
||||
GameCommand::balloonPress,
|
||||
GameCommand::guestSetFlags,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_STAFF,
|
||||
"PERMISSION_STAFF",
|
||||
{
|
||||
GameCommand::HireNewStaffMember,
|
||||
GameCommand::SetStaffPatrol,
|
||||
GameCommand::FireStaffMember,
|
||||
GameCommand::SetStaffOrders,
|
||||
GameCommand::SetStaffCostume,
|
||||
GameCommand::SetStaffColour,
|
||||
GameCommand::SetStaffName,
|
||||
GameCommand::PickupStaff,
|
||||
GameCommand::hireNewStaffMember,
|
||||
GameCommand::setStaffPatrol,
|
||||
GameCommand::fireStaffMember,
|
||||
GameCommand::setStaffOrders,
|
||||
GameCommand::setStaffCostume,
|
||||
GameCommand::setStaffColour,
|
||||
GameCommand::setStaffName,
|
||||
GameCommand::pickupStaff,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_PARK_PROPERTIES,
|
||||
"PERMISSION_PARK_PROPERTIES",
|
||||
{
|
||||
GameCommand::SetParkName,
|
||||
GameCommand::SetParkOpen,
|
||||
GameCommand::SetParkEntranceFee,
|
||||
GameCommand::SetLandOwnership,
|
||||
GameCommand::BuyLandRights,
|
||||
GameCommand::PlaceParkEntrance,
|
||||
GameCommand::RemoveParkEntrance,
|
||||
GameCommand::PlacePeepSpawn,
|
||||
GameCommand::ChangeMapSize,
|
||||
GameCommand::setParkName,
|
||||
GameCommand::setParkOpen,
|
||||
GameCommand::setParkEntranceFee,
|
||||
GameCommand::setLandOwnership,
|
||||
GameCommand::buyLandRights,
|
||||
GameCommand::placeParkEntrance,
|
||||
GameCommand::removeParkEntrance,
|
||||
GameCommand::placePeepSpawn,
|
||||
GameCommand::changeMapSize,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_PARK_FUNDING,
|
||||
"PERMISSION_PARK_FUNDING",
|
||||
{
|
||||
GameCommand::SetCurrentLoan,
|
||||
GameCommand::SetResearchFunding,
|
||||
GameCommand::StartMarketingCampaign,
|
||||
GameCommand::setCurrentLoan,
|
||||
GameCommand::setResearchFunding,
|
||||
GameCommand::startMarketingCampaign,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_KICK_PLAYER,
|
||||
"PERMISSION_KICK_PLAYER",
|
||||
{
|
||||
GameCommand::KickPlayer,
|
||||
GameCommand::kickPlayer,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_MODIFY_GROUPS,
|
||||
"PERMISSION_MODIFY_GROUPS",
|
||||
{
|
||||
GameCommand::ModifyGroups,
|
||||
GameCommand::modifyGroups,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_SET_PLAYER_GROUP,
|
||||
"PERMISSION_SET_PLAYER_GROUP",
|
||||
{
|
||||
GameCommand::SetPlayerGroup,
|
||||
GameCommand::setPlayerGroup,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_CHEAT,
|
||||
"PERMISSION_CHEAT",
|
||||
{
|
||||
GameCommand::Cheat,
|
||||
GameCommand::SetDate,
|
||||
GameCommand::FreezeRideRating,
|
||||
GameCommand::cheat,
|
||||
GameCommand::setDate,
|
||||
GameCommand::freezeRideRating,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
@@ -255,14 +255,14 @@ namespace OpenRCT2::Network
|
||||
STR_ACTION_MODIFY_TILE,
|
||||
"PERMISSION_MODIFY_TILE",
|
||||
{
|
||||
GameCommand::ModifyTile,
|
||||
GameCommand::modifyTile,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
STR_ACTION_EDIT_SCENARIO_OPTIONS,
|
||||
"PERMISSION_EDIT_SCENARIO_OPTIONS",
|
||||
{
|
||||
GameCommand::EditScenarioOptions,
|
||||
GameCommand::editScenarioOptions,
|
||||
},
|
||||
},
|
||||
NetworkAction{
|
||||
|
||||
@@ -3039,12 +3039,12 @@ namespace OpenRCT2::Network
|
||||
packet >> tick >> actionType;
|
||||
|
||||
// Don't let clients send pause or quit
|
||||
if (actionType == GameCommand::TogglePause || actionType == GameCommand::LoadOrQuit)
|
||||
if (actionType == GameCommand::togglePause || actionType == GameCommand::loadOrQuit)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (actionType != GameCommand::Custom)
|
||||
if (actionType != GameCommand::custom)
|
||||
{
|
||||
// Check if player's group permission allows command to run
|
||||
NetworkGroup* group = GetGroupByID(connection.player->group);
|
||||
|
||||
@@ -1490,13 +1490,13 @@ JSValue ScriptEngine::GameActionResultToJS(
|
||||
if (result.error == GameActions::Status::ok)
|
||||
{
|
||||
// RideCreateAction only
|
||||
if (action.GetType() == GameCommand::CreateRide)
|
||||
if (action.GetType() == GameCommand::createRide)
|
||||
{
|
||||
const auto rideIndex = result.getData<RideId>();
|
||||
JS_SetPropertyStr(ctx, obj, "ride", JS_NewInt32(ctx, rideIndex.ToUnderlying()));
|
||||
}
|
||||
// StaffHireNewAction only
|
||||
else if (action.GetType() == GameCommand::HireNewStaffMember)
|
||||
else if (action.GetType() == GameCommand::hireNewStaffMember)
|
||||
{
|
||||
const auto actionResult = result.getData<GameActions::StaffHireNewActionResult>();
|
||||
if (!actionResult.StaffEntityId.IsNull())
|
||||
@@ -1508,13 +1508,13 @@ JSValue ScriptEngine::GameActionResultToJS(
|
||||
auto bannerId = BannerIndex::GetNull();
|
||||
switch (action.GetType())
|
||||
{
|
||||
case GameCommand::PlaceBanner:
|
||||
case GameCommand::placeBanner:
|
||||
bannerId = result.getData<GameActions::BannerPlaceActionResult>().bannerId;
|
||||
break;
|
||||
case GameCommand::PlaceLargeScenery:
|
||||
case GameCommand::placeLargeScenery:
|
||||
bannerId = result.getData<GameActions::LargeSceneryPlaceActionResult>().bannerId;
|
||||
break;
|
||||
case GameCommand::PlaceWall:
|
||||
case GameCommand::placeWall:
|
||||
bannerId = result.getData<GameActions::WallPlaceActionResult>().BannerId;
|
||||
break;
|
||||
default:
|
||||
@@ -1643,87 +1643,87 @@ public:
|
||||
|
||||
// clang-format off
|
||||
const static EnumMap<GameCommand> ActionNameToType = {
|
||||
{ "balloonpress", GameCommand::BalloonPress },
|
||||
{ "bannerplace", GameCommand::PlaceBanner },
|
||||
{ "bannerremove", GameCommand::RemoveBanner },
|
||||
{ "bannersetcolour", GameCommand::SetBannerColour },
|
||||
{ "bannersetname", GameCommand::SetBannerName },
|
||||
{ "bannersetstyle", GameCommand::SetBannerStyle },
|
||||
{ "clearscenery", GameCommand::ClearScenery },
|
||||
{ "footpathplace", GameCommand::PlacePath },
|
||||
{ "footpathlayoutplace", GameCommand::PlacePathLayout },
|
||||
{ "footpathremove", GameCommand::RemovePath },
|
||||
{ "footpathadditionplace", GameCommand::PlaceFootpathAddition },
|
||||
{ "footpathadditionremove", GameCommand::RemoveFootpathAddition },
|
||||
{ "gamesetspeed", GameCommand::SetGameSpeed },
|
||||
{ "guestsetflags", GameCommand::GuestSetFlags },
|
||||
{ "guestsetname", GameCommand::SetGuestName },
|
||||
{ "landbuyrights", GameCommand::BuyLandRights },
|
||||
{ "landlower", GameCommand::LowerLand },
|
||||
{ "landraise", GameCommand::RaiseLand },
|
||||
{ "landsetheight", GameCommand::SetLandHeight },
|
||||
{ "landsetrights", GameCommand::SetLandOwnership },
|
||||
{ "landsmooth", GameCommand::EditLandSmooth },
|
||||
{ "largesceneryplace", GameCommand::PlaceLargeScenery },
|
||||
{ "largesceneryremove", GameCommand::RemoveLargeScenery },
|
||||
{ "largescenerysetcolour", GameCommand::SetLargeSceneryColour },
|
||||
{ "loadorquit", GameCommand::LoadOrQuit },
|
||||
{ "mapchangesize", GameCommand::ChangeMapSize },
|
||||
{ "mazeplacetrack", GameCommand::PlaceMazeDesign },
|
||||
{ "mazesettrack", GameCommand::SetMazeTrack },
|
||||
{ "networkmodifygroup", GameCommand::ModifyGroups },
|
||||
{ "parkentranceplace", GameCommand::PlaceParkEntrance },
|
||||
{ "parkentranceremove", GameCommand::RemoveParkEntrance },
|
||||
{ "parkmarketing", GameCommand::StartMarketingCampaign },
|
||||
{ "parksetdate", GameCommand::SetDate },
|
||||
{ "parksetentrancefee", GameCommand::SetParkEntranceFee },
|
||||
{ "parksetloan", GameCommand::SetCurrentLoan },
|
||||
{ "parksetname", GameCommand::SetParkName },
|
||||
{ "parksetparameter", GameCommand::SetParkOpen },
|
||||
{ "parksetresearchfunding", GameCommand::SetResearchFunding },
|
||||
{ "pausetoggle", GameCommand::TogglePause },
|
||||
{ "peeppickup", GameCommand::PickupGuest },
|
||||
{ "peepspawnplace", GameCommand::PlacePeepSpawn },
|
||||
{ "playerkick", GameCommand::KickPlayer },
|
||||
{ "playersetgroup", GameCommand::SetPlayerGroup },
|
||||
{ "ridecreate", GameCommand::CreateRide },
|
||||
{ "ridedemolish", GameCommand::DemolishRide },
|
||||
{ "rideentranceexitplace", GameCommand::PlaceRideEntranceOrExit },
|
||||
{ "rideentranceexitremove", GameCommand::RemoveRideEntranceOrExit },
|
||||
{ "ridefreezerating", GameCommand::FreezeRideRating },
|
||||
{ "ridesetappearance", GameCommand::SetRideAppearance },
|
||||
{ "ridesetcolourscheme", GameCommand::SetColourScheme },
|
||||
{ "ridesetname", GameCommand::SetRideName },
|
||||
{ "ridesetprice", GameCommand::SetRidePrice },
|
||||
{ "ridesetsetting", GameCommand::SetRideSetting },
|
||||
{ "ridesetstatus", GameCommand::SetRideStatus },
|
||||
{ "ridesetvehicle", GameCommand::SetRideVehicles },
|
||||
{ "scenariosetsetting", GameCommand::EditScenarioOptions },
|
||||
{ "cheatset", GameCommand::Cheat },
|
||||
{ "signsetname", GameCommand::SetSignName },
|
||||
{ "signsetstyle", GameCommand::SetSignStyle },
|
||||
{ "smallsceneryplace", GameCommand::PlaceScenery },
|
||||
{ "smallsceneryremove", GameCommand::RemoveScenery },
|
||||
{ "smallscenerysetcolour", GameCommand::SetSceneryColour},
|
||||
{ "stafffire", GameCommand::FireStaffMember },
|
||||
{ "staffhire", GameCommand::HireNewStaffMember },
|
||||
{ "staffsetcolour", GameCommand::SetStaffColour },
|
||||
{ "staffsetcostume", GameCommand::SetStaffCostume },
|
||||
{ "staffsetname", GameCommand::SetStaffName },
|
||||
{ "staffsetorders", GameCommand::SetStaffOrders },
|
||||
{ "staffsetpatrolarea", GameCommand::SetStaffPatrol },
|
||||
{ "surfacesetstyle", GameCommand::ChangeSurfaceStyle },
|
||||
{ "tilemodify", GameCommand::ModifyTile },
|
||||
{ "trackdesign", GameCommand::PlaceTrackDesign },
|
||||
{ "trackplace", GameCommand::PlaceTrack },
|
||||
{ "trackremove", GameCommand::RemoveTrack },
|
||||
{ "tracksetbrakespeed", GameCommand::SetBrakesSpeed },
|
||||
{ "wallplace", GameCommand::PlaceWall },
|
||||
{ "wallremove", GameCommand::RemoveWall },
|
||||
{ "wallsetcolour", GameCommand::SetWallColour },
|
||||
{ "waterlower", GameCommand::LowerWater },
|
||||
{ "waterraise", GameCommand::RaiseWater },
|
||||
{ "watersetheight", GameCommand::SetWaterHeight }
|
||||
{ "balloonpress", GameCommand::balloonPress },
|
||||
{ "bannerplace", GameCommand::placeBanner },
|
||||
{ "bannerremove", GameCommand::removeBanner },
|
||||
{ "bannersetcolour", GameCommand::setBannerColour },
|
||||
{ "bannersetname", GameCommand::setBannerName },
|
||||
{ "bannersetstyle", GameCommand::setBannerStyle },
|
||||
{ "clearscenery", GameCommand::clearScenery },
|
||||
{ "footpathplace", GameCommand::placePath },
|
||||
{ "footpathlayoutplace", GameCommand::placePathLayout },
|
||||
{ "footpathremove", GameCommand::removePath },
|
||||
{ "footpathadditionplace", GameCommand::placeFootpathAddition },
|
||||
{ "footpathadditionremove", GameCommand::removeFootpathAddition },
|
||||
{ "gamesetspeed", GameCommand::setGameSpeed },
|
||||
{ "guestsetflags", GameCommand::guestSetFlags },
|
||||
{ "guestsetname", GameCommand::setGuestName },
|
||||
{ "landbuyrights", GameCommand::buyLandRights },
|
||||
{ "landlower", GameCommand::lowerLand },
|
||||
{ "landraise", GameCommand::raiseLand },
|
||||
{ "landsetheight", GameCommand::setLandHeight },
|
||||
{ "landsetrights", GameCommand::setLandOwnership },
|
||||
{ "landsmooth", GameCommand::editLandSmooth },
|
||||
{ "largesceneryplace", GameCommand::placeLargeScenery },
|
||||
{ "largesceneryremove", GameCommand::removeLargeScenery },
|
||||
{ "largescenerysetcolour", GameCommand::setLargeSceneryColour },
|
||||
{ "loadorquit", GameCommand::loadOrQuit },
|
||||
{ "mapchangesize", GameCommand::changeMapSize },
|
||||
{ "mazeplacetrack", GameCommand::placeMazeDesign },
|
||||
{ "mazesettrack", GameCommand::setMazeTrack },
|
||||
{ "networkmodifygroup", GameCommand::modifyGroups },
|
||||
{ "parkentranceplace", GameCommand::placeParkEntrance },
|
||||
{ "parkentranceremove", GameCommand::removeParkEntrance },
|
||||
{ "parkmarketing", GameCommand::startMarketingCampaign },
|
||||
{ "parksetdate", GameCommand::setDate },
|
||||
{ "parksetentrancefee", GameCommand::setParkEntranceFee },
|
||||
{ "parksetloan", GameCommand::setCurrentLoan },
|
||||
{ "parksetname", GameCommand::setParkName },
|
||||
{ "parksetparameter", GameCommand::setParkOpen },
|
||||
{ "parksetresearchfunding", GameCommand::setResearchFunding },
|
||||
{ "pausetoggle", GameCommand::togglePause },
|
||||
{ "peeppickup", GameCommand::pickupGuest },
|
||||
{ "peepspawnplace", GameCommand::placePeepSpawn },
|
||||
{ "playerkick", GameCommand::kickPlayer },
|
||||
{ "playersetgroup", GameCommand::setPlayerGroup },
|
||||
{ "ridecreate", GameCommand::createRide },
|
||||
{ "ridedemolish", GameCommand::demolishRide },
|
||||
{ "rideentranceexitplace", GameCommand::placeRideEntranceOrExit },
|
||||
{ "rideentranceexitremove", GameCommand::removeRideEntranceOrExit },
|
||||
{ "ridefreezerating", GameCommand::freezeRideRating },
|
||||
{ "ridesetappearance", GameCommand::setRideAppearance },
|
||||
{ "ridesetcolourscheme", GameCommand::setColourScheme },
|
||||
{ "ridesetname", GameCommand::setRideName },
|
||||
{ "ridesetprice", GameCommand::setRidePrice },
|
||||
{ "ridesetsetting", GameCommand::setRideSetting },
|
||||
{ "ridesetstatus", GameCommand::setRideStatus },
|
||||
{ "ridesetvehicle", GameCommand::setRideVehicles },
|
||||
{ "scenariosetsetting", GameCommand::editScenarioOptions },
|
||||
{ "cheatset", GameCommand::cheat },
|
||||
{ "signsetname", GameCommand::setSignName },
|
||||
{ "signsetstyle", GameCommand::setSignStyle },
|
||||
{ "smallsceneryplace", GameCommand::placeScenery },
|
||||
{ "smallsceneryremove", GameCommand::removeScenery },
|
||||
{ "smallscenerysetcolour", GameCommand::setSceneryColour},
|
||||
{ "stafffire", GameCommand::fireStaffMember },
|
||||
{ "staffhire", GameCommand::hireNewStaffMember },
|
||||
{ "staffsetcolour", GameCommand::setStaffColour },
|
||||
{ "staffsetcostume", GameCommand::setStaffCostume },
|
||||
{ "staffsetname", GameCommand::setStaffName },
|
||||
{ "staffsetorders", GameCommand::setStaffOrders },
|
||||
{ "staffsetpatrolarea", GameCommand::setStaffPatrol },
|
||||
{ "surfacesetstyle", GameCommand::changeSurfaceStyle },
|
||||
{ "tilemodify", GameCommand::modifyTile },
|
||||
{ "trackdesign", GameCommand::placeTrackDesign },
|
||||
{ "trackplace", GameCommand::placeTrack },
|
||||
{ "trackremove", GameCommand::removeTrack },
|
||||
{ "tracksetbrakespeed", GameCommand::setBrakesSpeed },
|
||||
{ "wallplace", GameCommand::placeWall },
|
||||
{ "wallremove", GameCommand::removeWall },
|
||||
{ "wallsetcolour", GameCommand::setWallColour },
|
||||
{ "waterlower", GameCommand::lowerWater },
|
||||
{ "waterraise", GameCommand::raiseWater },
|
||||
{ "watersetheight", GameCommand::setWaterHeight }
|
||||
};
|
||||
// clang-format on
|
||||
|
||||
@@ -1756,7 +1756,7 @@ void ScriptEngine::RunGameActionHooks(const GameActions::GameAction& action, Gam
|
||||
JSValue obj = JS_NewObject(ctx);
|
||||
|
||||
auto actionId = action.GetType();
|
||||
if (action.GetType() == GameCommand::Custom)
|
||||
if (action.GetType() == GameCommand::custom)
|
||||
{
|
||||
auto customAction = static_cast<const GameActions::CustomAction&>(action);
|
||||
JS_SetPropertyStr(ctx, obj, "action", JSFromStdString(ctx, customAction.GetId()));
|
||||
|
||||
Reference in new issue
Block a user