Discussion in 'Rhye's and Fall of the Greek World' started by bluepotato, Jan 18, 2020.
I tried adding the Celtiberians and managed to add them as a civ and I recompiled the DLL with the only change in CvDefines.h to make the number of max players higher. But I drastically failed in adding them the WBS, the coordinates are really weird, they show no representation to the ones on the map and it gave me an error when I click select on the 4400 BC scenario. Also I decided to rather just work on my other projects.
But I do have a question, do you plan on ever adding corporations? If you ever add corporations you could use the mechanic in DoC, that corporations auto spread themselves and disappear sometimes.
A nice thing about this RFGW version is that this isn't necessary. The number of max players is already one lower than the actual number of players, as the DLL can simply recycle player slots.
Well they do, it's just that not every tile is stored in scenario files because not every tile has stuff on it. Also map data is separated from scenario-specific data, so you don't have to edit two files just to change one tile. But generally the JSON representation was never meant to be edited by hand (except for me moving stuff to the new format), it's just that I still haven't made GUI editors for everything in the worldbuilder.
And that's precisely why, this version of python has no built-in JSON parser, so it's parsed by simplejson. And while it works, it won't tell you where the problem is when it doesn't like something (well now that I think about it, it isn't so much different from the default scenario parser after all ). I could add some better error handling but at this point it's way more useful to just add more user-friendly interfaces to the WB.
I'm not planning to add them, and there's tons of other things I do plan to do. But if I ever run out of ideas I might consider it.
I'm about to pull away from Civ again for a while - we are finally out of Covid lockdown down here and it looks like work and delayed projects are going to take my energy for most of the rest of the year - but I thought I'd note a couple of things before I go:
When a city spawns or flips, the defending unit(s) are pushed one square SW; the new city is therefore undefended for its initial turn. If there are hostile units poised within reach, they can capture the city unopposed. This was handy for e.g. Sumeria since I had units within my cultural boundary just one square SE of Agade, and nabbed the city as soon as it appeared. It also explains why the defender of Larsa appeared to be coming for me when that city appeared - Ur is SW of Larsa and the unit just got pushed there.
Looks like some factor, probably the Macedonian UP (city culture is converted upon capture) is suppressing the pop-up that gives the human player the option of razing a newly captured city if the original (not necessarily the current) owner has culture in the city. Sometimes a 1-pop city will auto-raze, but that is unreliable and may just indicate the original owner never developed any culture. This is awkward for Alexander when e.g. the AI has founded a city in a rubbish location or the city is preventing a better city from growing. Testing by experimentation: use WB to reduce current city culture to 0 = no pop-up; set city owner to be original owner (so that aboriginal culture is revealed) and reduce that culture to 0 = pop-up.
Hope that gives you enough info to track down root causes.
Anyway, bye for now; looking forward to seeing where things are up to later in the year.
Small status update: I've fixed quite a few bugs today (actually pretty much all I know of), so those using the development version are strongly encouraged to update.
I've also updated the opening post, and removed the download link to the old beta version because there's absolutely no reason to use that and it was probably causing confusion.
Edit: finally RFGW scenarios can store building data of cities as well. This involved moving a bunch of objects from the stack to the heap because building data wouldn't fit into the stack (I may be wrong here but I think that was the problem; the error reporting in this game isn't always very specific about what went wrong...). So there were even more opportunities for me to mess something up.
And while I don't think I did (test autoplays worked fine at least), just in case anybody happens to run into a memory allocation failure, please report it.
Edit2: unsurprisingly I was wrong, I ended up finding two memory leaks, at least that's fixed now.
@Autumn Leaf Well we look forward to seeing you when you return. Perhaps you might fancy writing a UHV for one of the Civs, you seem better at coding then me. Plus the more UHVs are written the easier for me to write them (as tweaking exisiting UHVs is easier then writing or importing them from another R&F mod.
@Louis the XIV Sad you weren't able to add the Celtiberians, but I do get it. You seem to have your fingers in many pies on this forum (I hope that saying translate over okay)!
@bluepotato So you are planning to implement the 900 BC scenario fully? Do you have any plans for what you might do after that?
Yeah, code-wise at this point there's not much left in the way of a fully functioning 900 BC, so I'll finish it sooner or later. However it might take a while due to real life.
A few more RFGW-specific interfaces for the WorldBuilder (unit, city and civilization editors), but other than that & bugfixing I don't have much more planned for 2.0. After that, 2.1 will be the AdvCiv merge, we'll see how that goes.
I am pretty excited for the 900 BC scenario to work! I finally won't have to wait an eternity to play as the Huns.
I have an idea though, when playing with the Byzantines or Huns it says in the corner of the screen about 50 Turns Left! Well that is very annoying because it just reminds you that you might build a huge empire as the Huns/Byzantines and then the game ends. So an idea could be to remove it or maybe give a little more time for the Huns to conquer what they conquered.
I've done some work on 900 BC today, so it's somewhat playable now (at least there are no game breaking bugs). Also, Egypt's city name map was a mess so I completely redid the Lower Egyptian city names. Well actually most city name maps are still in a pretty bad condition, but this one was a low-hanging fruit with the amount of easy to find resources on Egyptian cities online.
I've left 900 BC's suffix as Work in Progress because it's still unbalanced and untested. Plus goody huts will need to be disabled and I'll have to implement saving improvements.
I know this is a huge ask, but it would be fun to have a scenario that starts with Byzantines spawning on Turn 0. Definitely part of the appeal of RFGW is to just burn everything as the Huns, and it sucks that we have to wait so long to get that gratification. Likewise for the Byzantines game
It sure took a while, but I've finally fixed this. When units are spawned on someone's territory, the game may autodeclare on the owner of that plot if there is one. Turns out I forgot to check if that owner isn't the one receiving those units... and since unit spawning for players already in the game is generally rare (these were the Neo-Babylonian freebies), I only encountered this now while testing 900 BC.
I've thought about adding another 100 turns to the game, but for that we'd need more techs, buildings and units. Plus it'd take quite a while to balance everything again.
Later starts are quite low priority right now, but I think an AD scenario wouldn't be too much trouble to maintain once it's done. For now I'm content with the current two scenarios.
I've been thinking about human players switching civs recently. In original RFC and most of its derivatives this can be done when a new civilization starts by clicking yes on a popup.
However, I find this solution quite annoying. Usually you'd only switch civilizations if the game with your current civ has become hopelessly unwinnable, you've already won with the current civ and want to win multiple UHVs (though this is only possible in DoC afaik), or you planned to do so from the beginning. So you end up being bombarded with useless popups, with no guarantee that they will be available when you actually need them.
My idea is to instead add a button to the You have been defeated!!!/The End of History popups. This would bring up a screen where where you could select any civilization which has not started yet. After choosing a new civ, you'd be put in autoplay as normal and you'd spawn as the civ you selected on the appropriate turn.
RFC also has limitations on how close your new civilization can be, or how many times you may switch. I personally don't see why these would be necessary, so I'm not planning to add them.
This way a human player would no longer be forced to quit a game they lost, so I'd also consider changing the complete collapse mechanism to kill human civs (possibly only when the second one occurs, currently you always get to keep your capital).
After winning the game, the amount of civs you won/lost with could also contribute to your score - though I'm not sure if this is a good idea, since by choosing the right civilizations you could snowball pretty easily.
None of this is set in stone yet, and I don't think I'll add this to 2.0 because it already has enough new parts that need more testing. Thoughts and ideas are welcome.
This all sounds kinda complicated but you could start with the similar function from RevolutionDCM which is basically the same thing you just said except that you choose from existing civilizations.
I don't think it is? It's not even new, RFC does the same thing, except there's no civ selection screen (well ok we're switching to not alive civs but that doesn't really make a difference). Though you can't copy-paste this kind of stuff and expect it to work, but that wasn't my plan either.
Currently I'm more interested in what this feature should do/how it should work than how I should implement it.
The easiest way would be to copy paste the Civ Selection Screen from RevDCM and edit it to be able to choose any civ, even those that are not alive.
I feel as if the problem will be that when you select the Civ that is still in AutoPlay the AutoPlay will stop, but I might be wrong, probably.
This thought had actually occurred to me previously playing RFC style games. I've played DOC games from start to finish, while switching between civs, but this only works as long as none of your Civs collapse. If you were able to add it, it would be a nice feature
By the way when do you plan to release 2.0? I should have time to write a at least a couple of UHVs for civs over Christmas break which perhaps could be included in the 2.0 release.
There's still a bunch of things I want to add to the civilization editor (starting units, cities, techs), and I'd like to have a province editor as well (currently only their area can be edited, ideally you could add/remove provinces and modify all their attributes). And I'm sure there's still quite a few bugs to fix that I don't know of yet.
I can't really estimate how long this will take. So, to answer your question: when it's ready
Unrelated: some recent commits produced CtDs under certain circumstances. This should be fixed in the latest commit, so everybody using the development version is advised to update.
Ok, the civilization editor is done. It is a bit too cluttered (and may not work on lower resolutions), but still far more pleasant to use than manually editing JSON files. And it helped me find some displaced independent city spawns which I wouldn't have found otherwise, so looks like my suffering with UI code wasn't in vain
Currently working on Carthaginian UHVs (things are progressing well).
Glad to see the 900 BC scenario is working again.
Though there were a couple of error messages.
When playing as Carthage:
Traceback (most recent call last):
File "CvWBInterface", line 21, in writeDesc
File "RFGWB", line 506, in createSplitWBSave
File "RFGWB", line 436, in saveScenarioFile
RuntimeError: unidentifiable C++ exception
ERR: Python function writeDesc failed, module CvWBInterface
When playing as Phoenicia
Traceback (most recent call last):
File "CvScreensInterface", line 494, in forceScreenRedraw
File "CvMainInterface", line 724, in redraw
File "CvMainInterface", line 1112, in updatePlotListButtons
File "CvMainInterface", line 111, in numPlotListButtons
CvMainInterface instance has no attribute 'm_iNumPlotListButtons'
ERR: Python function forceScreenRedraw failed, module CvScreensInterface
Neither of the errors caused any obvious issues however.
Comments about 900 BC map:
1. Needs cities in Persia and India (I know this is something I originally failed to do)
2. Why is Carthage founded before the Carthaginians spawn?
3. Why does Carthage start at war with Phoenicia?
4. Phoenicia needs more of the map revealed, coast of North Africa would suffice.
Also I think the map needs more dye resources, specifically as this relates to Carthage's new UHV.
There is a map on page 3 here which shows where the main sites were:
Anyway overall the mod is looking good.
Separate names with a comma.