OpenTTD Source 20260711-master-g3fb3006dff
gamelog.h File Reference

Functions to be called to log fundamental changes to the game. More...

#include "newgrf_config.h"
#include "newgrf_type.h"

Go to the source code of this file.

Data Structures

class  Gamelog

Enumerations

enum class  GamelogActionType : uint8_t {
  Start , Load , GRF , Cheat ,
  Setting , GRFBug , Emergency , End ,
  None = 0xFF
}
 The actions we log. More...
enum class  GamelogChangeType : uint8_t {
  Mode , Revision , OldVer , Setting ,
  GRFAdd , GRFRem , GRFCompat , GRFParam ,
  GRFMove , GRFBug , Emergency , End ,
  None = 0xFF
}
 Type of logged change. More...

Variables

Gamelog _gamelog
 Gamelog instance.

Detailed Description

Functions to be called to log fundamental changes to the game.

Definition in file gamelog.h.

Enumeration Type Documentation

◆ GamelogActionType

enum class GamelogActionType : uint8_t
strong

The actions we log.

Enumerator
Start 

Game created.

Load 

Game loaded.

GRF 

GRF changed.

Cheat 

Cheat was used.

Setting 

Setting changed.

GRFBug 

GRF bug was triggered.

Emergency 

Emergency savegame.

End 

End marker.

None 

No logging active; in savegames, end of list.

Definition at line 17 of file gamelog.h.

◆ GamelogChangeType

enum class GamelogChangeType : uint8_t
strong

Type of logged change.

Enumerator
Mode 

Scenario editor x Game, different landscape.

Revision 

Changed game revision string.

OldVer 

Loaded from savegame without logged data.

Setting 

Non-networksafe setting value changed.

GRFAdd 

Removed GRF.

GRFRem 

Added GRF.

GRFCompat 

Loading compatible GRF.

GRFParam 

GRF parameter changed.

GRFMove 

GRF order changed.

GRFBug 

GRF bug triggered.

Emergency 

Emergency savegame.

End 

End marker.

None 

In savegames, end of list.

Definition at line 30 of file gamelog.h.

Variable Documentation

◆ _gamelog