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

Suggestions, ideas and bugfixes related to modding

Discussion in 'Civ6 - Creation & Customization' started by Gedemon, Apr 4, 2019.

  1. Gedemon

    Gedemon Modder Moderator

    Joined:
    Oct 4, 2004
    Messages:
    9,384
    Location:
    France
    Updated Aug 11, 2019

    Fixes

    • Allows AI units to stack depending on the value of PLOT_UNIT_LIMIT (Last time I tried there is a check at the end of the AI turn to unstack units even when PLOT_UNIT_LIMIT > 1)
    • Delete all occurances within Firaxis-created lua files of "RowID - 1". The problem is that RowID does not update to reflect changes to database table "numbering" that come from mods, in which case (row.RowID - 1) can be different than row.Index (which is the value used in core)

    Graphic
    • Allow SQL queries to modify the Artdef tables
    • Make the heightmap update in game when placing Terrain and Features without a reload be. This happens when constructing a Dam - I understand that this is because Dams use the "TerrainEditMaterial" rather a "TerrainElement" but it seems like if the engine can handle the Heightmap being edited on the fly by the TerrainEditMaterial or Coastal Flooding it should be able to handle on on the fly heightmap changes when planting Features or adding removing Terrain and Features in the WorldBuilder tab in FireTuner.
    • Make it possible for Units to change the Terrain - yes, with the above I want true terraforming with Units!
    • Make it possible to add new base Terrain types outside of Snow/Tundra/Plains/Grassland/Desert - there is an unfortunate amount of hard-coding around these eg TerrainStyle.artdef StandardFlat Collection.
    • Make it possible to re-skin Particle FX - I can do it by editing the text strings in the .psb using Notepad by that's not as straight-forward as re-skinning the 3D assets.
    • Add 3 tile "C-shape" and 4 tile "Tri-star shape" TerrainElement configurations for Features/Natural Wonders - see post #5
    • Ability to set opacity maps for units. By now its not possible to have a opacity texture map in the material for a unit.
    • Ability to use different Tints for different Attachments in the Asset Editor like I can in the artdefs. At the moment I can only specify one Tint for the entire unit including all Attachments which doesn't imitate what is possible via the Artdefs. This would be handy for making Unit Portraits so that, for example, I can have blue horse armor without having a blue horse body.
    • If possible, update the unit preview script so it can preview both the horse and rider at the same time
    • Ability to test TerrainElement Materials outside of the game (including Heightmap changes) so that you combine with the TerrainElementAssets and fully test Natural Wonders outside of the game
    • Proper support for Dam World Wonders would be nice - perhaps with Hoover Dam or Three Gorges as an example? Windfly's Three Gorges is a very good effort but AFAIK there is no support to having face in the correct direction with regards to river flow

    Gameplay (Lua methods & events)
    • API documentation : full list of available methods and parameters
    • Game events that you can use to modify the gameplay, similar to civ5 (TestAll):
      • GameEvents.CanMakeDiplomaticAction( PlayerID1, PlayerID2, DiplomaticActionType)
      • GameEvents.CanTrade( PlayerID1, PlayerID2, ResourceType )
      • GameEvents.CanMakeDeal( PlayerID1, PlayerID2, DealType )
      • GameEvents.CityCanCreate ( PlayerID, CityID, ProjectType )
      • GameEvents.CityCanConstruct ( PlayerID, CityID, BuildingType )
      • GameEvents.CityCanCreate ( PlayerID, CityID, ProjectType )
      • GameEvents.CityCanTrain ( PlayerID, CityID, UnitType )
      • GameEvents.PlayerCanConstruct ( PlayerID, BuildingType )
      • GameEvents.PlayerCanCreate ( PlayerID, ProjectType )
      • GameEvents.PlayerCanResearchTech ( PlayerID, TechType )
      • GameEvents.PlayerCanResearchCivic ( PlayerID, CivicType )
      • GameEvents.PlayerCanAdoptPolicy ( PlayerID, PolicyType )
      • GameEvents.PlayerCanAdoptGovernment ( PlayerID, GovernmentType )
      • GameEvents.PlayerCanTrain ( PlayerID, UnitType )
      • GameEvents.UnitCanAttack ( UnitID1 , UnitID2 )
      • GameEvents.UnitCanDoActionAt ( UnitID , ActionType, PlotID )
    • More gameplay related methods like the DeclareWarOn() added for DLC scenarios :
      • DoActionOn( OtherPlayerID1, DiplomaticActionType)
      • DoTradeWith
      • DoDealWith
    • Add/Remove Modifiers via Lua for all entities
    • Method to change/set rivers/mountains/deserts/volcanoes names on all maps
    • Core events and methods to take direct control over AI units (there is a move method, but no engine event we can hook into to use it correctly, the AI units either double move or not move at all, and there is nothing for combat)
    • Linked to the above, Core events to to control a combat or a movement before it's executed, to allow things like various support fire (preparatory fire, counter-fire, opportunity fire, defensive fire, ...), first strike, ambushes, etc...
    • User exits for scoring done by the AI, eg a scoring done by AI is passed and updated with a return value, this would allow for a finer control on what and when AI builds and does, especially for city evaluation when assessing the attack possibilites and for plot evaluation when settling. And ideally if this would also support Contract Managers from behavior trees.


    Gameplay (general, database)

    • "StackingClasses" or "StackingWeigth" tables to allow separate values for stacking units type (for example 2 civilians + 1 ranged + 1 melee + 1 recon on a tile), ATM the stacking of various existing units type (civilian, support, religious, combat, ...) seems completly hardcoded.
    • More ARGTYPES for ModifierArguments (right now we have just these 3: ARGTYPE_IDENTITY, ScaleByGameSpeed, LinearScaleFromDefaultHandicap)
      • ScaleByGameEra
      • ScaleByMapSize
      • ScaleByGameTurn
    • Add a field to Technologies and Civics that makes them assignable by Modifiers only (similar to the new field for Projects in the Projects_XP2 table)
    • AdjacentDistrict not only for building wonders but also for building other districts and improvements (and possibly terrains and others)
    • Ability to add new types of moments with their triggering requirements. Right now that seems to all be done at the Game Core level
    • Output table and constraint name and the offending line of SQL (file and line number) on Database Error
    • Remove all hard-coding from Lua for things that can be determined from the dynamic data in the database and cached

    Alternatively, the release of the DLL source code would allow us to do all the gameplay related request ourselves.


    Modbuddy

    • ArtDefs that are not referenced in the Mod.Art.xml are highlighted red (or different colour)
    • XLPs that are not referenced in the Mod.Art.xml are highlighted red (or different colour)
    • Assets that are not referenced in any XLP are highlighted red (or different colour)
    • Icons/UI Textures that are not referenced in any XLP are highlighted red (or different colour)
    • Mod.Art.xml highlighted red (or different colour) if it's not added into UpdateArt (Mod Art Dependency File)
    • Scripts to streamline mod creation from assets
     
    Last edited: Aug 11, 2019
    Deliverator, steemroller and Infixo like this.
  2. Gedemon

    Gedemon Modder Moderator

    Joined:
    Oct 4, 2004
    Messages:
    9,384
    Location:
    France
    Forgot one:
    • A method to change/set rivers/mountains/deserts/volcanoes names on all maps
     
  3. Cosmic Fox

    Cosmic Fox Civ 6 Addict - TB Mod Collaborator

    Joined:
    Mar 14, 2009
    Messages:
    453
    Gender:
    Male
    Location:
    Las Vegas
    I did not see anything on adding our own eras or values to mountain tiles? Elucidus has been trying to add eras and insert new values for mountain tiles and other things. DB refuses to accept the changes, can this be added @Gedemon? If not delete my post :p
     
  4. Gedemon

    Gedemon Modder Moderator

    Joined:
    Oct 4, 2004
    Messages:
    9,384
    Location:
    France
    I don't know about those issues, but please, @everyone, feel free to format suggestions and post them in this thread (or link to the reports about them), I'll see if I can keep the OP updated if it proves useful

    ho, and how did I forgot thoses:
    • Core events and methods to take direct control over AI units (there is a move method, but no engine event we can hook into to use it correctly, the AI units either double move or not move at all, and there is nothing for combat)
    • Linked to the above, Core events to to control a combat or a movement before it's executed, to allow things like various support fire (preparatory fire, counter-fire, opportunity fire, defensive fire, ...), first strike, ambushes, etc...
     
    Last edited: Apr 4, 2019
    Infixo likes this.
  5. Deliverator

    Deliverator Graphical Hackificator

    Joined:
    Feb 12, 2008
    Messages:
    4,681
    Location:
    London, UK
    • Make the heightmap update in game when placing Terrain and Features without a reload be. This happens when constructing a Dam - I understand that this is because Dams use the "TerrainEditMaterial" rather a "TerrainElement" but it seems like if the engine can handle the Heightmap being edited on the fly by the TerrainEditMaterial or Coastal Flooding it should be able to handle on on the fly heightmap changes when planting Features or adding removing Terrain and Features in the WorldBuilder tab in FireTuner.
    • Make it possible for Units to change the Terrain - yes, with the above I want true terraforming with Units!
    • Make it possible to add new base Terrain types outside of Snow/Tundra/Plains/Grassland/Desert - there is an unfortunate amount of hard-coding around these e.g. TerrainStyle.artdef StandardFlat Collection.
    • Make it possible to re-skin Particle FX - I can do it by editing the text strings in the .psb using Notepad by that's not as straight-forward as re-skinning the 3D assets.
    • Add 3 tile "C-shape" and 4 tile "Tri-star shape" TerrainElement configurations for Features/Natural Wonders - see below:
    TerrainElement_C_shape.png TerrainElement_Tristar_shape.png
     
    Last edited: Apr 5, 2019
    ShiroToraRyu and SeelingCat like this.
  6. LeeS

    LeeS Imperator Supporter

    Joined:
    Jul 23, 2013
    Messages:
    6,972
    Location:
    Illinois, USA
  7. ShiroToraRyu

    ShiroToraRyu Hoping for Civ 7

    Joined:
    Apr 26, 2014
    Messages:
    403
    Gender:
    Male
    Location:
    Berlin, Germany
    +1

    that would be really helpful
     
  8. Infixo

    Infixo Deity

    Joined:
    Jan 9, 2016
    Messages:
    3,696
    Gender:
    Male
    Location:
    Warsaw
    I would like to have user exits for scoring done by the AI, e.g. a scoring done by AI is passed and updated with a return value.
    This would allow for a finer control on what and when AI builds and does.
    Especially for city evaluation when assessing the attack possibilites and for plot evaluation when settling.
    And ideally if this would also support Contract Managers from behavior trees.
     
  9. Gedemon

    Gedemon Modder Moderator

    Joined:
    Oct 4, 2004
    Messages:
    9,384
    Location:
    France
    Ho, yes, thanks, fixed! (my post I mean)
     
  10. Gedemon

    Gedemon Modder Moderator

    Joined:
    Oct 4, 2004
    Messages:
    9,384
    Location:
    France
    I second the ability to add new terrains type and on the fly update of terrain change, give use that @dshirk, and I swore I'll team with @Deliverator to do an alien invasion mod with a "xenoforming" element...
     
    Auda likes this.
  11. ShiroToraRyu

    ShiroToraRyu Hoping for Civ 7

    Joined:
    Apr 26, 2014
    Messages:
    403
    Gender:
    Male
    Location:
    Berlin, Germany
    I for one would also like to have the possibility to set opacity maps for units..by now its not possible to have a opacity texture map in the material for a unit.

    yeah, that would be nice
     
  12. Auda

    Auda Chieftain

    Joined:
    Oct 5, 2008
    Messages:
    32
    Location:
    Chella, Valencia, Spain
    OMG! That would be epic! Please make it possible. :crazyeye::p:worship:
     
  13. TheMarshmallowBear

    TheMarshmallowBear Benelovent Chieftain of the BearKingdom

    Joined:
    Dec 27, 2006
    Messages:
    7,525
    Location:
    Inside an Ikanda.
    What did you mean by "removing Game Modifiers for players/cities"?

    Do you mean via LUA? I like how that took me literally 10 seconds to realise what it meant.

    Can I suggest the simplest of things? An actual full API of LUA functions to use?

    Including a "Flip" and "Resurrect" for cities and players so I can work on my Rhyse and Fall remake.
     
  14. Brian Whitman

    Brian Whitman Chieftain

    Joined:
    Apr 3, 2019
    Messages:
    5
    With the current release of the Civilization VI Development Tools there now two types of particle effects. Legacy particles, in the PSB format, and FireFX particles in the FFX format.

    To skin legacy particles you need to convince the cooker to cook a new texture with an existing particle effect:

    1) Find the texture name you want to override, the textures are listed in the Particle Effect file (PTL format)
    2) Make a new texture in your mod with the exact same name and texture class
    3) Add a new XLP to your mod that uses the "VFX" class
    4) Add an entry to the XLP pointing to the Particle Effect Asset (AST file) you are overriding the texture for. By convention, they are named the same as the Particle Effect Effect (PTL file)
    5) Open the Art.xml file for your mod and make sure the VFX library is configured to load the VFX package

    When you cook this XLP it will use the Asset and Particle Effect from the base game, but the texture from your mod.

    Now for the caveat. To reduce footprint, cooked textures are shared. What this means for particle effect texture overriding is that this will override ALL particle effects that reference the texture in question.
    To complicate things further, its likely the LoadOrder will be very important for mods using this mechanism, because when project layering happens the last instance of the shared texture to be loaded will be the one used by everything.


    With the new particle system you have complete control over the particle using our FireFX scripting language.
    There is too much in that system to enumerate it here, details can be found in the documentation that comes with the Civilization VI Development Tools under the Understanding FireFX Scripts and Emitter Properties headings.
    There are also a number of FireFX scripts that can be used for reference in the Civilization VI Development Assets

     
    Smity2k1 and Deliverator like this.
  15. isau

    isau Deity

    Joined:
    Jan 15, 2007
    Messages:
    3,068
    Current wishlist (all database based):
    • More ARGTYPES for ModifierArguments. Right now we have just these 3:
      • ARGTYPE_IDENTITY
      • ScaleByGameSpeed
      • LinearScaleFromDefaultHandicap
    I'd add these as a start:
    • ScaleByGameEra
    • ScaleByMapSize
    • ScaleByGameTurn
    • Add a field to Technologies and Civics that makes them assignable by Modifiers only (similar to the new field for Projects in the Projects_XP2 table).
     
  16. Deliverator

    Deliverator Graphical Hackificator

    Joined:
    Feb 12, 2008
    Messages:
    4,681
    Location:
    London, UK
    A relatively small one: It would be nice if I could use different Tints for different Attachments in the Asset Editor like I can in the artdefs. At the moment I can only specify one Tint for the entire unit including all Attachments which doesn't imitate what is possible via the Artdefs. This would be handy for making Unit Portraits so that, for example, I can have blue horse armor without having a blue horse body.
     
  17. Wolfdog

    Wolfdog Unit Butcher

    Joined:
    Jun 29, 2012
    Messages:
    659
    Location:
    Australia
    I second that and maybe also it would be nice if possible to update the unit preview script so it can preview both the horse and rider at the same time.
     
    Deliverator likes this.
  18. racha

    racha Warlord

    Joined:
    Jul 27, 2013
    Messages:
    269
    Location:
    Surrounded by barbarians
    Suggestion: an idiot-proof GUI that lets you import graphics ~stuff~ (icons, atlases, textures, units, everything) from Firaxis assets, other mods and your own creations, and churns out a fully working file / mod at the click of a button.

    All the tutorials from the community are fantastic, but some of us old folk need all the help we can get to simplify things.
     
  19. Deliverator

    Deliverator Graphical Hackificator

    Joined:
    Feb 12, 2008
    Messages:
    4,681
    Location:
    London, UK
    • It would be good to be able to test TerrainElement Materials outside of the game (including Heightmap changes) so that you combine with the TerrainElementAssets and fully test Natural Wonders outside of the game.
     
  20. raen

    raen Coat of Arms

    Joined:
    May 12, 2003
    Messages:
    2,301
    Location:
    Portugal
    AdjacentDistrict not only for building wonders but also for building other districts and improvements (and possibly terrains and others)
     

Share This Page