forked from rosebudai/OpenRCT2-Web
Move entity serialisation functions (#16003)
This commit is contained in:
1 parent
56e78d5733
commit
e3f8ff78b8
13 files changed
+287
-274
No files matched your search
@@ -11,6 +11,7 @@
|
||||
|
||||
#include "../Game.h"
|
||||
#include "../audio/audio.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../network/network.h"
|
||||
#include "../scenario/Scenario.h"
|
||||
#include "../util/Util.h"
|
||||
@@ -96,3 +97,12 @@ void Balloon::Create(const CoordsXYZ& balloonPos, int32_t colour, bool isPopped)
|
||||
balloon->colour = colour;
|
||||
balloon->popped = (isPopped ? 1 : 0);
|
||||
}
|
||||
|
||||
void Balloon::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
stream << popped;
|
||||
stream << time_to_move;
|
||||
stream << colour;
|
||||
}
|
||||
@@ -10,6 +10,7 @@
|
||||
|
||||
#include "../Game.h"
|
||||
#include "../audio/audio.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../localisation/Date.h"
|
||||
#include "../scenario/Scenario.h"
|
||||
#include "../sprites.h"
|
||||
@@ -352,3 +353,12 @@ void Duck::RemoveAll()
|
||||
duck->Remove();
|
||||
}
|
||||
}
|
||||
|
||||
void Duck::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
stream << target_x;
|
||||
stream << target_y;
|
||||
stream << state;
|
||||
}
|
||||
@@ -19,279 +19,12 @@
|
||||
#include "MoneyEffect.h"
|
||||
#include "Particle.h"
|
||||
|
||||
static void EntityBaseSerialise(EntityBase& base, DataSerialiser& stream)
|
||||
void EntityBase::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
stream << base.Type;
|
||||
stream << base.sprite_index;
|
||||
stream << base.x;
|
||||
stream << base.y;
|
||||
stream << base.z;
|
||||
stream << base.sprite_direction;
|
||||
}
|
||||
|
||||
void Litter::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << SubType;
|
||||
stream << creationTick;
|
||||
}
|
||||
|
||||
void Balloon::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
stream << popped;
|
||||
stream << time_to_move;
|
||||
stream << colour;
|
||||
}
|
||||
|
||||
void Duck::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
stream << target_x;
|
||||
stream << target_y;
|
||||
stream << state;
|
||||
}
|
||||
|
||||
void MoneyEffect::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
stream << MoveDelay;
|
||||
stream << NumMovements;
|
||||
stream << Vertical;
|
||||
stream << Value;
|
||||
stream << OffsetX;
|
||||
stream << Wiggle;
|
||||
}
|
||||
|
||||
void VehicleCrashParticle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
stream << time_to_live;
|
||||
stream << colour;
|
||||
stream << crashed_sprite_base;
|
||||
stream << velocity_x;
|
||||
stream << velocity_y;
|
||||
stream << velocity_z;
|
||||
stream << acceleration_x;
|
||||
stream << acceleration_y;
|
||||
stream << acceleration_z;
|
||||
}
|
||||
|
||||
void ExplosionFlare::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
}
|
||||
|
||||
void ExplosionCloud::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
}
|
||||
|
||||
void CrashSplashParticle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
}
|
||||
|
||||
void SteamParticle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
stream << time_to_move;
|
||||
}
|
||||
|
||||
void JumpingFountain::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << frame;
|
||||
stream << FountainType;
|
||||
stream << NumTicksAlive;
|
||||
stream << FountainFlags;
|
||||
stream << TargetX;
|
||||
stream << TargetY;
|
||||
stream << Iteration;
|
||||
}
|
||||
|
||||
static void PeepBaseSerialise(Peep& base, DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(base, stream);
|
||||
if (stream.IsLoading())
|
||||
{
|
||||
base.Name = nullptr;
|
||||
}
|
||||
stream << base.NextLoc;
|
||||
stream << base.NextFlags;
|
||||
stream << base.State;
|
||||
stream << base.SubState;
|
||||
stream << base.SpriteType;
|
||||
stream << base.TshirtColour;
|
||||
stream << base.TrousersColour;
|
||||
stream << base.DestinationX;
|
||||
stream << base.DestinationY;
|
||||
stream << base.DestinationTolerance;
|
||||
stream << base.Var37;
|
||||
stream << base.Energy;
|
||||
stream << base.EnergyTarget;
|
||||
stream << base.Mass;
|
||||
// stream << base.WindowInvalidateFlags;
|
||||
stream << base.CurrentRide;
|
||||
stream << base.CurrentRideStation;
|
||||
stream << base.CurrentTrain;
|
||||
stream << base.CurrentCar;
|
||||
stream << base.CurrentSeat;
|
||||
stream << base.SpecialSprite;
|
||||
stream << base.ActionSpriteType;
|
||||
stream << base.NextActionSpriteType;
|
||||
stream << base.ActionSpriteImageOffset;
|
||||
stream << base.Action;
|
||||
stream << base.ActionFrame;
|
||||
stream << base.StepProgress;
|
||||
stream << base.PeepDirection;
|
||||
stream << base.InteractionRideIndex;
|
||||
stream << base.Id;
|
||||
stream << base.PathCheckOptimisation;
|
||||
stream << base.PathfindGoal;
|
||||
stream << base.PathfindHistory;
|
||||
stream << base.WalkingFrameNum;
|
||||
stream << base.PeepFlags;
|
||||
}
|
||||
|
||||
void Guest::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
PeepBaseSerialise(*this, stream);
|
||||
stream << GuestNumRides;
|
||||
stream << GuestNextInQueue;
|
||||
stream << ParkEntryTime;
|
||||
stream << GuestHeadingToRideId;
|
||||
stream << GuestIsLostCountdown;
|
||||
stream << GuestTimeOnRide;
|
||||
stream << PaidToEnter;
|
||||
stream << PaidOnRides;
|
||||
stream << PaidOnFood;
|
||||
stream << PaidOnDrink;
|
||||
stream << PaidOnSouvenirs;
|
||||
stream << OutsideOfPark;
|
||||
stream << Happiness;
|
||||
stream << HappinessTarget;
|
||||
stream << Nausea;
|
||||
stream << NauseaTarget;
|
||||
stream << Hunger;
|
||||
stream << Thirst;
|
||||
stream << Toilet;
|
||||
stream << TimeToConsume;
|
||||
stream << Intensity;
|
||||
stream << NauseaTolerance;
|
||||
stream << TimeInQueue;
|
||||
stream << CashInPocket;
|
||||
stream << CashSpent;
|
||||
stream << Photo1RideRef;
|
||||
stream << Photo2RideRef;
|
||||
stream << Photo3RideRef;
|
||||
stream << Photo4RideRef;
|
||||
stream << RejoinQueueTimeout;
|
||||
stream << PreviousRide;
|
||||
stream << PreviousRideTimeOut;
|
||||
stream << Thoughts;
|
||||
stream << LitterCount;
|
||||
stream << DisgustingCount;
|
||||
stream << AmountOfFood;
|
||||
stream << AmountOfDrinks;
|
||||
stream << AmountOfSouvenirs;
|
||||
stream << VandalismSeen;
|
||||
stream << VoucherType;
|
||||
stream << VoucherRideId;
|
||||
stream << SurroundingsThoughtTimeout;
|
||||
stream << Angriness;
|
||||
stream << TimeLost;
|
||||
stream << DaysInQueue;
|
||||
stream << BalloonColour;
|
||||
stream << UmbrellaColour;
|
||||
stream << HatColour;
|
||||
stream << FavouriteRide;
|
||||
stream << FavouriteRideRating;
|
||||
stream << ItemFlags;
|
||||
}
|
||||
|
||||
void Staff::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
PeepBaseSerialise(*this, stream);
|
||||
stream << AssignedStaffType;
|
||||
stream << MechanicTimeSinceCall;
|
||||
stream << HireDate;
|
||||
stream << StaffOrders;
|
||||
stream << StaffMowingTimeout;
|
||||
stream << StaffLawnsMown;
|
||||
stream << StaffGardensWatered;
|
||||
stream << StaffLitterSwept;
|
||||
stream << StaffBinsEmptied;
|
||||
}
|
||||
|
||||
void Vehicle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBaseSerialise(*this, stream);
|
||||
stream << SubType;
|
||||
stream << Pitch;
|
||||
stream << bank_rotation;
|
||||
stream << remaining_distance;
|
||||
stream << velocity;
|
||||
stream << acceleration;
|
||||
stream << ride;
|
||||
stream << vehicle_type;
|
||||
stream << colours;
|
||||
stream << track_progress;
|
||||
stream << TrackTypeAndDirection;
|
||||
stream << TrackLocation;
|
||||
stream << next_vehicle_on_train;
|
||||
stream << prev_vehicle_on_ride;
|
||||
stream << next_vehicle_on_ride;
|
||||
stream << var_44;
|
||||
stream << mass;
|
||||
stream << update_flags;
|
||||
stream << SwingSprite;
|
||||
stream << current_station;
|
||||
stream << SwingPosition;
|
||||
stream << SwingSpeed;
|
||||
stream << status;
|
||||
stream << sub_state;
|
||||
stream << peep;
|
||||
stream << peep_tshirt_colours;
|
||||
stream << num_seats;
|
||||
stream << num_peeps;
|
||||
stream << next_free_seat;
|
||||
stream << restraints_position;
|
||||
stream << spin_speed;
|
||||
stream << sound2_flags;
|
||||
stream << spin_sprite;
|
||||
stream << sound1_id;
|
||||
stream << sound1_volume;
|
||||
stream << sound2_id;
|
||||
stream << sound2_volume;
|
||||
stream << sound_vector_factor;
|
||||
stream << var_C0;
|
||||
stream << speed;
|
||||
stream << powered_acceleration;
|
||||
stream << dodgems_collision_direction;
|
||||
stream << animation_frame;
|
||||
stream << animationState;
|
||||
stream << scream_sound_id;
|
||||
stream << TrackSubposition;
|
||||
stream << var_CE;
|
||||
stream << var_CF;
|
||||
stream << lost_time_out;
|
||||
stream << vertical_drop_countdown;
|
||||
stream << var_D3;
|
||||
stream << mini_golf_current_animation;
|
||||
stream << mini_golf_flags;
|
||||
stream << ride_subtype;
|
||||
stream << colours_extended;
|
||||
stream << seat_rotation;
|
||||
stream << target_seat_rotation;
|
||||
stream << BoatLocation;
|
||||
stream << IsCrashedVehicle;
|
||||
stream << Type;
|
||||
stream << sprite_index;
|
||||
stream << x;
|
||||
stream << y;
|
||||
stream << z;
|
||||
stream << sprite_direction;
|
||||
}
|
||||
@@ -68,4 +68,6 @@ struct EntityBase
|
||||
{
|
||||
return Is<T>() ? reinterpret_cast<const T*>(this) : nullptr;
|
||||
}
|
||||
|
||||
void Serialise(class DataSerialiser& stream);
|
||||
};
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "Fountain.h"
|
||||
|
||||
#include "../Game.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../scenario/Scenario.h"
|
||||
#include "../world/Footpath.h"
|
||||
#include "../world/Map.h"
|
||||
@@ -379,3 +380,15 @@ void JumpingFountain::CreateNext(const CoordsXYZ& newLoc, int32_t direction) con
|
||||
}
|
||||
JumpingFountain::Create(newType, newLoc, direction >> 1, newFlags, Iteration);
|
||||
}
|
||||
|
||||
void JumpingFountain::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
stream << FountainType;
|
||||
stream << NumTicksAlive;
|
||||
stream << FountainFlags;
|
||||
stream << TargetX;
|
||||
stream << TargetY;
|
||||
stream << Iteration;
|
||||
}
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
#include "../Cheats.h"
|
||||
#include "../Game.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../localisation/StringIds.h"
|
||||
#include "../world/Map.h"
|
||||
#include "EntityList.h"
|
||||
@@ -130,3 +131,11 @@ uint32_t Litter::GetAge() const
|
||||
{
|
||||
return gCurrentTicks - creationTick;
|
||||
}
|
||||
|
||||
void Litter::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
|
||||
stream << SubType;
|
||||
stream << creationTick;
|
||||
}
|
||||
@@ -9,6 +9,7 @@
|
||||
#include "MoneyEffect.h"
|
||||
|
||||
#include "../OpenRCT2.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../drawing/Drawing.h"
|
||||
#include "../interface/Viewport.h"
|
||||
#include "../interface/Window.h"
|
||||
@@ -152,3 +153,15 @@ std::pair<rct_string_id, money64> MoneyEffect::GetStringId() const
|
||||
|
||||
return std::make_pair(stringId, outValue);
|
||||
}
|
||||
|
||||
void MoneyEffect::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
stream << MoveDelay;
|
||||
stream << NumMovements;
|
||||
stream << Vertical;
|
||||
stream << Value;
|
||||
stream << OffsetX;
|
||||
stream << Wiggle;
|
||||
}
|
||||
@@ -9,6 +9,7 @@
|
||||
#include "Particle.h"
|
||||
|
||||
#include "../audio/audio.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../paint/sprite/Paint.Sprite.h"
|
||||
#include "../scenario/Scenario.h"
|
||||
#include "EntityRegistry.h"
|
||||
@@ -113,6 +114,21 @@ void VehicleCrashParticle::Update()
|
||||
}
|
||||
}
|
||||
|
||||
void VehicleCrashParticle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
stream << time_to_live;
|
||||
stream << colour;
|
||||
stream << crashed_sprite_base;
|
||||
stream << velocity_x;
|
||||
stream << velocity_y;
|
||||
stream << velocity_z;
|
||||
stream << acceleration_x;
|
||||
stream << acceleration_y;
|
||||
stream << acceleration_z;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* rct2: 0x00673699
|
||||
@@ -144,6 +160,12 @@ void CrashSplashParticle::Update()
|
||||
}
|
||||
}
|
||||
|
||||
void CrashSplashParticle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* rct2: 0x006734B2
|
||||
@@ -187,6 +209,13 @@ void SteamParticle::Update()
|
||||
}
|
||||
}
|
||||
|
||||
void SteamParticle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
stream << time_to_move;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* rct2: 0x0067363D
|
||||
@@ -218,6 +247,12 @@ void ExplosionCloud::Update()
|
||||
}
|
||||
}
|
||||
|
||||
void ExplosionCloud::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* rct2: 0x0067366B
|
||||
@@ -248,3 +283,9 @@ void ExplosionFlare::Update()
|
||||
EntityRemove(this);
|
||||
}
|
||||
}
|
||||
|
||||
void ExplosionFlare::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << frame;
|
||||
}
|
||||
@@ -14,6 +14,7 @@
|
||||
#include "../OpenRCT2.h"
|
||||
#include "../audio/audio.h"
|
||||
#include "../config/Config.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../core/Guard.hpp"
|
||||
#include "../core/Numerics.hpp"
|
||||
#include "../entity/Balloon.h"
|
||||
@@ -7484,3 +7485,59 @@ void Guest::RemoveRideFromMemory(ride_id_t rideId)
|
||||
lastEntry.item = PeepThoughtItemNone;
|
||||
}
|
||||
}
|
||||
|
||||
void Guest::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
Peep::Serialise(stream);
|
||||
stream << GuestNumRides;
|
||||
stream << GuestNextInQueue;
|
||||
stream << ParkEntryTime;
|
||||
stream << GuestHeadingToRideId;
|
||||
stream << GuestIsLostCountdown;
|
||||
stream << GuestTimeOnRide;
|
||||
stream << PaidToEnter;
|
||||
stream << PaidOnRides;
|
||||
stream << PaidOnFood;
|
||||
stream << PaidOnDrink;
|
||||
stream << PaidOnSouvenirs;
|
||||
stream << OutsideOfPark;
|
||||
stream << Happiness;
|
||||
stream << HappinessTarget;
|
||||
stream << Nausea;
|
||||
stream << NauseaTarget;
|
||||
stream << Hunger;
|
||||
stream << Thirst;
|
||||
stream << Toilet;
|
||||
stream << TimeToConsume;
|
||||
stream << Intensity;
|
||||
stream << NauseaTolerance;
|
||||
stream << TimeInQueue;
|
||||
stream << CashInPocket;
|
||||
stream << CashSpent;
|
||||
stream << Photo1RideRef;
|
||||
stream << Photo2RideRef;
|
||||
stream << Photo3RideRef;
|
||||
stream << Photo4RideRef;
|
||||
stream << RejoinQueueTimeout;
|
||||
stream << PreviousRide;
|
||||
stream << PreviousRideTimeOut;
|
||||
stream << Thoughts;
|
||||
stream << LitterCount;
|
||||
stream << DisgustingCount;
|
||||
stream << AmountOfFood;
|
||||
stream << AmountOfDrinks;
|
||||
stream << AmountOfSouvenirs;
|
||||
stream << VandalismSeen;
|
||||
stream << VoucherType;
|
||||
stream << VoucherRideId;
|
||||
stream << SurroundingsThoughtTimeout;
|
||||
stream << Angriness;
|
||||
stream << TimeLost;
|
||||
stream << DaysInQueue;
|
||||
stream << BalloonColour;
|
||||
stream << UmbrellaColour;
|
||||
stream << HatColour;
|
||||
stream << FavouriteRide;
|
||||
stream << FavouriteRideRating;
|
||||
stream << ItemFlags;
|
||||
}
|
||||
@@ -2631,3 +2631,47 @@ CoordsXY Peep::GetDestination() const
|
||||
{
|
||||
return CoordsXY{ DestinationX, DestinationY };
|
||||
}
|
||||
|
||||
void Peep::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
if (stream.IsLoading())
|
||||
{
|
||||
Name = nullptr;
|
||||
}
|
||||
stream << NextLoc;
|
||||
stream << NextFlags;
|
||||
stream << State;
|
||||
stream << SubState;
|
||||
stream << SpriteType;
|
||||
stream << TshirtColour;
|
||||
stream << TrousersColour;
|
||||
stream << DestinationX;
|
||||
stream << DestinationY;
|
||||
stream << DestinationTolerance;
|
||||
stream << Var37;
|
||||
stream << Energy;
|
||||
stream << EnergyTarget;
|
||||
stream << Mass;
|
||||
// stream << base.WindowInvalidateFlags;
|
||||
stream << CurrentRide;
|
||||
stream << CurrentRideStation;
|
||||
stream << CurrentTrain;
|
||||
stream << CurrentCar;
|
||||
stream << CurrentSeat;
|
||||
stream << SpecialSprite;
|
||||
stream << ActionSpriteType;
|
||||
stream << NextActionSpriteType;
|
||||
stream << ActionSpriteImageOffset;
|
||||
stream << Action;
|
||||
stream << ActionFrame;
|
||||
stream << StepProgress;
|
||||
stream << PeepDirection;
|
||||
stream << InteractionRideIndex;
|
||||
stream << Id;
|
||||
stream << PathCheckOptimisation;
|
||||
stream << PathfindGoal;
|
||||
stream << PathfindHistory;
|
||||
stream << WalkingFrameNum;
|
||||
stream << PeepFlags;
|
||||
}
|
||||
@@ -408,6 +408,8 @@ public: // Peep
|
||||
void SetDestination(const CoordsXY& coords, int32_t tolerance);
|
||||
[[nodiscard]] CoordsXY GetDestination() const;
|
||||
|
||||
void Serialise(class DataSerialiser& stream);
|
||||
|
||||
// TODO: Make these private again when done refactoring
|
||||
public: // Peep
|
||||
[[nodiscard]] bool CheckForPath();
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
#include "../actions/StaffSetOrdersAction.h"
|
||||
#include "../audio/audio.h"
|
||||
#include "../config/Config.h"
|
||||
#include "../core/DataSerialiser.h"
|
||||
#include "../entity/EntityRegistry.h"
|
||||
#include "../interface/Viewport.h"
|
||||
#include "../localisation/Date.h"
|
||||
@@ -2670,3 +2671,17 @@ money32 GetStaffWage(StaffType type)
|
||||
return MONEY(55, 00);
|
||||
}
|
||||
}
|
||||
|
||||
void Staff::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
Peep::Serialise(stream);
|
||||
stream << AssignedStaffType;
|
||||
stream << MechanicTimeSinceCall;
|
||||
stream << HireDate;
|
||||
stream << StaffOrders;
|
||||
stream << StaffMowingTimeout;
|
||||
stream << StaffLawnsMown;
|
||||
stream << StaffGardensWatered;
|
||||
stream << StaffLitterSwept;
|
||||
stream << StaffBinsEmptied;
|
||||
}
|
||||
@@ -9788,3 +9788,67 @@ void Vehicle::EnableCollisionsForTrain()
|
||||
vehicle->ClearUpdateFlag(VEHICLE_UPDATE_FLAG_COLLISION_DISABLED);
|
||||
}
|
||||
}
|
||||
|
||||
void Vehicle::Serialise(DataSerialiser& stream)
|
||||
{
|
||||
EntityBase::Serialise(stream);
|
||||
stream << SubType;
|
||||
stream << Pitch;
|
||||
stream << bank_rotation;
|
||||
stream << remaining_distance;
|
||||
stream << velocity;
|
||||
stream << acceleration;
|
||||
stream << ride;
|
||||
stream << vehicle_type;
|
||||
stream << colours;
|
||||
stream << track_progress;
|
||||
stream << TrackTypeAndDirection;
|
||||
stream << TrackLocation;
|
||||
stream << next_vehicle_on_train;
|
||||
stream << prev_vehicle_on_ride;
|
||||
stream << next_vehicle_on_ride;
|
||||
stream << var_44;
|
||||
stream << mass;
|
||||
stream << update_flags;
|
||||
stream << SwingSprite;
|
||||
stream << current_station;
|
||||
stream << SwingPosition;
|
||||
stream << SwingSpeed;
|
||||
stream << status;
|
||||
stream << sub_state;
|
||||
stream << peep;
|
||||
stream << peep_tshirt_colours;
|
||||
stream << num_seats;
|
||||
stream << num_peeps;
|
||||
stream << next_free_seat;
|
||||
stream << restraints_position;
|
||||
stream << spin_speed;
|
||||
stream << sound2_flags;
|
||||
stream << spin_sprite;
|
||||
stream << sound1_id;
|
||||
stream << sound1_volume;
|
||||
stream << sound2_id;
|
||||
stream << sound2_volume;
|
||||
stream << sound_vector_factor;
|
||||
stream << var_C0;
|
||||
stream << speed;
|
||||
stream << powered_acceleration;
|
||||
stream << dodgems_collision_direction;
|
||||
stream << animation_frame;
|
||||
stream << animationState;
|
||||
stream << scream_sound_id;
|
||||
stream << TrackSubposition;
|
||||
stream << var_CE;
|
||||
stream << var_CF;
|
||||
stream << lost_time_out;
|
||||
stream << vertical_drop_countdown;
|
||||
stream << var_D3;
|
||||
stream << mini_golf_current_animation;
|
||||
stream << mini_golf_flags;
|
||||
stream << ride_subtype;
|
||||
stream << colours_extended;
|
||||
stream << seat_rotation;
|
||||
stream << target_seat_rotation;
|
||||
stream << BoatLocation;
|
||||
stream << IsCrashedVehicle;
|
||||
}
|
||||
Reference in new issue
Block a user