[TOT] The Test Of Time Patch Project

Welcome back! This time around you'll notice there are considerably more scenarios making use of your fine work. Thanks for everything you've done! I hope you have an opportunity to try some of our creations.
 
This is excellent! I look forward to testing these new features. Thank you for your work.
 
Hi TheNamelessOne,

It’s great to see another set of enhancements to your wonderful project. The Settler feature alone should be a very welcome addition. As you may have hopefully witnessed, many great new scenarios have been produced by our community based on your work. Thank you once again!

I don’t know if you were just passing by this time or whether you were still open to some requests or questions but I thought it couldn’t hurt to ask.
  • Transport mechanism: is this still a feature that you think you will be able to release someday?
  • Assigning multiple civilizations to a single human player in ToT, other than in Hot Seat mode: I asked this question back in 2018 but to be honest I didn’t understand your reply on the following post 812 as to whether it was possible or not and if so how. Are you able to confirm?
In Napoleon, we implemented the feature that swapped the terrain files when winter came around. But we still needed to use a bat file to switch the rules.txt and potentially the units.bmp files since as I understood it at the time lua didn't support swapping these particular files.

Code:
civ.ui.loadTerrain(0, 'Terrain/wTerrain1.bmp', 'Terrain/wTerrain2.bmp')

Unless I misunderstood, would it be possible to add the ability to load unit.bmp and rules.txt files as well, whenever the scenario called for it, thereby eliminating the need to use the bat file altogether?
 
Last edited:
In Napoleon, we implemented the feature that swapped the terrain files when winter came around. But we still needed to use a bat file to switch the rules.txt and potentially the units.bmp files since as I understood it at the time lua didn't support swapping these particular files.

Unless I misunderstood, would it be possible to add the ability to load unit.bmp and rules.txt files as well, whenever the scenario called for it, thereby eliminating the need to use the bat file altogether?

Many more settings from the rules.txt are now editable via event, such as the terrain features and the advanced units settings, so you might be able to get away without using a bat file to swap the rules.txt, at least. On the other hand, having the feature to swap out any file would make it much easier remove the bat file requirement from existing scenarios, and easier for the existing talent to move to Lua.
 
Hi @tootall_2012, I compared the summer and winter versions of Rules.txt for Napoleon, and it looks to me like all of the changes you're making would indeed be possible to make with Lua now, without actually swapping Rules.txt files. As @Prof. Garfield implied, this wasn't true with TOTPP 0.15.1 but the new support for terrains in 0.16 gets us there, and I think we could eliminate the batch files entirely if you want. (You can PM me if you'd like to release Napoleon v1.4 with this enhancement -- I'd be happy to help with the Lua changes.)

I don't see multiple versions of Units.bmp in Napoleon so I'm not sure what you envision as the goal of swapping that file. It's true that TOTPP/Lua doesn't support that yet though. And while Lua provides full control for editing unittype stats, it doesn't actually allow you to change the unittype name, and it's true that loading a new Rules.txt with batch files would permit that. I'm just not sure what you have in mind as far as applying this within Napoleon or a different scenario.
 
Assigning multiple civilizations to a single human player in ToT, other than in Hot Seat mode: I asked this question back in 2018 but to be honest I didn’t understand your reply on the following post 812 as to whether it was possible or not and if so how. Are you able to confirm?
I believe this is possible, in Lua only, by setting civ.game.humanPlayers or (as of 0.16) tribe.isHuman appropriately. Based on TNO's response that you referenced, I believe the nuance is that this needs to be set every time a game is loaded -- i.e., the setting isn't preserved across save and load. I haven't tested this, but I think that should be easy enough to do by placing the Lua assignment in civ.scen.onScenarioLoaded().

There isn't a simple way at this point to have multiple human tribes in a new base game, since this can't be selected via the menu sequence (only in a Lua events file).
 
Last edited:
Hi Knighttime,

Thank you for the offer of assistance but in this case I was merely using Napoleon as a reference as to what my ultimate intention was, i.e. to have the feature that allowed the designer to swap multiple types of files such as the unit, terrain, rules or maybe even others as Prof. Garfield suggests like the game.txt file.

