mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-04 05:32:54 +01:00
Remove references to game command
This commit is contained in:
@@ -90,7 +90,7 @@ static GAME_COMMAND_CALLBACK_POINTER * const game_command_callback_table[] = {
|
||||
nullptr,
|
||||
nullptr,
|
||||
nullptr,
|
||||
game_command_callback_ride_remove_track_piece,
|
||||
nullptr,
|
||||
game_command_callback_place_banner,
|
||||
game_command_callback_place_ride_entrance_or_exit,
|
||||
game_command_callback_hire_new_staff_member,
|
||||
@@ -731,14 +731,6 @@ void game_log_multiplayer_command(int command, const int* eax, const int* ebx, c
|
||||
network_append_server_log(log_msg);
|
||||
}
|
||||
}
|
||||
else if (command == GAME_COMMAND_REMOVE_TRACK)
|
||||
{
|
||||
char* args[1] = {
|
||||
(char*)player_name,
|
||||
};
|
||||
format_string(log_msg, 256, STR_LOG_REMOVE_TRACK, args);
|
||||
network_append_server_log(log_msg);
|
||||
}
|
||||
}
|
||||
|
||||
void pause_toggle()
|
||||
@@ -1324,7 +1316,7 @@ GAME_COMMAND_POINTER* new_game_command_table[GAME_COMMAND_COUNT] = {
|
||||
nullptr,
|
||||
nullptr,
|
||||
nullptr,
|
||||
game_command_remove_track,
|
||||
nullptr,
|
||||
game_load_or_quit,
|
||||
game_command_create_ride,
|
||||
game_command_demolish_ride,
|
||||
|
||||
@@ -22,7 +22,7 @@ enum GAME_COMMAND
|
||||
GAME_COMMAND_SET_LAND_HEIGHT, // GA
|
||||
GAME_COMMAND_TOGGLE_PAUSE, // GA
|
||||
GAME_COMMAND_PLACE_TRACK, // GA
|
||||
GAME_COMMAND_REMOVE_TRACK,
|
||||
GAME_COMMAND_REMOVE_TRACK, // GA
|
||||
GAME_COMMAND_LOAD_OR_QUIT,
|
||||
GAME_COMMAND_CREATE_RIDE, // GA
|
||||
GAME_COMMAND_DEMOLISH_RIDE,
|
||||
|
||||
@@ -48,7 +48,7 @@ public:
|
||||
{
|
||||
GameAction::Serialise(stream);
|
||||
|
||||
stream << DS_TAG(_trackType) << DS_TAG(_origin);
|
||||
stream << DS_TAG(_trackType) << DS_TAG(_sequence) << DS_TAG(_origin);
|
||||
}
|
||||
|
||||
GameActionResult::Ptr Query() const override
|
||||
@@ -74,8 +74,8 @@ public:
|
||||
if (!(GetFlags() & GAME_COMMAND_FLAG_ALLOW_DURING_PAUSED) && game_is_paused() && !gCheatsBuildInPauseMode)
|
||||
{
|
||||
return MakeResult(
|
||||
GA_ERROR::GAME_PAUSED,
|
||||
STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS, STR_CONSTRUCTION_NOT_POSSIBLE_WHILE_GAME_IS_PAUSED);
|
||||
GA_ERROR::GAME_PAUSED, STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS,
|
||||
STR_CONSTRUCTION_NOT_POSSIBLE_WHILE_GAME_IS_PAUSED);
|
||||
}
|
||||
|
||||
bool found = false;
|
||||
|
||||
@@ -152,11 +152,6 @@ rct_ride_measurement gRideMeasurements[MAX_RIDE_MEASUREMENTS];
|
||||
|
||||
uint16_t gRideCount;
|
||||
bool gGotoStartPlacementMode = false;
|
||||
int32_t gRideRemoveTrackPieceCallbackX;
|
||||
int32_t gRideRemoveTrackPieceCallbackY;
|
||||
int32_t gRideRemoveTrackPieceCallbackZ;
|
||||
int32_t gRideRemoveTrackPieceCallbackDirection;
|
||||
int32_t gRideRemoveTrackPieceCallbackType;
|
||||
|
||||
money16 gTotalRideValueForMoney;
|
||||
|
||||
@@ -6259,29 +6254,6 @@ rct_ride_name get_ride_naming(const uint8_t rideType, rct_ride_entry* rideEntry)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* Network client callback when removing ride pieces
|
||||
* Client does execute placing the piece on the same tick as mouse_up - waits for server command
|
||||
* Re-executes function from ride_construction - window_ride_construction_mouseup_demolish()
|
||||
* Only uses part that deals with construction state
|
||||
*/
|
||||
|
||||
void game_command_callback_ride_remove_track_piece(
|
||||
[[maybe_unused]] int32_t eax, [[maybe_unused]] int32_t ebx, [[maybe_unused]] int32_t ecx, [[maybe_unused]] int32_t edx,
|
||||
[[maybe_unused]] int32_t esi, [[maybe_unused]] int32_t edi, [[maybe_unused]] int32_t ebp)
|
||||
{
|
||||
int32_t x, y, z, direction, type;
|
||||
|
||||
x = gRideRemoveTrackPieceCallbackX;
|
||||
y = gRideRemoveTrackPieceCallbackY;
|
||||
z = gRideRemoveTrackPieceCallbackZ;
|
||||
direction = gRideRemoveTrackPieceCallbackDirection;
|
||||
type = gRideRemoveTrackPieceCallbackType;
|
||||
|
||||
window_ride_construction_mouseup_demolish_next_piece(x, y, z, direction, type);
|
||||
}
|
||||
|
||||
bool ride_type_has_flag(int32_t rideType, uint32_t flag)
|
||||
{
|
||||
return (RideProperties[rideType].flags & flag) != 0;
|
||||
@@ -6942,16 +6914,6 @@ bool ride_select_forwards_from_back()
|
||||
return false;
|
||||
}
|
||||
|
||||
money32 ride_remove_track_piece(int32_t x, int32_t y, int32_t z, int32_t direction, int32_t type, uint8_t flags)
|
||||
{
|
||||
gGameCommandErrorTitle = STR_RIDE_CONSTRUCTION_CANT_REMOVE_THIS;
|
||||
if (network_get_mode() == NETWORK_MODE_CLIENT)
|
||||
{
|
||||
game_command_callback = game_command_callback_ride_remove_track_piece;
|
||||
}
|
||||
return game_do_command(x, flags | ((direction & 3) << 8), y, type, GAME_COMMAND_REMOVE_TRACK, z, 0);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* rct2: 0x006B58EF
|
||||
@@ -7422,9 +7384,8 @@ static bool ride_is_vehicle_type_valid(Ride* ride, uint8_t inputRideEntryIndex)
|
||||
int32_t rideTypeIterator, rideTypeIteratorMax;
|
||||
|
||||
if (gCheatsShowVehiclesFromOtherTrackTypes
|
||||
&& !(
|
||||
ride_type_has_flag(ride->type, RIDE_TYPE_FLAG_FLAT_RIDE) || ride->type == RIDE_TYPE_MAZE
|
||||
|| ride->type == RIDE_TYPE_MINI_GOLF))
|
||||
&& !(ride_type_has_flag(ride->type, RIDE_TYPE_FLAG_FLAT_RIDE) || ride->type == RIDE_TYPE_MAZE
|
||||
|| ride->type == RIDE_TYPE_MINI_GOLF))
|
||||
{
|
||||
selectionShouldBeExpanded = true;
|
||||
rideTypeIterator = 0;
|
||||
|
||||
@@ -992,11 +992,6 @@ extern uint8_t gRideEntranceExitPlacePreviousRideConstructionState;
|
||||
extern uint8_t gRideEntranceExitPlaceDirection;
|
||||
|
||||
extern bool gGotoStartPlacementMode;
|
||||
extern int32_t gRideRemoveTrackPieceCallbackX;
|
||||
extern int32_t gRideRemoveTrackPieceCallbackY;
|
||||
extern int32_t gRideRemoveTrackPieceCallbackZ;
|
||||
extern int32_t gRideRemoveTrackPieceCallbackDirection;
|
||||
extern int32_t gRideRemoveTrackPieceCallbackType;
|
||||
|
||||
extern uint8_t gLastEntranceStyle;
|
||||
|
||||
@@ -1068,8 +1063,6 @@ rct_ride_name get_ride_naming(const uint8_t rideType, rct_ride_entry* rideEntry)
|
||||
void game_command_create_ride(int32_t* eax, int32_t* ebx, int32_t* ecx, int32_t* edx, int32_t* esi, int32_t* edi, int32_t* ebp);
|
||||
void game_command_callback_ride_construct_new(
|
||||
int32_t eax, int32_t ebx, int32_t ecx, int32_t edx, int32_t esi, int32_t edi, int32_t ebp);
|
||||
void game_command_callback_ride_remove_track_piece(
|
||||
int32_t eax, int32_t ebx, int32_t ecx, int32_t edx, int32_t esi, int32_t edi, int32_t ebp);
|
||||
void game_command_demolish_ride(
|
||||
int32_t* eax, int32_t* ebx, int32_t* ecx, int32_t* edx, int32_t* esi, int32_t* edi, int32_t* ebp);
|
||||
money32 ride_create_command(int32_t type, int32_t subType, int32_t flags, ride_id_t* outRideIndex, uint8_t* outRideColour);
|
||||
@@ -1133,8 +1126,6 @@ void ride_get_entrance_or_exit_position_from_screen_position(
|
||||
bool ride_select_backwards_from_front();
|
||||
bool ride_select_forwards_from_back();
|
||||
|
||||
money32 ride_remove_track_piece(int32_t x, int32_t y, int32_t z, int32_t direction, int32_t type, uint8_t flags);
|
||||
|
||||
bool ride_are_all_possible_entrances_and_exits_built(Ride* ride);
|
||||
void ride_fix_breakdown(Ride* ride, int32_t reliabilityIncreaseFactor);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user