diff options
Diffstat (limited to 'player.h')
-rw-r--r-- | player.h | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -7,6 +7,7 @@ #include "aystar.h" #include "rail.h" #include "engine.h" +#include "livery.h" typedef struct PlayerEconomyEntry { int32 income; @@ -161,6 +162,7 @@ typedef struct Player { int64 money64; // internal 64-bit version of the money. the 32-bit field will be clamped to plus minus 2 billion byte player_color; + Livery livery[LS_END]; byte player_money_fraction; byte avail_railtypes; byte block_preview; @@ -312,4 +314,11 @@ static inline int32 AddEngineReplacementForPlayer(Player *p, EngineID old_engine */ static inline int32 RemoveEngineReplacementForPlayer(Player *p, EngineID engine, uint32 flags) {return RemoveEngineReplacement(&p->engine_renew_list, engine, flags); } +/** + * Reset the livery schemes to the player's primary colour. + * This is used on loading games without livery information and on new player start up. + * @param p Player to reset. + */ +void ResetPlayerLivery(Player *p); + #endif /* PLAYER_H */ |