Here is a list of slic triggers which would make Ctp2 a better game. Most of these triggers should be able to be used with any mod, so those of you working on your own mods will benefit from making these just as much as the rest of us.
1)A trigger to keep units from bombarding underwater units unless they can also attack underwater units.
This will keep subs from being killed by air or naval units like Battleships when they are accidentally discovered by those units. I asked for a "Bombard Underwater" flag way back when I was a beta-tester, but I guess the game was too far along for them to put this flag into the game.
Note: I think I have come up with a setup which will make the creation of this trigger unnecessary.
2)The AIs have a habit of running their planes out of fuel and losing them. I will give planes enough fuel for two turns, plus one more space to take into account the fuel used when attacking. I need a trigger to make the AIs return their planes to the nearest city, airbase or Carrier if they do not begin their turn in a city, airbase or Carrier.
3)I have changed several wonders in the game to give improvements in every city. I need a trigger that removes the option to build improvements if a civ has a wonder that grants that improvement to every city. This has been discussed before, but I don't recall the options to disable this "feature".
4)Locutus, I believe, had asked before about clearing orders, and I think that this is a good idea. What I would want is a trigger to clear all unit orders say, every 3 turns, and another trigger to clear orders whenever an AI civ loses one of its cities. If this is hard to do, then a trigger which makes the seige goal the highest priority whenever a city is lost may work just as well.
5)I need a trigger to disable the Start Strategies after 125 turns. I just want the AI to use it's default personality strategy when at peace, and the three war strategies when in that state.
You see, I have added some things to the Start strategies that should help the AIs at the start of the game, but these settings will interfere with the other strategies if they are in play for the entire game.
Locutus: Oh, wait a minute. I misunderstood what you meant by Start strategies, but now I get it. I think reloading the standard personality strategy (with SetStrategicState) after 125 turns or whenever you want will undo the changes of the Start strategies. I think this can be done.
6)On another note, I would like to change the way buildings are obsoleted. Right now, they are obsoleted (and destroyed) upon discovery of the advance which gives their replacement. I want to change it so that they are destroyed when their replacement is built. Charles mentioned that something similar to the militia code would seem to be able to do this.
This is a trigger that I would like to be in place for the beta.
7)Richard: However, if you force the AI to declare war and make sure the diplomatic state for the AI (in
diplomacy.txt) will refuse peace that should do what you want. So how do you foce the AI to declare war? Sigh, I have a function to do this, but I forgot to expose it via SLIC. However, there is a fun way
you can do this. Create a new goal (maybe called
GOAL_PROVOCATION) that looks a lot like an attack goal, but in which the TargetOwner: is ColdEnemy rather than HotEnemy. This will cause the AI to preemptively attack, and once at war it will stay at war as long as it never makes or accepts a ceasefire. You'll have to add the goal to everyone, but only set it to have maxeval > 0 for beligerent AI. You could also swap in a strategy specifically that enables this
goal only when the AI has military superiority.
WesW: I would like a trigger to swap in a strategy that enables this goal when they have military superiority. I will set the MaxEval > 0 for Militaristic and Ecotopian AIs.
WesW: I thought that there were settings in the game already to determine relative military strengths. Doesn't the AI use these in deciding whether to declare war, or what war strategy to use?
Locutus: You're right. MilitaryRank can be used for this. I didn't think of this yet, it's hardly ever useful for anything but it's perfect now. Should be fairly simple then.
8)On a more general comment, don't you think it would be good to have embassies more permanent even if you don't get the wonder? I think it would be worth it to write some SLIC so that if you make peace with a civ you'd had an embassy with before the war, the embassy is automatically reinstated.
This next trigger is specifically for the Med mod, but of course it can be used by others if they so desire.
Wouter, below is an excerpt from a letter Harlan sent me about the wonder-units. We were discussing alternate ways of granting the units rather than using wonders. Read this over, and let me know if you think it can be done via slic, and if it would slow the game down much. We would need to scan the 9 squares within each city's initial radius for this to work.
> What would be really cool is if you base the odds of getting each special
> unit not on pure chance, but on appropriateness for the civ. For instance,
> you could use a quick analysis of the terrain the civ's cities are on (or
> terrain immediately adjacent to the city) when they reach the tech for the
> unit. The higher percentage of cities on the coast, the more likely they
> can get an ocean special unit, for instance. The more cities on jungle,
> the more likely they get War Elephant. The more cities on Plains, the more
> likely they get Nomad Horseman. Forest for Longbowman, Hills for Hoplites,
> etc... This has several advantages. 1) You won't get AI civs building
> wonders that will lead to units they don't need. For instance an inland
> civ building a naval unit enabling wonder. 2) It solves you War Elephant
> problem- no need for extra code there. 3) Chances are greater these
> special units will actually be useful for the civs that can build them.
>
Locutus: This is definitely possible, no doubts about that. I don't even think it's gonna be very expensive if you implement it properly: Harlan suggests checking terrain when a civ discovers the appropriate tech, but one could also calculate the odds every time a city is founded, captured, destroyed, etc. and store the results in a small array (and read that array when the advance comes available). So instead of doing all the calculations at once, you're spreading them over the entire game (as long as there are still special units to be aquired).
I could even include a check for changes in city radius size and not only check for the tiles immediately surrounding the city but the entire city radius, though that would cost some extra resources since changes in city radius occur relatively often (though usually not for more than 1 or 2 cities at a time/turn so if there's a slowdown at all it's a minimal one).
WesW: This sounds great, Wouter. All the special units occur before the Renaissance age, so city radii should not be more than 2.
Additional triggers I would like to see in the Med Pack II:
1)A refugee trigger which takes a quarter of a city's population and disperses it among the other cities of a civ when a city is lost to conquest.
2)A trigger to destroy a percentage of all the buildings in a city when that city is captured by assault, ala civ2. Right now, all you can lose is one building during assault, which is totally unrealistic when you look at what happens to a city during warfare.
[This message has been edited by WesW (edited February 15, 2001).]
1)A trigger to keep units from bombarding underwater units unless they can also attack underwater units.
This will keep subs from being killed by air or naval units like Battleships when they are accidentally discovered by those units. I asked for a "Bombard Underwater" flag way back when I was a beta-tester, but I guess the game was too far along for them to put this flag into the game.
Note: I think I have come up with a setup which will make the creation of this trigger unnecessary.
2)The AIs have a habit of running their planes out of fuel and losing them. I will give planes enough fuel for two turns, plus one more space to take into account the fuel used when attacking. I need a trigger to make the AIs return their planes to the nearest city, airbase or Carrier if they do not begin their turn in a city, airbase or Carrier.
3)I have changed several wonders in the game to give improvements in every city. I need a trigger that removes the option to build improvements if a civ has a wonder that grants that improvement to every city. This has been discussed before, but I don't recall the options to disable this "feature".
4)Locutus, I believe, had asked before about clearing orders, and I think that this is a good idea. What I would want is a trigger to clear all unit orders say, every 3 turns, and another trigger to clear orders whenever an AI civ loses one of its cities. If this is hard to do, then a trigger which makes the seige goal the highest priority whenever a city is lost may work just as well.
5)I need a trigger to disable the Start Strategies after 125 turns. I just want the AI to use it's default personality strategy when at peace, and the three war strategies when in that state.
You see, I have added some things to the Start strategies that should help the AIs at the start of the game, but these settings will interfere with the other strategies if they are in play for the entire game.
Locutus: Oh, wait a minute. I misunderstood what you meant by Start strategies, but now I get it. I think reloading the standard personality strategy (with SetStrategicState) after 125 turns or whenever you want will undo the changes of the Start strategies. I think this can be done.
6)On another note, I would like to change the way buildings are obsoleted. Right now, they are obsoleted (and destroyed) upon discovery of the advance which gives their replacement. I want to change it so that they are destroyed when their replacement is built. Charles mentioned that something similar to the militia code would seem to be able to do this.
This is a trigger that I would like to be in place for the beta.
7)Richard: However, if you force the AI to declare war and make sure the diplomatic state for the AI (in
diplomacy.txt) will refuse peace that should do what you want. So how do you foce the AI to declare war? Sigh, I have a function to do this, but I forgot to expose it via SLIC. However, there is a fun way
you can do this. Create a new goal (maybe called
GOAL_PROVOCATION) that looks a lot like an attack goal, but in which the TargetOwner: is ColdEnemy rather than HotEnemy. This will cause the AI to preemptively attack, and once at war it will stay at war as long as it never makes or accepts a ceasefire. You'll have to add the goal to everyone, but only set it to have maxeval > 0 for beligerent AI. You could also swap in a strategy specifically that enables this
goal only when the AI has military superiority.
WesW: I would like a trigger to swap in a strategy that enables this goal when they have military superiority. I will set the MaxEval > 0 for Militaristic and Ecotopian AIs.
WesW: I thought that there were settings in the game already to determine relative military strengths. Doesn't the AI use these in deciding whether to declare war, or what war strategy to use?
Locutus: You're right. MilitaryRank can be used for this. I didn't think of this yet, it's hardly ever useful for anything but it's perfect now. Should be fairly simple then.
8)On a more general comment, don't you think it would be good to have embassies more permanent even if you don't get the wonder? I think it would be worth it to write some SLIC so that if you make peace with a civ you'd had an embassy with before the war, the embassy is automatically reinstated.
This next trigger is specifically for the Med mod, but of course it can be used by others if they so desire.
Wouter, below is an excerpt from a letter Harlan sent me about the wonder-units. We were discussing alternate ways of granting the units rather than using wonders. Read this over, and let me know if you think it can be done via slic, and if it would slow the game down much. We would need to scan the 9 squares within each city's initial radius for this to work.
> What would be really cool is if you base the odds of getting each special
> unit not on pure chance, but on appropriateness for the civ. For instance,
> you could use a quick analysis of the terrain the civ's cities are on (or
> terrain immediately adjacent to the city) when they reach the tech for the
> unit. The higher percentage of cities on the coast, the more likely they
> can get an ocean special unit, for instance. The more cities on jungle,
> the more likely they get War Elephant. The more cities on Plains, the more
> likely they get Nomad Horseman. Forest for Longbowman, Hills for Hoplites,
> etc... This has several advantages. 1) You won't get AI civs building
> wonders that will lead to units they don't need. For instance an inland
> civ building a naval unit enabling wonder. 2) It solves you War Elephant
> problem- no need for extra code there. 3) Chances are greater these
> special units will actually be useful for the civs that can build them.
>
Locutus: This is definitely possible, no doubts about that. I don't even think it's gonna be very expensive if you implement it properly: Harlan suggests checking terrain when a civ discovers the appropriate tech, but one could also calculate the odds every time a city is founded, captured, destroyed, etc. and store the results in a small array (and read that array when the advance comes available). So instead of doing all the calculations at once, you're spreading them over the entire game (as long as there are still special units to be aquired).
I could even include a check for changes in city radius size and not only check for the tiles immediately surrounding the city but the entire city radius, though that would cost some extra resources since changes in city radius occur relatively often (though usually not for more than 1 or 2 cities at a time/turn so if there's a slowdown at all it's a minimal one).
WesW: This sounds great, Wouter. All the special units occur before the Renaissance age, so city radii should not be more than 2.
Additional triggers I would like to see in the Med Pack II:
1)A refugee trigger which takes a quarter of a city's population and disperses it among the other cities of a civ when a city is lost to conquest.
2)A trigger to destroy a percentage of all the buildings in a city when that city is captured by assault, ala civ2. Right now, all you can lose is one building during assault, which is totally unrealistic when you look at what happens to a city during warfare.
[This message has been edited by WesW (edited February 15, 2001).]
Comment