Additional notifications

eotinb

Ancient and Hermetic
Joined
Sep 14, 2005
Messages
409
Location
Buffalo
I'm soliticing ideas for some additional in-game notifications for a mod I'm working on. There are certain events that I for one would find helpful to be automatically informed about that aren't at this point. For example, when I start the game, I usually have the capital start on a warrior, but if I'm not going for a religion, I usually switch to a worker as soon as it grows to size 2. But at the same time, I'm off exploring with my warrior or scout, so I can miss the growth. It's pretty easy to mod an event that makes a noise and gives you one of those icon arrows when a city grows -- problem solved. Are there other things like this that people would like to be notified of?

Here is my initial list:
1. City growth
2. New trade opportunities available (resources and techs)
3. City about to grow unhappy/unhealthy
4. City is unhappy/unhealthy (although I'm not sure about this one as it could get pretty annoying)
5. City set on "no growth" has extra healthy/happy margin
6. War weariness increases in a city

My reasoning on the items above:
1. Already discussed
2. To prevent checking the foreign advisor every turn. Would inform you when you learn a tech that you can trade, when an opponent learns a tech you don't have and they are willing to trade it, and when they become willing to trade a tech you don't have (same for resources, just substitute "hook up" for "learn")
3. There are situations when you may not mind letting a city grow unhappy or unhealthy, but I often like to turn on no growth to prevent this. homegrown's excellent domestic advisor improvement helps, but you still have to check it every turn and I'd like to avoid that inconvenience.
4. If you lose access to a resource or unhappiness grows from war weariness, a city can go unhappy/unhealthy without giving you the chance of having a warning like in 3. But on the other hand, if you don't care or if it takes a while to fix the unhappiness/unhealthiness, getting notified every turn could get really annoying. Maybe this could be a notification when a city becomes unhappy/unhealthy rather than a city is unhappy/unhealthy.
5. The idea is to be the opposite of 3 above. I have found more than once that I have left a city on no growth too long after fixing whatever was causing the happiness/healthiness problems. Again, though, if you wanted to leave a city on no growth for some other reason, the notification every turn would get annoying. Again perhaps this could be a notification when a city comes out of unhappiness/unhealthiness.
5. Could be usefull to keep track of indepedent of how it affects the happiness margin in a city.

Most of these ideas were taken from the alerts in CivAssist2, by the way.
 
In principle the idea sounds good.
I would be mainly interested in warnings about 1 and 3.

Only problem I see might be 'overkill' of pop ups on screen. There are already lots of them as it is. And that makes it easier again to just ignore them.
So less might be more here.
 
City Growth - I haven't found much use for this, other than starting my 1st worker when the first city grows to 2.

The others are good. The ability to turn them on/off is also a nice feature
 
What I'd like is an "Advisor Summary" that would come up at the beginning of each turn to tell me things like:

"You're military is ranked number 5 of 7, you'd better build it up."

"Cities with unhappy citizens: Tours(2), Marseilles(3)"

"Cities that are unhealthy: Tours(-3), Paris(-1)"

"Cities that don't have the state religion: London"

"Cities that have weak defenses: Rheims(1 warrior), Tours(none)"

It would just be a single popup at the begining of each turn. I'd really like to be able to write code that determines some of the things like the military strength warning, and probably a few other sorts of things that don't come to mind right now. I'd even be willing to learn Python to do so (I'm a long-time Perl user).

What would also be really nice would be to have another screen that I could bring up to give info to the code that runs the Advisor Summary. Something like having a radio button for my current overall plan (Building, Preparing for War, Fighting a War, etc), so the advisor could tailor it's info accordingly (e.g. I need more military strength when preparing for war than when I'm just building).

Then I'd want to be able to modify the city governer AI so it will key its builds (assuming auto-production queue is turned on) based on my current plan. I'd like to be able to use the city automation, but I currently don't trust it because I can't tell it what I'm trying to do overall.

Then I'd want to modify the worker AI... Ok, enough for now. A per-turn summary would be a great start. :)

Keith
 
zienth, as a long-time Perl user, I expect you'd find Python pretty easy to pick up. I'm not a long-time anything user -- more of a dabbler, and I can do quite a bit in Python without too many hours of reading and trial and error. What you are looking for is perhaps a bit beyond what I had in mind (although I think it's a great idea), so don't wait for me to do this. I suggest either checking out homegrown's improved domestic advisor mod and/or doing it yourself. I'm certainly happy to pass along anything I've learned about the cIV Python code if you get stuck.

What you want to do wouldn't be too hard (except for the Advisor controller and the city governor -- I have no idea how hard those would be). Most of that information is already there and accessible, just not necessarily in the format in which you'd like to see it. If you decide to do this yourself, check out PyHelpers.py and the advisor screens (CvDomesticAdvisor.py, etc.).
 
Cool. Thanks for the reply. I guess I should start digging around in the python code. Is there anyplace that describes how the directories are organized, or a basic primer on doing mods? I haven't been paying much attention to the mods forum up until today, and I want to understand the right way of making changes.

I think the hardest part will be sitting in front of my computer at home and not playing! :)

Keith
 
