Event that reliably fires at game start

There isn't one.

Most of the time you can just use code outside of a function in an InGameUIAddin as that triggers between the loading screen and the player gaining control. But not if you need ContextPtr:LookUpControl() (which I'm guessing you do)

Edit: GameEvents.PlayerDoTurn.Add(function(iPlayer) end) is an alternative to Events.ActivePlayerTurnStart(), but it still has short-comings
 
:lol: how did you make that wild a guess ? Actually no I've given up on trying to do something about IGE, Don Quiche is right it's a minor issue that concerns nobody. I rarely use it myself (although when I do it's extremely useful). What I am looking for is a way to open the city screen when founding a city, even when unit cycling is set to auto. For it to work I have to set it cycling temporarily to manual :crazyeye: and need an init trigger at the start of the game.

:cry: I was afraid there would be no easy fix.

:crazyeye: but maybe there is one: ContextPtr:SetUpdate ?
 
ContextPtr:SetUpdate ?

Is used for animations, eg the World Wonder zooming/panning animation - as it fires many times a second (every 5 frames IIRC)
 
Well, I opened thread to provide that exact answer, but not needed now...

Strangely, I'm confronted with a need for an Events that fires on game entry after the engine creates Autosave_Initial_0000 BC-4000.Civ5GameSave. By testing, Events.LoadScreenClose fires right before that. (No big deal though. I can build a one-time listener from unit dirty or something like that.)
 
Back
Top Bottom