[Civ2] Civilization II MGE User Interface Additions (CIV2UIA)

Is it possible to have an option to swap the graphics in throne room? It bothers me that I "upgrade" smooth walls to cave-like. I guess it may be outside of this project's scope but seeing the insane amount of quality of life additions / bugfixes I want to check first here before trying to learn how to modify pv.dll in Civ2 :)
Do you mean just reordering the progression? I could whip something up. Now that you mention it, it would make more sense to chisel out from a rough cave.
 
And done! I had to edit the layers a bit as the original Level 0 borders were showing through when used as upgrade layers, but otherwise it was a simple swap. Unfortunately this is not compatible with UIA, as the launcher appears to apply the vanilla fix overtop pv.dll, thus superseding the edit. UPDATE: Fixed!

You may be onto something that the original is backwards: note the fur bunting between this and the original:

Spoiler :


 
Last edited:
Unfortunately this is not compatible with UIA, as the launcher appears to apply the vanilla fix overtop pv.dll, thus superseding the edit.
Civ2UIA replaces resource #105 only if it has size of 74478 bytes.
https://github.com/FoxAhead/Civ2-UI...3b2504aeac2d55005d/src/Civ2UIA_Ex.pas#L87-L91
C-like:
  DllGifsToBeFixed: array[1..3] of TDllGifsToBeFixed = (
    (ResNum: 105; WrongSize: 74478),
    (ResNum: 229; WrongSize: 29923),
    (ResNum: 250; WrongSize: 27741)
    );
So, to prevent the intervention of Civ2UIA just make 105.gif of the size other than 74478.
 
As luck would have it, just re-saving the GIF shrunk it by ~5KB. Now works. :D

Civ2 isn't exactly a big programme these days, but now I'm wondering if it's worth optimizing all the .dlls...
 
As luck would have it, just re-saving the GIF shrunk it by ~5KB. Now works. :D

Civ2 isn't exactly a big programme these days, but now I'm wondering if it's worth optimizing all the .dlls...
I would double check why the size has decreased. Has there been any loss of quality?
 
Visually identical as far as I can see. Palette hasn't changed, same dimensions, but it's been almost thirty years so GIF encoding may have improved since they were originally created.
 
Checking visually a bunch of ways these images look identical / perfect to me also.
Added to both TOT and MGE for next time I play either.
 
Visually identical as far as I can see. Palette hasn't changed, same dimensions, but it's been almost thirty years so GIF encoding may have improved since they were originally created.
where can I download this gif image or the modified library file?
under spoilers png picture
 
Is there an option to use move command similar to the one issued while holding shift but with one important difference, that once the unit attacked it stops and asks for further instructions? I hate it when I siege a city on diagonal and the move to command causes my unit to conquer the city which I wanted to use to heal my other unit.
 
Can't get the Council/movies to work with UIA. They only work if I use compabibility (e.g. with Windows XP) but then I can't use UIA, because it gives me Error: ReadProcessMemory: 5.

Details: Windows 10, I have a CiV2.nrg I got Caesar knows where from and how old ago that says Gold Edition Multiplayer, so it should be the right one. I installed it through Daemon Tools Lite, and successfully applied the 1.3 patch 5.4.0f. UIA works, but only if there's no compabibility mode, and then I don't get movies/Council. Do I have a wrong version of the game or is there anything else I should do?
 
Last edited:
Can't get the Council/movies to work with UIA. They only work if I use compabibility (e.g. with Windows XP) but then I can't use UIA, because it gives me Error: ReadProcessMemory: 5.

Details: Windows 10, I have a CiV2.nrg I got Caesar knows where from and how old ago that says Gold Edition Multiplayer, so it should be the right one. I installed it through Daemon Tools Lite, and successfully applied the 1.3 patch 5.4.0f. UIA works, but only if there's no compabibility mode, and then I don't get movies/Council. Do I have a wrong version of the game or is there anything else I should do?
you need to use the program CodecTweakTool without compatibility or to avoid freezing leave compatibility with Windows 7
in the program, click on the ACM/VMW 86 button and select the Indeo 4/5 codec, click Apply
 
