Gedemon's Civilization, development thread

Yes handling prisoners after capture is not coded yet.

On that side, I'd like a few suggestions for the buildings handling them and slaves...

One to convert prisoners to slave, one to house them, setting a minimal value of slave reserved to that city, and one to allow slave trading/transfer between cities.

I could use fixed values, but this setting allows you to decide what to do with prisoners.

I could use some other buildings to convert prisoners (especially barbarians) to personnel (for your army) or citizen.

My first thought was that this shouldn't be too complicated, or require special buildings other than the Slave Market... it might crowd the building list with basic utility items. But I see your point about wanting to allow the player to direct the slave population somewhat.

What you could do is use the Slave Market for prisoner housing (and transfer), but give standard industry buildings the conversion power. So a city with a Slave Market that is also well developed in basic industry (granary, mill, butcher, workshop, etc) would be more efficient at converting slaves to lower tier population, while a less developed city (with slave market) would overflow and passively transfer elsewhere. It would be interesting if tile improvements (farms, mines, etc) could also contribute to conversion, so smaller cities which receive prisoners would still get a measured benefit. Together, this would have the effect of larger population centers gradually pulling slaves from the frontier.

Military buildings (barracks, etc) could handle direct conversion to personnel, serving as an alternate sink for the raw slave population. So a player might choose to develop military over industry in a frontier region where they want to direct the slave population towards personnel instead. I guess you'd need to use policies for +/- conversion rates, since there's no apparent method to remove buildings when they're no longer relevant (i.e. the frontier expands and cities change focus).

Having a great time with the mod.. Even at this early stage, the systems you've introduced create a lot of integration between city and military management, which is otherwise absent. I poked my head back into civ6 to see if there were any substantial improvements, and was very pleased to find this project :). Some questions and bug reports to follow...
 
A couple of observations... not sure what constitutes a bug at this point and what's simply a loose end:

- Tiles acquired through cultural border expansion aren't considered by some base game systems, until after a reload. Examples: pantheon benefits don't apply (+1 culture to pastures, food to camps, etc); neutral units aren't removed from acquired tiles after border enforcement;

- When in certain overlay UI modes (citizen management, lenses, etc), activating one of the new tooltips on either a unit or a city banner will create an awkward toggle state until you manually exit the mode.

Those are the only outstanding issues I came across in a week or so of playing. Everything is clean, clear and well implemented, including tooltips and the new city UI panel. It takes a while to get comfortable with the mechanics, but all of the necessary information is present. I might suggest (at some point) adding a tooltip for converted resources (grain to food, livestock to food, etc) that shows the related building and rate of conversion, maximum output and such. That way it's easier to check if everything adds up, and demonstrates what the new buildings are doing.

And a question: Could you clarify the meaning of 'cost' in the resource stock, import/export routes and internal transfer routes sections of the new City Details panel? I'm guessing that the stock panel is showing price per unit when exported (i.e. cost to the buyer), but for the route sections it's apparently "transfer cost", so I'm a little uncertain.
 
Thanks for the feedback !

I suppose I could code some new projects to remove buildings, but it will be simpler to use policies until I can give the players a way to change cities settings without using buildings.

I've no idea if the first bug can be fixed with the current modding capabilities, but I'll have a look at the second.

The "cost per unit" is the local cost of a resource in the current city.

I'm not sure how to translate this in the UI, but here is more info about the "cost":

Each resource class has a base value (may change that to a value per resource instead of per class), 0.5 for bonus, 2 for strategic and 3 for luxuries.

Collecting a resource has a cost factor based on city wealth, the presence of an improvement and if the plot is currently worked by a citizen.

The "transport cost" is added to the "cost per unit" when moving a resource from one city to another. That cost is dependent of the type of route and it's length (ie: efficiency)

Each turn the cost is updated in each city based on supply and demand in that city.

