|
OpenTTD Source 20251117-master-g7398d2e290
|
The storage for each script. More...
#include <script_storage.hpp>
Private Attributes | |
| ScriptModeProc * | mode = nullptr |
| The current build mode we are int. | |
| class ScriptObject * | mode_instance = nullptr |
| The instance belonging to the current build mode. | |
| ScriptAsyncModeProc * | async_mode = nullptr |
| The current command async mode we are in. | |
| class ScriptObject * | async_mode_instance = nullptr |
| The instance belonging to the current command async mode. | |
| CompanyID | root_company = INVALID_OWNER |
| The root company, the company that the script really belongs to. | |
| CompanyID | company = INVALID_OWNER |
| The current company. | |
| uint | delay = 1 |
| The ticks of delay each DoCommand has. | |
| bool | allow_do_command = true |
| Is the usage of DoCommands restricted? | |
| CommandCost | costs |
| The costs the script is tracking. | |
| Money | last_cost = 0 |
| The last cost of the command. | |
| ScriptErrorType | last_error {} |
| The last error of the command. | |
| bool | last_command_res = true |
| The last result of the command. | |
| CommandDataBuffer | last_data |
| The last data passed to a command. | |
| Commands | last_cmd = CMD_END |
| The last cmd passed to a command. | |
| CommandDataBuffer | last_cmd_ret |
| The extra data returned by the last command. | |
| std::vector< int > | callback_value |
| The values which need to survive a callback. | |
| RoadType | road_type = INVALID_ROADTYPE |
| The current roadtype we build. | |
| RailType | rail_type = INVALID_RAILTYPE |
| The current railtype we build. | |
| ScriptEventQueue | event_queue |
| Event queue for this script. | |
| ScriptLogTypes::LogData | log_data |
| Log data storage. | |
Friends | |
| class | ScriptObject |
The storage for each script.
It keeps track of important information.
Definition at line 43 of file script_storage.hpp.
|
friend |
Definition at line 44 of file script_storage.hpp.
|
private |
Is the usage of DoCommands restricted?
Definition at line 54 of file script_storage.hpp.
|
private |
The current command async mode we are in.
Definition at line 48 of file script_storage.hpp.
|
private |
The instance belonging to the current command async mode.
Definition at line 49 of file script_storage.hpp.
|
private |
The values which need to survive a callback.
Definition at line 65 of file script_storage.hpp.
|
private |
The current company.
Definition at line 51 of file script_storage.hpp.
|
private |
The costs the script is tracking.
Definition at line 56 of file script_storage.hpp.
|
private |
The ticks of delay each DoCommand has.
Definition at line 53 of file script_storage.hpp.
|
private |
Event queue for this script.
Definition at line 70 of file script_storage.hpp.
The last cmd passed to a command.
Definition at line 62 of file script_storage.hpp.
|
private |
The extra data returned by the last command.
Definition at line 63 of file script_storage.hpp.
|
private |
The last result of the command.
Definition at line 59 of file script_storage.hpp.
|
private |
The last cost of the command.
Definition at line 57 of file script_storage.hpp.
|
private |
The last data passed to a command.
Definition at line 61 of file script_storage.hpp.
|
private |
The last error of the command.
Definition at line 58 of file script_storage.hpp.
|
private |
Log data storage.
Definition at line 71 of file script_storage.hpp.
|
private |
The current build mode we are int.
Definition at line 46 of file script_storage.hpp.
|
private |
The instance belonging to the current build mode.
Definition at line 47 of file script_storage.hpp.
|
private |
The current railtype we build.
Definition at line 68 of file script_storage.hpp.
|
private |
The current roadtype we build.
Definition at line 67 of file script_storage.hpp.
|
private |
The root company, the company that the script really belongs to.
Definition at line 50 of file script_storage.hpp.