Progress has been delayed by a few things (GOTM, etc.) but I plan to get back on track soon. Almost everything I have either figured out how to do or should be pretty easy -- the challenge is going to be new trade opportunities, but I don't want to release without this feature as it's one of the main reasons I want to make this mod.

Thanks for asking.
 
Blazer6, I don't understand. Units that are set to heal spring back to active once they are at full HPs. Other than this, what would trigger "can now be put to use"?
 
I mean move them around. By then, the borders might have expanded and the workers are threatened by barbarians.
 
eotinb said:
Progress has been delayed by a few things (GOTM, etc.) but I plan to get back on track soon. Almost everything I have either figured out how to do or should be pretty easy -- the challenge is going to be new trade opportunities, but I don't want to release without this feature as it's one of the main reasons I want to make this mod.

Thanks for asking.

Not sure what you need help with, but it shouldn't be hard to do the trade opportunities. In fact, I was going to work on the Foreign Advisor next after I finished the Domestic Advisor.

If you need some help, I could help you out.

Oh yeah, great idea for a mod.

Req
 
Well, the trouble is that there is no event. Instead, I am working on creating an array of every trade opportunity and checking it each round to see what, if anything has changed and reporting that, before updating the array. It's not hard, exactly, but it's much more trouble than responding to an event. I got as far as creating the array of what I could trade to the AI and took a first pass at the opposite before I got stuck yesterday and wanted to play some. That was the last time I looked at it. If I can't figure out what went wrong next time I look at it, I'll be sure to ask you for any insight you my have Req.
 
The Foreign Advisor is a big improvement, but I'd really like an easy way to see how much gold each opponent has. I often end up checking this every turn. I'm not sure how this ties into the notifier, but maybe you can think of something. It would be great to see not just the current value but the trend. Maybe you could generate notifications when an opponent's gold goes up or down by more than some threshold.
 
Excellent idea DaviddesJ. At the very least it would be nice to see in the Foreign Advisor how much gold the other civs have (but that will have to be another mod -- maybe in Req's revisions to the FA he hinted at...). But some notification that another civ has a lot of money would work well (and I should have thought of this since that's one of the alarms in CivAssistII, which is the source of many of the ideas for this mod). Wonder what the threshholds should be... Any suggestions?
 
eotinb said:
Any suggestions?

I'd follow civassistII in this case. They used some percentage (10% or something) of your total commerce (tax + science) income, I think. The exact percentage might be a difficult number to balance, but I really think it should be a percentage.

I know the threshold is mentioned somewhere is the CivassistII thread, but Civ4 might be pretty difficult in this respect, so that percentage might not be the best choise.

Thank you for creating this mod-utility type of thing (how do you name it?).

edit: I looked it up in the online help of CivassistII and it said the following:

"Rival has lots of cash: This alert reports all rivals who have gained a substantial sum of money in the last turn. To allow this to scale as the game progresses, the tolerance is set to 10% of the cost of the technology that you are currently researching. "

This relation to the cost of a technology was probably chosen because in Civ3, technologies were often traded for money or gold per turn. In civ4 that is less likely to happen. The cost of a technology can however still offer you something to use as a reference point. The value of 100gp is very different when you're researching techs of 200 research points compared to when you're researching techs of 20000 research points.
 
eotinb said:
Well, the trouble is that there is no event. Instead, I am working on creating an array of every trade opportunity and checking it each round to see what, if anything has changed and reporting that, before updating the array. It's not hard, exactly, but it's much more trouble than responding to an event. I got as far as creating the array of what I could trade to the AI and took a first pass at the opposite before I got stuck yesterday and wanted to play some. That was the last time I looked at it. If I can't figure out what went wrong next time I look at it, I'll be sure to ask you for any insight you my have Req.

Ah, I see. Yes, it would be easier if they had an event like that, but unfortunately, they don't. So, pretty much your way is the correct way. Yeah, if you need someone to bounce ideas off of, of check your code, send me a buzz ;).

eotinb said:
Excellent idea DaviddesJ. At the very least it would be nice to see in the Foreign Advisor how much gold the other civs have (but that will have to be another mod -- maybe in Req's revisions to the FA he hinted at...).

Hehe, yup, that definitely was one of the first things on my list. Technologies that they were willing to trade in one glance was another one.

Req
 
eotinb said:
Excellent idea DaviddesJ. At the very least it would be nice to see in the Foreign Advisor how much gold the other civs have (but that will have to be another mod -- maybe in Req's revisions to the FA he hinted at...). But some notification that another civ has a lot of money would work well (and I should have thought of this since that's one of the alarms in CivAssistII, which is the source of many of the ideas for this mod). Wonder what the threshholds should be... Any suggestions?

I'd set some thresholds and generate an announcement when an opponent crosses one. My first thought is to set thresholds at 100 gold, 200 gold, 300 gold, up to 1000. Then at 2000 gold, 3000 gold, etc., up to 10000. And so on.
 
Requies said:
Hehe, yup, that definitely was one of the first things on my list. Technologies that they were willing to trade in one glance was another one.

I don't understand this. The Foreign Advisor already shows which technologies your opponents have, and which of those they are, or are not, willing to trade.
 
Back
Top Bottom