ATM the cost is only used to calculate the import/export transaction (it doesn't "cost" gold for your civilization to import resources, on the contrary it generates income, a percentage of the transaction, which is more important for exporting)

You're not using the resource, the trade is made by the cities.

But in the future, you'll need some manufactured goods to produce buildings or units, those will be made from the resources, and at that moment you'll have to buy them. Which means it won't cost you the same amount of gold to make a Swordsman unit near a city with an Iron Mine and a low wealth level than in a wealthy city which import iron materiel from far away.

The cost will also be used when determining citizen needs (imagine having enough food in a city, but the lower class can't buy it) and so, stability.
 
Thanks, that helped :). I'm finding the system is much easier to observe playing on small maps with few opponents, but slowest game speed.

A few other notes...

-- city garrison and defenses aren't replenishing, neither passively nor with the 'repair outer defenses' project (it never progresses). I haven't played in a while (until now), so I have no idea whether this is a vanilla problem... garrison/defense repair was always a little buggy. I've just been fixing them with the console. Do you have an alternate plan for defense maintenance that involves personnel and materials?

-- entering a goody-hut tile prior to settling your first city causes a CTD

-- when founding a new city in an area that includes tiles previously acquired through culture spread, you have to take ownership of those through 'citizen management'
 
First one is as far as I know a problem in vanilla if you have a city with Industrial+ walls without ever having built a wall there.

Last one is 100% certain something in vanilla.
 
First one is as far as I know a problem in vanilla if you have a city with Industrial+ walls without ever having built a wall there.

Last one is 100% certain something in vanilla.

Yeah, I think the wall repair project won't show up in vanilla under certain circumstances, due to tech/era logic. Here though, the project shows up, but doesn't function (ever). I figure there's an alternate plan for this mod anyway.

With the tile ownership, I suppose it might come up in vanilla, but border growth beyond 3 hexes takes ages, and that area tends to be settled by that point. Here you can found a new city very early that's completely in owned (unshared) territory. It ends up surrounded entirely by tiles it can't work by default, so I'm wondering how AI players handle that. I don't remember if that was the case with the RED dll or Cultural Diffusion projects for civ5... I don't recall coming across it.
 
Yeah, I think the wall repair project won't show up in vanilla under certain circumstances, due to tech/era logic. Here though, the project shows up, but doesn't function (ever). I figure there's an alternate plan for this mod anyway.

With the tile ownership, I suppose it might come up in vanilla, but border growth beyond 3 hexes takes ages, and that area tends to be settled by that point. Here you can found a new city very early that's completely in owned (unshared) territory. It ends up surrounded entirely by tiles it can't work by default, so I'm wondering how AI players handle that. I don't remember if that was the case with the RED dll or Cultural Diffusion projects for civ5... I don't recall coming across it.

I came across an AI city settled in the 4th ring in one of my games, and as for how they handle that... They don't. The city was locked size one because it didn't have any tiles to work. But that's on Firaxis to fix, really.
 
I'll try to fix it by giving the tiles in the 3 rings around a new city to that city if
- the tile belong to the same player
- the tile belong to another city, but the new city is closer

edit: and yes, I plan to use material for city "healing", so that will fix the problem with city wall repair project.
 
Update on Github
Code:
add resources conversion and resources stock to buildings tooltips.
raise Food stock value per City size.
tweak Morale change from distance to home
add Horem's Building Icons for Herbalist, Butchery, Blacksmith
remove Campus, Commercial, Entertainment, Theater and Holy District
Market, Bank and Stock Exchange get 1 trader capacity.
remove faith from yields, buildings and units
update the syntax of the .modinfo file
show resources that have supply/demand in the city screens even when their actual stock is 0
when creating a new city, update plot ownership around the city to make sure it gets the complete first ring and all the closest non-worked tiles.
 
I need your help !

I've started to implement the citizen needs (housing to regulate birth rate), but I've got some data corruption in saves after ~15-30 turns (resulting in unit flags not shown on reload) and CTD when exiting a game (either to main menu, to desktop or reloading a save from ingame)

Are you experimenting the same issues with the GitHub release ? (it would give me a starting point to investigate)
 
I think it's solved: do not divide by zero, ever. It may sound fun, but the serializer doesn't handle the result very well...
 
Fixed a few more things related to saved data, and new update on GitHub
- add Housing needs for population, affecting Birth Rate
- add 3x3 buildings to add Housing to a city (the "Housing" values from the mod are different from the "Housing" values of the base game)
multiple bug fixes

I'll work on the UI for the Population Needs next, ATM the information is only available in the Lua.log

There are 3 classes of Housing: Wealthy, Normal and Cheap.

Upper class population will use Middle Class Housing if there is no Wealthy Housing available, and Middle Class population will use Cheap Housing if there is no Normal Housing available.

The Housing value for the buildings is equivalent to city size, a city start with 3 housing (enough for a Size 3 city), each of the test building add 1 more, the population size use the same formule as for Civ5: population = math.pow(CitySize, 2.8) * 1000

Size 1 = 1000
Size 2 = 6964
Size 3 = 21674
...

When there is more than 50% of specific housing available for a population class (Wealthy for Upper, ...) that class get a Birth Rate bonus
When there is less than 25% of total housing available for a population class (Wealthy and Normal for Upper, ...) that class get a Birth Rate penalty

bonus/penalty are directly relative of the value of housing left.

Note that if the Upper Class has to use some Normal Housing, that part is not available for the Middle Class.

For almost every needs, the upper class will take its full part first, but for some specific needs (like food), rationing may be used.

There is no effect coded for surpopulation yet, that will come with Health.
 
Some belated commentary from the previous commit(s)...

add resources conversion and resources stock to buildings tooltips.
This is much better. It helps a lot when trying to gauge efficiency, which I think is the primary gameplay challenge posed by the mod. No?

raise Food stock value per City size.
I've only played some partial games (@marathon) thus far, but population growth seems less "sticky"... previously, some cities would hit a wall that was hard to climb. Either that, or it's easier to prioritize food conversion buildings, in the absence of most districts. Maybe both.

add Horem's Building Icons for Herbalist, Butchery, Blacksmith
I think I remember these from Horem's mod. It's a shame there isn't a better showcase for icon artwork in VI. Anyway, they're a good fit.

remove Campus, Commercial, Entertainment, Theater and Holy District Market, Bank and Stock Exchange get 1 trader capacity. remove faith from yields, buildings and units
I briefly played an intermediate update, before you added traders to commerce buildings. Those turned out to be useful ;-)