Can't get the Council/movies to work with UIA. They only work if I use compabibility (e.g. with Windows XP) but then I can't use UIA, because it gives me Error: ReadProcessMemory: 5.

Details: Windows 10, I have a CiV2.nrg I got Caesar knows where from and how old ago that says Gold Edition Multiplayer, so it should be the right one. I installed it through Daemon Tools Lite, and successfully applied the 1.3 patch 5.4.0f. UIA works, but only if there's no compabibility mode, and then I don't get movies/Council. Do I have a wrong version of the game or is there anything else I should do?
Try turning off No-CD patch in the Options of Civ2UIA Launcher
 
Try turning off No-CD patch in the Options of Civ2UIA Launcher
If you mean the Disable CD Check option, yeah, I had already unticked it. The problem isn't the usual "Council doesn't even show up", it's that the screen shows up and I get black spaces instead of council movies.
 
Last edited:
If you mean the Disable CD Check option, yeah, I had already unticked it. The problem isn't the usual "Council doesn't even show up", it's that the screen shows up and I get black spaces instead of council movies.
Then it looks like the codec problem. Try enabling Indeo codec as @duplj said.
 
New version 1.21 (build 2676).
ADD: x3 Major Objective flag now can be used in scenarios.
FIX: Setting all units on sentry with mass Sentry feature (key U) should also set Unit.GotoX to $FFFF so they can board next ship in port.
CHANGE: CityWindow: In the 'Change Production' list show the real maintainance cost provided by Civ2.GetUpkeep() function, and not the one that is defined in the RULES.TXT, taking into account all game factors such as Adam Smith's TC, government, difficulty or advances. This applies, for example, to barracks with different military advances, or 1-gold buildings with ASTC, or happines related improvements under Fundamentalism.
ADD: CityWindow: Show city size in the top-left corner.
ADD: CityWindow: Show total resources gathered in the Resource Map. Also show resources from one tile under the cursor.
ADD: CityWindow and QuickInfo: indicate trade route level with plus signs. This is a multiplier depending on the connection between cities (considering qualified road and Airport) and the availability of Superhighways. It could be from nothing to '+++'.
ADD: Draw unit veteran badge. This feature follows the game rules, so don't expect to reveal enemy veterans.
ADD: CityWindow: show the number of turns remaining to complete construction in the bottom-right corner of the production box.
ADD: ScienceAdvisor: show more info (beakers production, turns to complete)
ADD: TaxWindow: show turns to complete current research
FIX: TaxWindow: correct Discoveries Turns calculation
FIX: CityViewWindow: Center image on the screen wider than 1280
FIX: Correct estimated time to build/research wherever possible. That is, if there is no beakers production, then it should say 'Never'. The same applies to improvements construction in the city.
FEATURE: CityWindow: ResourceMap: right click on center removes all workers.
FIX: CityWindow: While in Turn phase, allow to press key 'C' or touch Shift key without warning about closing window.
FIX: CityWindow: Bring back focus to CityWindow after some dialogs (sell, buy, rename, change production etc).
FIX: CanvasEx.TextOutWithShadows was not using clipping. Now unit internal counter should not be drawn outside of the ClientRectangle.
CHANGE: CDCheck patch (No-CD) now works in Smart mode. If Civ2 compact disc is present in the CDROM drive then all paths are directed to CD. Otherwise game works in local mode.
FIX: The game was looking for Civ2 CD only in the first CDROM drive. CdAudio and CDCheck patches now correctly find CDROM with Civ2 disc in case of multiple CDROMs are installed.
FEATURE: Some advisor windows can now handle keys for opening TaxWindow (Shift+T) or to switch to another advisor (F1, F2, F4, F5, F6). So you can swicth between them instantly.
FEATURE: CDAudio: Finally. In case of no Civ2 CD detected, music now can be played from files in the MUSIC folder. There can be separate MUSIC folder in each subfolder (scenario). Files are filtered by extensions: MP3, WAV, AIFF, FLAC, OGG, AAC, WMA, APE. The playability of specific format depends on codecs installed in your system. Please note the following logic of the original game. Files are sorted alphabetically case-insensitively, and the first file corresponds to Track #2 (the Track #1 on the CD is data). If the number of files is 9, 11, 17 or 23, the game allows you to use 'Pick Music' dialog from the Game menu, suggesting titles from the GAME.TXT file from the @PICKMUSIC, @PICKMUSICGOLD, @PICKMUSICSCENARIO, @PICKMUSICFANWORLDS sections respectively. Otherwise "music disc" is considered "Custom" and no track can be picked manually. The music switches to the next random track at the end of the current track or after leaving some no-music screens such as High Council or foreign dialogs. In "Custom" mode it could be any track, otherwise Track #2 and Track #3 (first and second files) are excluded, as they are reserved for special events: Track #2 "Funeral March" for loosing and Track #3 "Ode to Joy" for joyful events.
FIX: Crash on trying to draw music track progress while in main menu Credits window.
FIX: CityStatusAdvisor: Moved call to Civ2.CalcCityGlobals() to the beginning of the loop to bring changes of all trade-connected cities after exiting CityWindow.
FIX: Scrolling step in dialogs with multiple colums and horizontal scrollbar, e.g. Research goal was default value 3. Now this type of windows is detected as wtDialogMultiColumns and step (ScrollLines) is 1 (one column per scroll step).
FIX: Resizing Science Advisor or Intelligence Report now correctly adjusts horizontal scrollbar range and position.
FIX: Save UIA settings only when really closing Advisor (not just calling function). This prevents CreateFile spam which may cause random EFCreateError exception with ERROR_USER_MAPPED_FILE error caused by antivirus interferring.
ADD: Save UIA settings also on saving CIV2.DAT file
FEATURE: With active caravan (non-food) selected, press Shift+G or select the menu 'Kingdom - Cities Trading In...' to display a list of possible caravan delivery revenues.
ADD: Put working Settler/Engineer on top of the stack after accumulating work counter from coworker. So working unit will be first in the stack and more noticeable.
FIX: GIF loaders were crashing on GIF Graphics Control Extension (it can be added by some image editors like Aseprite).
FIX: MassMove was not checking for unit's current task and could take away engineer with order but not yet processed in this turn.

Download
https://github.com/FoxAhead/Civ2-UI-Additions/releases/tag/v1.21

Demo.png
 
Good God, Christmas came early! :cool: The science report improvements were on my wishlist for ages, but the new trade details are something else—knowing the delivery values upfront is a total game-changer.
 
Omg! Christmas has indeed come early! True CD free music support means you've made Civ2 truly portable without needing any other patches. There's so many other great GUI usability improvements here too. Well done and thank you so much!!!! :) Will share the news around the Civ2 Discord, Reddit & Facebook groups too.

There can be separate MUSIC folder in each subfolder (scenario).
Ohhh I really like you adding in this one too. Custom music playlists for custom scenarios.. awesome!!! :)

CHANGE: CDCheck patch (No-CD) now works in Smart mode. If Civ2 compact disc is present in the CDROM drive then all paths are directed to CD. Otherwise game works in local mode.
Slightly worried about this one though since I've made a bunch of mods with custom video file replacements and because Civ2 normally prioritizes local installed files it would ensure my custom videos were played even if the user had the CD in. If I'm understanding correctly it now sounds like my total conversion mods with only work properly if people don't have their CD in the drive which is a bit of a shame, guess I'll need to change my ReadMe instructions.
.
 
Last edited:
Top Bottom