Beyond XML

What do you know about LUA?

  • Nothing and I don't care

    Votes: 0 0.0%
  • Nothing, but I'm interested

    Votes: 3 50.0%
  • The basics, but I'm struggling

    Votes: 2 33.3%
  • I'm doing okay, but I haven't found a technical reference re Civ VI

    Votes: 1 16.7%
  • I'm the LUA god civilizations pray to

    Votes: 0 0.0%

  • Total voters
    6

CivilizationAce

Warlord
Joined
Jan 17, 2017
Messages
240
So far I've used xml and sql to make changes that are isolated to the situation as the game starts.

However, I have no idea how to alter things on the fly during play.

Re SQL so far I only see configuration tables, not run-time.
  • Are existing units, buildings, acquired techs etc in the game represented in a database?
    • If so is there a database schema for that or a way I can access it to see what's there once a game is running?

I've noticed some stuff about LUA (most noticeably this: https://forums.civfanatics.com/threads/lua-basic-modding-guide-for-civ5.533853/) but it all seems quite cryptic. Is there a reference to LUA re Civ VI? I'm not bothered about the syntax of LUA itself yet (not that I'd turn down links to such), but I'd like to know what events Civ VI throws and what objects LUA recognises.
 
The database you modify with SQL/XML is read-only during gameplay. All gameplay data is stored in memory, then saved to a save file, and then reloaded. If you want to change the game behavior beyond what is offered by standard object features and modifiers, you need to do some coding in Lua. And this is where the fun begins :)
I think you should really visit this page: http://modiki.civfanatics.com/. It doesn't have Civ6 section yet, but the ideas are the same.
 
Back
Top Bottom