sp00n
Prince
- Joined
- Jan 4, 2007
- Messages
- 371
So I just learned how to change the interface by hooking a LuaEvent and making use of ContextPtr:LookUpControl() calls. And as far as I understood these function calls only work when they are executed from within the <UserInterface> section of the .modinfo file, and not within <ImportFiles>.
The problem - not really a problem, but an oddity - is that this section only seems to allow xml file entries. When I enter a lua file, I see the following entry in the Modding.log file: ERROR: UserInterface components require only the .xml file to be specified.
And the lua file isn't loaded.
However, I actually don't add any new UI element to the game, I'm only changing the size of an already existing one depending on a value I calculate in the lua file. So my xml file would be empty. Is there any way around having to reference an empty dummy xml file?
The problem - not really a problem, but an oddity - is that this section only seems to allow xml file entries. When I enter a lua file, I see the following entry in the Modding.log file: ERROR: UserInterface components require only the .xml file to be specified.
And the lua file isn't loaded.
However, I actually don't add any new UI element to the game, I'm only changing the size of an already existing one depending on a value I calculate in the lua file. So my xml file would be empty. Is there any way around having to reference an empty dummy xml file?