Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
Game.c
Go to the documentation of this file.
1/*
2===========================================
3Do not modify, this script is generated
4===========================================
5*/
6
7class Game
8{
9 protected World m_World;
13 sealed World GetWorld() { return m_World; }
17
21 proto external string GetWorldFile();
27 // --- Cinematics
28 proto external void StartCinematic(string name);
29 proto external void StopCinematic();
30 proto external bool IsPlayingCinematic();
42 proto external void ApplySettingsPreset();
46 proto external void UserSettingsChanged();
50 proto external void SaveUserSettings();
57 proto external bool IsSaveStorageAvailable();
61 proto external BackendApi GetBackendApi();
66 proto external RestApi GetRestApi();
75 proto external bool BeginPreload(notnull BaseWorld world, vector pos, float radius, int maxTime_sec = 60);
79 proto external bool IsPreloadFinished();
83 proto external int GetLoadTime();
87 proto external void RequestClose();
91 proto external string GetBuildVersion();
95 proto external string GetBuildTime();
99 proto external GenericWorldEntity GetWorldEntity();
100 proto external IEntity FindEntity(string name);
105 proto external bool InPlayMode();
106 proto external int ReloadFailureAddons(out notnull array<string> addons);
109 static proto bool IsDev();
110 proto external ref ScriptModule GetScriptModule();
115 [Obsolete("Pass addon GUIDs to the transition request directly")]
116 proto external void RequestReload(array<string> addonGUIDs = null);
122 proto external IEntity SpawnEntity(typename typeName, BaseWorld world = null, EntitySpawnParams params = null);
128 proto external IEntity SpawnEntityPrefab(notnull Resource templateResource, BaseWorld world = null, EntitySpawnParams params = null);
129
130 // callbacks
131
132 // script callbacks
133 event typename GetMenuPreset() { return GameLibMenusEnum; };
150 event void OnUpdate(BaseWorld world, float timeslice);
154 event void OnAfterInit(BaseWorld world);
158 event bool OnGameStart() { return true; };
162 event void OnGameEnd();
168 event void OnEvent(EventType eventTypeId, Tuple params);
176 event void OnInputDeviceUserChangedEvent(EInputDeviceType oldDevice, EInputDeviceType newDevice);
180 event void OnInputDeviceIsGamepadEvent(bool isGamepad);
184 event void OnWorldPostProcess(World world);
189 event void OnWorldSimulatePhysics(float timeSlice);
190 /*
191 \brief Event which is called after each fixed step of the physics simulation
192 *param timeSlice simulation step length
193 */
194 event void OnWorldPostSimulatePhysics(float timeSlice);
201 event void OnWindowResize(int w, int h, bool windowed);
203 event void HostGameConfig();
204 event void PlayGameConfig(ResourceName sResource, string addonsList);
205 event ref array<ResourceName> GetDefaultGameConfigs();
206 event Managed ReadGameConfig(string sResource);
211 event void OnGamepadConnectionStatus(bool isConnected);
212 /*
213 \brief Event which is called when Engine console command is executed.
214 @param cmd command text
215 */
216 event void OnConsoleCommand(string command);
217}
Backend Api instance.
Definition BackendApi.c:14
Definition Game.c:8
event void OnWorldPostProcess(World world)
Event called once loading of all entities of the world have been finished. (still within the loading)...
proto external void RequestClose()
Setting request flag for engine to exit the game.
event void HostGameConfig()
Called after reload to host a modded scenario.
proto external GenericWorldEntity GetWorldEntity()
Returns path of world file loaded.
event void OnGamepadConnectionStatus(bool isConnected)
Event which is called on Gamepad Connection/Disconnection.
proto external IEntity SpawnEntityPrefab(notnull Resource templateResource, BaseWorld world=null, EntitySpawnParams params=null)
event Managed ReadGameConfig(string sResource)
proto external void UserSettingsChanged()
Notify engine about changes in Engine User Settings.
proto external void RequestReload(array< string > addonGUIDs=null)
Setting request flag for the engine to reinitialize the game Doesn't do anything in Workbench.
event void OnWindowResize(int w, int h, bool windowed)
Event which is called when window size of fullscreen state changed.
World m_World
Definition Game.c:9
proto external bool IsPlayingCinematic()
sealed MenuManager GetMenuManager()
Definition Game.c:15
MenuManager m_MenuManager
Definition Game.c:11
proto external bool IsPreloadFinished()
If preload (started with BeginPreload method) is finished, returns true.
static proto bool IsDev()
Return true if executable is developer build.
WorkspaceWidget m_WorkspaceWidget
Definition Game.c:12
event void OnInputDeviceIsGamepadEvent(bool isGamepad)
Event which is called when input device binded to user changes between gamepad and keyboard/mouse,...
event GetMenuPreset()
Definition Game.c:133
proto external string GetBuildVersion()
Returns version of the game.
event bool OnGameStart()
Event which is called right before game starts (all entities are created and initialized)....
Definition Game.c:158
proto external GameWorldEditor GetWorldEditor()
InputManager m_InputManager
Definition Game.c:10
proto external void SaveUserSettings()
Save Engine User Settings to permanent storage.
proto external int GetLoadTime()
Returns load time in milliseconds for the lastly loaded world.
proto external void StartCinematic(string name)
event void OnUpdate(BaseWorld world, float timeslice)
Called on World update.
proto external IEntity SpawnEntity(typename typeName, BaseWorld world=null, EntitySpawnParams params=null)
proto external bool BeginPreload(notnull BaseWorld world, vector pos, float radius, int maxTime_sec=60)
Begin preloading on given position with given radius. Call is non-blocking, to get status of preload ...
proto external RestApi GetRestApi()
RESTful Api request access class.
event ref array< ResourceName > GetDefaultGameConfigs()
proto external bool IsSaveStorageAvailable()
Determines the availability of save storage. Game can try to call PlatformService::ObtainSaveDataAsyn...
sealed InputManager GetInputManager()
Definition Game.c:14
event void OnWorldPostSimulatePhysics(float timeSlice)
event void OnGameEnd()
Event which is called right before game end.
event void OnInputDeviceUserChangedEvent(EInputDeviceType oldDevice, EInputDeviceType newDevice)
Event which is called when input device binded to user changed.
event void OnConsoleCommand(string command)
proto external void StopCinematic()
proto external IEntity FindEntity(string name)
proto external BackendApi GetBackendApi()
Backend Api access class.
sealed WorkspaceWidget GetWorkspace()
Definition Game.c:16
proto external int ReloadFailureAddons(out notnull array< string > addons)
event void OnUserSettingsChangedEvent()
Event which is called when user change settings.
event void OnWorldSimulatePhysics(float timeSlice)
Event which is called before each fixed step of the physics simulation.
proto external UserSettings GetEngineUserSettings()
Returns UserSettings container for Engine User Settings.
event void PlayGameConfig(ResourceName sResource, string addonsList)
proto external void ApplySettingsPreset()
Apply setting preset according to DisplayUserSettings.OverallQuality.
proto external bool InPlayMode()
proto external BackendDebugApi GetBackendDebugApi()
sealed World GetWorld()
Definition Game.c:13
proto external string GetWorldFile()
Returns path of world file loaded.
proto external PlatformService GetPlatformService()
proto external ref ScriptModule GetScriptModule()
proto external string GetBuildTime()
Returns date and time when the game was built.
event void OnEvent(EventType eventTypeId, Tuple params)
Called when some system event occur. (NOTE: currently not called because of problems with recursion).
event LoadingAnim CreateLoadingAnim(WorkspaceWidget workspaceWidget)
event void OnAfterInit(BaseWorld world)
Called after full initialization of Game instance.
proto external UserSettings GetGameUserSettings()
Returns UserSettings container for Game User Settings.
Input management system for user interactions.
Object holding reference to resource. In destructor release the resource.
Definition Resource.c:25
Tuple class template with six parameters.
Definition tuple.c:13
Definition World.c:16
void EntitySpawnParams()
Definition gameLib.c:130
TypeID EventType
Definition EnWidgets.c:7