when creating a new city, update plot ownership around the city to make sure it gets the complete first ring and all the closest non-worked tiles.
This seems to be working well. I noticed that tiles outside the first ring are also acquired, where appropriate. Will keep an eye on it.

Having a go with the latest version now...
 
Thanks, I'll have a look, I've launched some autoplay (a first with this mod) games after updating gitHub, and all three of them crashed between 100-200 turns, could be linked.
 
New one, yes, thanks, seems that the ReportScreen.lua file use a hardcoded table for the yields, not allowing new types to be added in the game's DB.

The 3 news Housing types are not really "Yields", but "Health" will be, and I will include and edit ReportScreen.lua for the new mechanisms anyway, so I'll fix it then.
 
What are your plans with districts?
 
What are your plans with districts?
I'll keep some as they are (airport, space port), I think that I'll keep all commercial, cultural and scientific buildings in the city center, but I'd like to be able to expand the city center on adjacent tiles (with a limitation on the number of buildings in a city depending on the number of "expansions")

I'd like to have early military and production buildings in the city center, but also keep the corresponding districts for industrial and later ages buildings.
 
The autoplay tests have indeed shown a few issues, so here are some fixes on GitHub:

- fix a possible cause of crash when a city change owner (don't set ObsoleteEra to "ERA_ANCIENT" for a building...)
- optimization : only keep city statistic data for the last ten turns
- fix bug preventing flag creation for units using fuel
- few other bug fixes

About optimization of the table, I knew that I'll had to do it at some point, but it could already reach a million entries in the late game and took more than 10 sec for serialization and check... on a small map.

Now it's back to 0.3 seconds, much better.
 
Top Bottom