ModMod for VP: Adjustment of Late-Game Civilian Unit Era-based Models/Icons

Mad Madigan

Prince
Joined
Jun 15, 2016
Messages
403
For as many things that VP has improved about the experience of playing Civ 5, one remaining bugbear for me has been the way that certain civilian units change in appearance in the later eras of the game. Specifically, that there is a model and icon for cargo ships, caravans, workers, work boats, great generals, and great admirals that appear "modern" (aka featuring aesthetics of the post-Industrial Era world, such as the GGeneral's Jeep), but that these graphical changes occur either too early (for worker/work boat/GG/GA) or too late (for cargo ship/caravan).

I am not a knowledgeable coder nor do I have a lot of time these days for extensive modding, but I did some digging around the forums and was able to find older attempts at correcting this. After some testing and adjustment, I actually was able to get the changes I wanted to work in the latest version of VP, and so I have come to share what I found in case anyone else would like to adjust what Era the graphical changes for these units occur in. If @Gazebo and the rest of the VP team are interested, you are more than welcome to include these code snippets in the next version.

So by adding the following code into the NewUnits.sql file under "(2) Community Balance Overhaul\Balance Changes\Units" (although I am sure it could also be added to other .sql files and still work) these civilian units will now change their 3D model and icons to their "modern" equivalent in the actual, in-game Modern Era. That means no more Generals on Jeeps or plastic hard hat Workers in the Industrial Era and no more waiting til the Atomic Era for Cargo Ships and Caravans to appear as modern, steel ships and lorries.

Code:
UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_CARGO_SHIP_MODERN'
  WHERE Type = 'ART_DEF_UNIT_CARGO_SHIP_POSTMODERN';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_CARGO_SHIP_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_CARGO_SHIP_POSTMODERN';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_CARAVAN_MODERN'
  WHERE Type = 'ART_DEF_UNIT_CARAVAN_POSTMODERN';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_CARAVAN_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_CARAVAN_POSTMODERN';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_GREAT_ADMIRAL_MODERN'
  WHERE Type = 'ART_DEF_UNIT_GREAT_ADMIRAL_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_GREAT_ADMIRAL_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_GREAT_ADMIRAL_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_GREAT_GENERAL_MODERN'
  WHERE Type = 'ART_DEF_UNIT_GREAT_GENERAL_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_GREAT_GENERAL_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_GREAT_GENERAL_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_WORKBOAT_MODERN'
  WHERE Type = 'ART_DEF_UNIT_WORKBOAT_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_WORKBOAT_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_WORKBOAT_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_WORKER_MODERN'
  WHERE Type = 'ART_DEF_UNIT_WORKER_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_WORKER_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_WORKER_LATE';

Enjoy!
 
For as many things that VP has improved about the experience of playing Civ 5, one remaining bugbear for me has been the way that certain civilian units change in appearance in the later eras of the game. Specifically, that there is a model and icon for cargo ships, caravans, workers, work boats, great generals, and great admirals that appear "modern" (aka featuring aesthetics of the post-Industrial Era world, such as the GGeneral's Jeep), but that these graphical changes occur either too early (for worker/work boat/GG/GA) or too late (for cargo ship/caravan).

I am not a knowledgeable coder nor do I have a lot of time these days for extensive modding, but I did some digging around the forums and was able to find older attempts at correcting this. After some testing and adjustment, I actually was able to get the changes I wanted to work in the latest version of VP, and so I have come to share what I found in case anyone else would like to adjust what Era the graphical changes for these units occur in. If @Gazebo and the rest of the VP team are interested, you are more than welcome to include these code snippets in the next version.

So by adding the following code into the NewUnits.sql file under "(2) Community Balance Overhaul\Balance Changes\Units" (although I am sure it could also be added to other .sql files and still work) these civilian units will now change their 3D model and icons to their "modern" equivalent in the actual, in-game Modern Era. That means no more Generals on Jeeps or plastic hard hat Workers in the Industrial Era and no more waiting til the Atomic Era for Cargo Ships and Caravans to appear as modern, steel ships and lorries.

Code:
UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_CARGO_SHIP_MODERN'
  WHERE Type = 'ART_DEF_UNIT_CARGO_SHIP_POSTMODERN';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_CARGO_SHIP_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_CARGO_SHIP_POSTMODERN';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_CARAVAN_MODERN'
  WHERE Type = 'ART_DEF_UNIT_CARAVAN_POSTMODERN';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_CARAVAN_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_CARAVAN_POSTMODERN';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_GREAT_ADMIRAL_MODERN'
  WHERE Type = 'ART_DEF_UNIT_GREAT_ADMIRAL_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_GREAT_ADMIRAL_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_GREAT_ADMIRAL_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_GREAT_GENERAL_MODERN'
  WHERE Type = 'ART_DEF_UNIT_GREAT_GENERAL_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_GREAT_GENERAL_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_GREAT_GENERAL_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_WORKBOAT_MODERN'
  WHERE Type = 'ART_DEF_UNIT_WORKBOAT_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_WORKBOAT_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_WORKBOAT_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_WORKER_MODERN'
  WHERE Type = 'ART_DEF_UNIT_WORKER_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_WORKER_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_WORKER_LATE';

Enjoy!

I'll add this to my changes for next version, it seems like a quite sensible plug-and-play fix. Thanks! :)
 
@Recursive Just a note that I think these changes got lost, because I did not see them in the latest several beta patches you have put out. The above code snippet should be in "(2) Community Balance Overhaul\Balance Changes\Units\UnitChanges.sql". I have been having to add it back manually after each patch update so far this year.
 
@Recursive Just a note that I think these changes got lost, because I did not see them in the latest several beta patches you have put out. The above code snippet should be in "(2) Community Balance Overhaul\Balance Changes\Units\UnitChanges.sql". I have been having to add it back manually after each patch update so far this year.

It's in UnitFixes.sql, Community Patch folder.
 
@Recursive Okay, awesome! The reason I asked is because the era transitioning wasn't working as expected in my current game. I dug into it further and discovered that the art define for the Great General and Worker are not, in fact, "ART_DEF_UNIT_GREAT_GENERAL" and "ART_DEF_UNIT_WORKER", respectively. They are (because reasons) "ART_DEF_UNIT_GENERAL" and "ART_DEF_UNIT__WORKER" (note the two underscores!).

So I corrected this in the code of my own copy of the current beta version and now it works properly!!! Below is the corrected code snippet:

Code:
UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_CARGO_SHIP_MODERN'
  WHERE Type = 'ART_DEF_UNIT_CARGO_SHIP_POSTMODERN';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_CARGO_SHIP_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_CARGO_SHIP_POSTMODERN';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_CARAVAN_MODERN'
  WHERE Type = 'ART_DEF_UNIT_CARAVAN_POSTMODERN';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_CARAVAN_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_CARAVAN_POSTMODERN';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_GREAT_ADMIRAL_MODERN'
  WHERE Type = 'ART_DEF_UNIT_GREAT_ADMIRAL_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_GREAT_ADMIRAL_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_GREAT_ADMIRAL_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_GENERAL_MODERN'
  WHERE Type = 'ART_DEF_UNIT_GENERAL_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_GENERAL_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_GENERAL_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT_WORKBOAT_MODERN'
  WHERE Type = 'ART_DEF_UNIT_WORKBOAT_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT_WORKBOAT_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT_WORKBOAT_LATE';

UPDATE ArtDefine_UnitInfos
  SET Type = 'ART_DEF_UNIT__WORKER_MODERN'
  WHERE Type = 'ART_DEF_UNIT__WORKER_LATE';
UPDATE ArtDefine_UnitInfoMemberInfos
  SET UnitInfoType = 'ART_DEF_UNIT__WORKER_MODERN'
  WHERE UnitInfoType = 'ART_DEF_UNIT__WORKER_LATE';

Can you update this on Github for the next update?
 
Back
Top Bottom