PreGame lua Object

S3rgeus

Emperor
Joined
Apr 10, 2011
Messages
1,270
Location
London, United Kingdom
Does anyone know where in the DLL the Lua PreGame object is defined? I can't seem to find it with the rest of the Lua stuff. (I thought, maybe, CvPreGame was automatically set up for its public methods to be available to Lua, but the methods all have different capitalization in Lua and C++, which isn't the case for other pushed Lua methods. Plus it doesn't work, adding a new method doesn't allow it to be called from Lua.)

Any searches for the usual lFunctionName naming convention for the PreGame functions turns up nothing. :(
 
Does anyone know where in the DLL the Lua PreGame object is defined?

It's not.

PreGame is available before any mods are loaded and it's handled by the main .exe code. Look in the UI/FrontEnd/MainMenu.lua file and you'll find a call to PreGame.LoadPreGameSettings(), search the DLLs for the string/symbol LoadPreGameSettings and you won't find it as it's in the main EXE (DX9/DX11/Tablet) files
 
It's not.

PreGame is available before any mods are loaded and it's handled by the main .exe code. Look in the UI/FrontEnd/MainMenu.lua file and you'll find a call to PreGame.LoadPreGameSettings(), search the DLLs for the string/symbol LoadPreGameSettings and you won't find it as it's in the main EXE (DX9/DX11/Tablet) files

Curses! At least we can extend the gameplay dll side of CvPreGame, though there are limitations to the usefulness of that since we can't attach any updates to the UI before the game starts up.
 
Back
Top Bottom