1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Current Modding Limitations (post-DLL), Modding-Related Bugs and SDK Issues

Discussion in 'Civ5 - Creation & Customization' started by Pazyryk, Mar 5, 2013.

  1. Pazyryk

    Pazyryk Deity

    Joined:
    Jun 13, 2008
    Messages:
    3,584
    I'm going to skip items that could be done by modders and probably should go in the C++/Lua Request Thread, like new GameEvents or a better AssignStartingPlots.lua.


    Modding Limitations
    • No multiplayer for mods.
    • Can't modify a number of different kinds of data that are added by core game or DLC xml
    • LeaderLighting and LeaderSkin (possibly others) needed for leader screen.
    • Can't add custom fonts. (You can add system-installed fonts or extended font sets by xml in the Text folder, but they are not bit-mapped so look terrible. The bit-mapping/glyph system seems to be off limits to modders.)
    • Others... (I'll list as I find them)
    • No access to graphics dll. Related:
      • Can't update terrain graphics in-game (e.g., you can't terraform hills to flat, water to land, etc.).
    • No access to UI dll. Related:
      • Don't have "Get" methods for all of the different Controls we can "Set"
    • Can't update the vanilla dll via a mod, only G&K (perhaps related: the GetDLLPath option in ModBuddy doesn't work).

    Modding-Related Bugs
    • Graphic errors near x-wrap in all(?) modder-created map scripts: flatland often represented as hills or mountains and visa versa on the main map screen, though they are represented correctly in strategic view. It's not possible for modder to cause this error since we can't influence terrain graphics in any way. Described in Tectonics and PerfectWorld3 threads. (Note: there are other glitches around the "map seam" that appear in non-modded maps: empty rivers, vertical white streaks, strange attach animations, etc...)
    • Runtime errors are not reported for Lua chuncks called by GameEvents (but they are for Lua called from Events or the Live Tuner).
    • Mini-map: putting a tile back into the FoW doesn't clear the minimap
    • VFS load order not correct for Referenced mods (database xml/sql updates and AddIns do load in the proper order).

    SDK Issues
    • Creating unit art is horribly convoluted, requiring outdated versions of several programs (including the SDK itself) and modder-created software. Only a few individuals have mastered this.
    • When Runtime errors are reported in the Live Tuner, the file path is truncated such that the file name can't be identified. (This 60-char truncation is default Lua debug.traceback behavior, but it could be altered.)

    Please tell me what I've missed below.

    Moderator Action: Updated list for post-BNW changes
     
    dylansan likes this.
  2. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    No access to the UI dll - it would be useful to be able to add getters for all the setters on the Controls, and also fix the bug with the mini-map where putting a tile back into the FoW doesn't clear the minimap
     
  3. Pazyryk

    Pazyryk Deity

    Joined:
    Jun 13, 2008
    Messages:
    3,584
    There are a number of different kinds of data that are added by core game or DLC xml, but can't be added by mods (without hacking an existing DLC, that is). These include SoundID and SoundScript which would be needed to add sounds or music tracks, as opposed to only being able to replace existing files. Can folks post other data types (by name) that we are not able to mod?
     
  4. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    Unable to update the vanilla dll via a mod, and the GetDLLPath option in ModBuddy doesn't work
     
  5. Pazyryk

    Pazyryk Deity

    Joined:
    Jun 13, 2008
    Messages:
    3,584
    Added the vanilla dll limitation

    I thought this was just a bit of left-over code: maybe they thought about implementing it this way and then did something different and never removed this. If so, it's just code clutter and a potential modder stumper (which, if I was to point out in every case, would make my list somewhat unwieldy). But I'm no expert here so I may not understand the situation.
     
  6. Gedemon

    Gedemon Modder Moderator

    Joined:
    Oct 4, 2004
    Messages:
    9,156
    Location:
    France
    you can't make DLL mods for vanilla civ5.

    Moderator Action: and thread stickied, thanks Pazyryk for taking over.
     
  7. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    If I had to guess, I'd say it not working is directly related to being unable to load the vanilla dll via a mod
     
  8. Jabberwockxeno

    Jabberwockxeno Prince

    Joined:
    Jul 10, 2012
    Messages:
    487
    Question regarding dll mods: are there any out, at all?
     
  9. Lord Yanaek

    Lord Yanaek Emperor

    Joined:
    Aug 15, 2003
    Messages:
    1,495
    Welcome back from Mars ;)
    whoward's "DLL - Various Mod Components"
    This is the only general dll mod so far (others are specific to some bigger mods), but it has a lot of potential and improves constantly.
     
  10. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    Thanks :) It also has all the changed C++ source included in the mod so you can change it if you want.
     
  11. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    No access to the database xml parsing code, I'd like to add

    Code:
    <{tablename}>
      <If exists="{sql select stmt}"/>
        <!-- updates etc for say G&K, another mod being present or a game option with a specific setting -->
      <Else/>
        <!-- optional updates if the exists is not met -->
      <EndIf/>
    </{tablename}>
    
    This could be used to solve the Vanilla vs G&K issues, testing to see if another mod is present, or checking for a game option (eg langauge selection)
     
  12. Pazyryk

    Pazyryk Deity

    Joined:
    Jun 13, 2008
    Messages:
    3,584
    Couldn't the above be done with SQL?
     
  13. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    Only with great pain.

    Code:
    <TableName>
      <If exists="stmt"/>
        <!-- hundreds of Row/Update/Delete tags in here, eg for foreign text keys -->
      <Else/>
        <!-- hundreds of Row/Update/Delete tags in here, eg for foreign text keys  -->
      <EndIf/>
    </TableName>
    As opposed to

    Code:
    INSERT/UPDATE/DELETE ... WHERE ... AND EXISTS stmt;
    -- repeat above hundreds of times
    INSERT/UPDATE/DELETE ... WHERE ... AND EXISTS NOT stmt;
    -- repeat above hundreds of times
    I'd rather write the stmt once than "two times hundreds" of times
     
  14. Ekmek

    Ekmek on steam: ekmek_e

    Joined:
    Aug 7, 2002
    Messages:
    6,047
    Location:
    San Diego, California
    I'l work on an alternate farm graphic today. I know the game will load it if I make it part of a DLC. But does anyone know if it will load as part of a mod?
     
  15. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    Load order for mods only honours one of Depends and References if both are set on a mod. So if Mod M depends on Mod D and references Mod R the load order can be D, R, M (correct) or R, D, M (also correct) or D, M, R (incorrect)
     
  16. whoward69

    whoward69 DLL Minion

    Joined:
    May 30, 2011
    Messages:
    8,399
    Location:
    Near Portsmouth, UK
    Yet another References/Depends sequencing issue for lua files (may be solved if the VFS was loaded in the correct order)

    Code:
    for addin in Modding.GetActivatedModEntryPoints(something) do
    doesn't return files in the correct depends/references order
     
  17. Sync

    Sync Warlord

    Joined:
    May 28, 2008
    Messages:
    101
    Location:
    Warrington, England
    Most moddable civ ever? Shafer was laughing all the way to the bank.
     
  18. Gedemon

    Gedemon Modder Moderator

    Joined:
    Oct 4, 2004
    Messages:
    9,156
    Location:
    France
    It's far from perfect, but it's still really close to be "the most moddable civ ever". It depends of your mod's goals. Now please, stay on topic here, this thread is to add elements to the list only.
     
  19. Pazyryk

    Pazyryk Deity

    Joined:
    Jun 13, 2008
    Messages:
    3,584
    More moddable than Civ1 - 3.

    But to be fair, it's pretty amazing what can be done (even without DLL). In any case, modders are starting to look at replacing installation folders. This has been a sort of "self-imposed" limit on Civ5 modding that was never an issue in Civ4.


    Edit: posted before I saw moderator's chastisement :).
     
  20. Putmalk

    Putmalk Deity

    Joined:
    Sep 26, 2010
    Messages:
    2,623
    Location:
    New York
    Here's a question that may or may not belong here: Do you guys think they'll release the source code for BNW in a timely fashion, so we can convert our Gods and Kings mods to Brave New World?
     

Share This Page