It just seemed to me that this would make it so much easier from a development point if you could simply swap these files instead of having to potentially code all the required changes within lua itself. Am I incorrect in this assumption?

Perhaps a better example would have been my 'A House Divided' scenario where during winter time I exchanged my summer terrain and unit files for their winter counterparts. I also used the bat file to swap the rules files because I made changes not only to many unit but also terrain stats.

Another couple of examples would be 'Second Front' by Captain Nemo or 'Operation Herbstnebel' by Darth Veda where they use the bat file to replace the rules, terrain and unit multiple times. In these cases they not only change the rules, unit and terrain bmp files themselves, but often replace units with other ones and therefore have to modify unit names and stats in the rules file (though I'm not certain if this last part would be a restriction with lua).
 
Last edited:
I believe this is possible, in Lua only, by setting civ.game.humanPlayers or (as of 0.16) tribe.isHuman appropriately. Based on TNO's response that you referenced, I believe the nuance is that this needs to be set every time a game is loaded -- i.e., the setting isn't preserved across save and load. I haven't tested this, but I think that should be easy enough to do by placing the Lua assignment in civ.scen.onScenarioLoaded().

There isn't a simple way at this point to have multiple human tribes in a new base game, since this can't be selected via the menu sequence (only in a Lua events file).

I remember bringing this up originally because I believe I had read sometime in the past that this was a feature that you could do in Fantastic Worlds.

As you may recall, at one point, I was asking if in a WWII scenario for example you could design a game where you could have a Western Powers nation (that represented, England, France and the United States) and one other power for Russia and then allow the human player to control both of them. Similarly, could you have an Italian-German power and a Japanese one both controlled by the human player.

This would allow you to control either the Allied or Axis powers as a bloc but still have different technological paths and treasuries to maintain for the powers within your bloc.
 
Last edited:
Amazing to see progress on this astounding project - We scenario designers are in your debt!

"The city & unit limit patch now uses a growable heap for the Go To dialog, this one was missed in the v0.6 release."

If this means the GoTo menu can support more than 250 cities, then this has made my day, hell, my year!
 
... I was merely using Napoleon as a reference as to what my ultimate intention was, i.e. to have the feature that allowed the designer to swap multiple types of files such as the unit, terrain, rules or maybe even others as Prof. Garfield suggests like the game.txt file.
...
Perhaps a better example would have been my 'A House Divided' scenario where during winter time I exchanged my summer terrain and unit files for their winter counterparts. I also used the bat file to swap the rules files because I made changes not only to many unit but also terrain stats.
Got it. Well, my general point is the same: I think any change to terrain stats or unittype stats is now possible via Lua, with the exception of terrain, resource, and unittype names. And terrain images could already be swapped out in 0.15.1 as you know.

To be clear, I'm not opposed to the request of being able to read in more image or text files -- only pointing out that the Lua enhancements in 0.16, especially to terrain, are pretty significant and can probably handle most of the cases that previously made multiple versions of Rules.txt necessary.

Another couple of examples would be 'Second Front' by Captain Nemo or 'Operation Herbstnebel' by Darth Veda where they use the bat file to replace the rules, terrain and unit multiple times. In these cases they not only change the rules, unit and terrain bmp files themselves, but often replace units with other ones and therefore have to modify unit names and stats in the rules file (though I'm not certain if this last part would be a restriction with lua).
Is changing unit names plus images in these scenarios primarily done as a workaround for the limit on number of unit types? Thanks to TOTPP, we certainly have a lot more unit types available now than we did when those scenarios were originally created. But I could still imagine this being an issue, because no matter how many unit types are available, designers will always need "just a couple more". :lol:

It just seemed to me that this would make it so much easier from a development point if you could simply swap these files instead of having to potential code all the required changes within lua itself. Am I incorrect in this assumption?
Well, for the case of implementing "seasons", I consider it basically a tie. Instead of having "summer" and "winter" versions of Rules.txt, you just have "summer" and "winter" functions in your events file that set the correct values appropriately. Then at every point in the event code where you think a new Rules.txt ought to be loaded, you just call the appropriate function instead. The function makes it really easy to review exactly what changes are implemented, as well, without doing a text file comparison. Actually I think the Lua functions may be a little more foolproof, too, because if you want to make a Rules update that applies to all seasons, you just have to do it in one place (your single Rules.txt file) instead of updating every Rules.txt file for each season. Seems like it could be easy for bugs to sneak in because Rules files get slightly out-of-sync in unintentional ways.

But changing individual values via Lua has some major advantages in other situations. Say that you have 7 "custom" units such as military commanders, one per tribe, and each tribe has a tech they can research which updates the stats of its own commander. But you don't know which tribes will learn their techs in which order. How many different Rules files would you need to maintain in order to cover all combinations of upgrades? Lots! (I think it's 2^7 or 128 files, hope I'm figuring that right.) But with Lua we can just set the stats for each of the 7 unittypes individually, based on whether or not the corresponding tech is known, using just a handful of lines of code.

As you may recall, at one point, I was asking if in a WWII scenario for example you could design a game where you could have a Western Powers nation (that represented, England, France and the United States) and one other power for Russia and then allow the human player to control both of them. Similarly, could you have an Italian-German power and a Japanese one both controlled by the human player.

This would allow you to control either the Allied or Axis powers as a bloc but still have different technological paths and treasuries to maintain for the powers within your bloc.
This certainly seems possible to me, and not really very difficult to set up.
 
I have a scenario I'm working on that has over 150 distinct units (meaning they don't just change pictures, but completely change ownership and placement) using lua. It just takes some planning, but it's totally possible to get far more units out of a scenario by replacing the unit types as a whole before a change in rules/art.
 
I believe this is possible, in Lua only, by setting civ.game.humanPlayers or (as of 0.16) tribe.isHuman appropriately. Based on TNO's response that you referenced, I believe the nuance is that this needs to be set every time a game is loaded -- i.e., the setting isn't preserved across save and load. I haven't tested this, but I think that should be easy enough to do by placing the Lua assignment in civ.scen.onScenarioLoaded().

There isn't a simple way at this point to have multiple human tribes in a new base game, since this can't be selected via the menu sequence (only in a Lua events file).

I dabbled in this a little while ago, what you've written here matches my memory.
 
I have a question about the images - is this the same thing you were working on a few years back where an actual image would display on the screen, much like a .DLL? I remember that you were showing Grishnach this while it was a bit unstable at the time before you took sabbatical. Are we able to display images as a "box" now, or is this new image feature something different? Thanks.
 
Welcome Back!

TY for the update! I look forward to getting my ass kicked on the extra deity levels. :D


Also, an issue I've noticed:

Playing more than one game/mod while the exe is still running causes custom mods to load incorrectly, causing the custom scenario parameters to be ignored. Same goes for quitting to main menu then reloading the save you just quit from. For example, pollution suppression would stop working, despite still showing as enabled.

The only fix is to quit to desktop and relaunch the civ2.exe itself

EDIT: Another Issue: With the new settlers Patch, automating settlers causes a game crash. Afterwards, automating settlers stopped working at all. Only fix was to turn off extra settlers flag in the TOTPP window.


EDIT 2: A 3rd Issue I have: When building a new palace/capital on another map, the palace/capital on the old map is NOT automatically deleted.

EDIT 3: I've added extra difficulty levels in rules.txt, but they're not showing up ingame.


And a suggestion: A toggleable settler flag that allows them to dig or destroy rivers.
 

Attachments

  • Rules.txt
    65.2 KB · Views: 45
Last edited:
Another Suggestion: A way to automate exploration. I know later Civ editions have this feature, but it'd be nice for Civ 2 as well :D
 
Regarding autoexploration: The main thing I hate about multi-layer settings is that you have to switch layers EVERY TILE when exploring to effectively scout around you. I would be extremely happy if the game would auto-switch (and back) to all other available layers when moving, or having a hotkey "switch to world 1" etc. to skip the annoying "which world do you want to go to" dialog.
 
Top Bottom