Opportunities

131.12 Beta includes several new opportunities. As new opportunities are added, likelihood of encountering the old ones will decrease (such as the currently very-common Scout Savior).

City-State (requires contact, peace, and medieval era or higher)

  • -200:c5gold: +50:c5influence:
  • +200:c5gold: -50:c5influence: (requires non-ally status)
  • +10:c5influence:
Warrior

  • Convert to worker with +1:c5moves:.
  • Convert to spearman.
  • Heal and +5:c5war:.
Archer

  • Convert to worker with +1:c5moves:.
  • Convert to chariot archer.
  • Heal and +5:c5war:.
 
Cool, I formulated a few more since I wasn't really getting anywhere with what I should be doing anyways... But then I was shocked when I saw that the number has reached 70... So I am getting back to my work...

Some are more chaotic, I should rephrase a lot probably and the effects are not always clear/balanced, but hey I thought I already wrote them and before I leave for the day, I can show them to you anyways... ;) There's not enough on Units, but two each on every policy tree, there's a few on City States. and oh, I did name them "Mozart" instead of "Great Musician". You can do with it whatever you want ;)

Link
 

Attachments

  • Opportunities Mitsho.rar
    21.8 KB · Views: 205
Hi Thal

As mentioned before I run a little mod of my own in conjunction with VEM. Among other things it adds two new improvement buildable on flood plains (thought they needed a boost alá CivIV). These are copies of the normal farm and trading post improvements but provide +1 food.

Looking in VETR-Triggers.xml I can see that you have two opportunities linked to farms and trading posts. I'd like to make a little alteration to VEM for my own purposes so these opportunities also apply to my new improvement types. Would the correct way of doing this with your new structure be to make a of copy both the entire trigger and outcome fields of the desired opportunities and link them with the new improvements?

I've pasted an example of this below (partial code from the xml), where I entered the two new improvement types "IMPROVEMENT_FP_FARM" and "IMPROVEMENT_FP_TRADING_POST"
Spoiler :
Code:
	<Triggers>
		<Row><Type>COMMERCIAL_FARMING</Type>		<ImprovementType>IMPROVEMENT_FARM</ImprovementType>				</Row>
		<Row><Type>FP_COMMERCIAL_FARMING</Type>		<ImprovementType>IMPROVEMENT_FP_FARM</ImprovementType>				</Row>
		<Row><Type>MINE_STRIKE</Type>				<ImprovementType>IMPROVEMENT_MINE</ImprovementType>				</Row>
		<Row><Type>VILLAGE_PROTESTS</Type>			<ImprovementType>IMPROVEMENT_TRADING_POST</ImprovementType>		</Row>
		<Row><Type>FP_VILLAGE_PROTESTS</Type>			<ImprovementType>IMPROVEMENT_FP_TRADING_POST</ImprovementType>		</Row>
...
	</Triggers>
	<Outcomes>
		<Row><Type>COMMERCIAL_FARMING_1</Type>       <Yield>3</Yield><YieldType>YIELD_CULTURE</YieldType>      <GoldCost>150</GoldCost><Order>1</Order><TriggerType>COMMERCIAL_FARMING</TriggerType></Row>
		<Row><Type>COMMERCIAL_FARMING_2</Type>       <Yield>2</Yield><YieldType>YIELD_FOOD</YieldType>         <GoldCost>150</GoldCost><Order>2</Order><TriggerType>COMMERCIAL_FARMING</TriggerType></Row>
		<Row><Type>COMMERCIAL_FARMING_3</Type>       <Yield>1</Yield><YieldType>YIELD_GOLD</YieldType>         <GoldCost>  0</GoldCost><Order>3</Order><TriggerType>COMMERCIAL_FARMING</TriggerType></Row>
		<Row><Type>FP_COMMERCIAL_FARMING_1</Type>       <Yield>3</Yield><YieldType>YIELD_CULTURE</YieldType>      <GoldCost>150</GoldCost><Order>1</Order><TriggerType>FP_COMMERCIAL_FARMING</TriggerType></Row>
		<Row><Type>FP_COMMERCIAL_FARMING_2</Type>       <Yield>2</Yield><YieldType>YIELD_FOOD</YieldType>         <GoldCost>150</GoldCost><Order>2</Order><TriggerType>FP_COMMERCIAL_FARMING</TriggerType></Row>
		<Row><Type>FP_COMMERCIAL_FARMING_3</Type>       <Yield>1</Yield><YieldType>YIELD_GOLD</YieldType>         <GoldCost>  0</GoldCost><Order>3</Order><TriggerType>FP_COMMERCIAL_FARMING</TriggerType></Row>
		<Row><Type>MINE_STRIKE_1</Type>              <Yield>1</Yield><YieldType>YIELD_HAPPINESS</YieldType>    <GoldCost>150</GoldCost><Order>1</Order><TriggerType>MINE_STRIKE</TriggerType></Row>
		<Row><Type>MINE_STRIKE_2</Type>              <Yield>3</Yield><YieldType>YIELD_PRODUCTION</YieldType>   <GoldCost>150</GoldCost><Order>2</Order><TriggerType>MINE_STRIKE</TriggerType></Row>
		<Row><Type>MINE_STRIKE_3</Type>              <Yield>1</Yield><YieldType>YIELD_GOLD</YieldType>         <GoldCost>  0</GoldCost><Order>3</Order><TriggerType>MINE_STRIKE</TriggerType></Row>
		<Row><Type>VILLAGE_PROTESTS_1</Type>         <Yield>3</Yield><YieldType>YIELD_SCIENCE</YieldType>      <GoldCost>150</GoldCost><Order>1</Order><TriggerType>VILLAGE_PROTESTS</TriggerType></Row>
		<Row><Type>VILLAGE_PROTESTS_2</Type>         <Yield>1</Yield><YieldType>YIELD_HAPPINESS</YieldType>    <GoldCost>150</GoldCost><Order>2</Order><TriggerType>VILLAGE_PROTESTS</TriggerType></Row>
		<Row><Type>VILLAGE_PROTESTS_3</Type>         <Yield>1</Yield><YieldType>YIELD_GOLD</YieldType>         <GoldCost>  0</GoldCost><Order>3</Order><TriggerType>VILLAGE_PROTESTS</TriggerType></Row>
		<Row><Type>FP_VILLAGE_PROTESTS_1</Type>         <Yield>3</Yield><YieldType>YIELD_SCIENCE</YieldType>      <GoldCost>150</GoldCost><Order>1</Order><TriggerType>FP_VILLAGE_PROTESTS</TriggerType></Row>
		<Row><Type>FP_VILLAGE_PROTESTS_2</Type>         <Yield>1</Yield><YieldType>YIELD_HAPPINESS</YieldType>    <GoldCost>150</GoldCost><Order>2</Order><TriggerType>FP_VILLAGE_PROTESTS</TriggerType></Row>
		<Row><Type>FP_VILLAGE_PROTESTS_3</Type>         <Yield>1</Yield><YieldType>YIELD_GOLD</YieldType>         <GoldCost>  0</GoldCost><Order>3</Order><TriggerType>FP_VILLAGE_PROTESTS</TriggerType></Row>
...
	</Outcomes>

Thanks in advance

\Skodkim
 
I think you've got it right. You'll also need to add to the Outcome_Flavors table lower in that file (for the AI), and copy the text entries from:

/VEM/Text/en_US/Triggers.xml

Since I suspect your FP farms and villages are basically identical to the normal ones, you can simply copy-paste the normal farm/village text entries and change the "Tag" to match your new opportunities. :goodjob:
 
I would love to see some grittier stuff in opportunities:

Trigger: Defeating a unit (maybe non barbarian only)

Your soldiers have been caught defiling the bodies of enemy soldiers
  • This behavior shall not stand! (+10:c5influence: , unit destroyed)
  • They shall learn to fear us! (+50:c5gold: -20:c5influence: Unit gains +15%:c5strength: when attacking)
  • (Aztec Only) - Another sacrifice for Huitzilopochtli! (-20:c5influence: +150:c5culture:)
 
I would love to see some grittier stuff in opportunities:

Trigger: Defeating a unit (maybe non barbarian only)

Your soldiers have been caught defiling the bodies of enemy soldiers
  • This behavior shall not stand! (+10:c5influence: , unit destroyed)
  • They shall learn to fear us! (+50:c5gold: -20:c5influence: Unit gains +15%:c5strength: when attacking)
  • (Aztec Only) - Another sacrifice for Huitzilopochtli! (-20:c5influence: +150:c5culture:)

I love this aesthetically. From a gameplay perspective, I also really like the clear cost/benefit trade-offs.
 
@Sneaks
If we kill a citystate unit, we're at war, so our influence is fixed at -60. It would work with major civs in theory, but:

Unfortunately I think we have:

Get major civ mood
Set major civ mood
Get minor civ mood
Set minor civ mood

I'll ask in the main modding forum.
The responses confirmed the second one is missing. It could alter our influence with all citystates? Or perhaps just the closest one...

Opportunity costs can't scale with game speed, can they? On marathon, they all seem way too cheap.

Both costs and benefits remain the same, so I think they're still balanced in relation to one another? Each opportunity is proportionately weaker, but more occur per game, so that balances out too.
 
The per turn benefits remain the same but that has a much greater impact at longer game times since instead of having 200 turns to use the benefit you have 400 turns. It means that trading away lump sums for constant improvements is a much better deal on marathon or epic.
 
So, I've been thinking. What kind of Opportunities should we have and I think I've identified the following groups by their "target"/"trigger":

  • Tile Improvements, offering permanently higher yields for a set amount of gold (or culture or science?)
  • City States offering influence for yield (gold, culture, science, food?, unit?, production?). But there need to be a few that are independent from influence so that they can target non-allied states.
  • Empire wide opportunities, triggered by Social Policy Trees, maybe one for the opener, one for the finisher?
  • Single units that can be changed or get a promotion for a yield. (unit types?
  • Buildings, mostly giving one yield or the other for gold?
  • Tiles, offering a "free" improvement or even a ressource (f.e. wheat), or cut down/plant forest, or adding the tile to the empire.
  • Natural Disasters adding primarily flavour and giving a choice or cultural/scientific/commercial Events giving a set amount of a yield (culture, science, gold, food?, production?), Occupied/Puppeted Cities, opportunities for a conquest game?, or Foreign/Barbarian Units, ...

But the effect can get quite repetitive if you get several opportunities of the same type repetitively. If there are more unit-targeted events, this feeling can be eliminated. Best way to counterbalance this is having around the same number of opportunities for each group, I'd say. What are the possible effects?

  • Yield-per turn: on tile improvement, tile, city or building.
  • Net sum of yield: science, culture, gold, influence (production?, food? happines?)
  • New/flipped Unit
  • Promotion on unit
  • special effect? (like +X% production on Specialist/Wonder building, food surplus, etc. ?)

That's not much variety at all, but if one succeeds in having more unit-focuessed ones, that should be a very good start...
 
Opportunities cannot repeat until all eligible ones are exhausted. Think of it like an ipod on shuffle, but each time a song plays, it's removed from the playlist. This greatly reduces the likelihood of getting the same thing twice. It resets when nothing's left so everything can play again. In addition to this, an opportunity cannot repeat with the same target. If a farm gets the Commercial Farm opportunity it will never target that farm again. (It's possible to override this if an opportunity's trigger has the "CanRepeat" flag set.)

These things are in place because I feel it's immersion-breaking when the same thing happens twice in a row. Sometimes it's unavoidable though, particularly in the very early game when few opportunities are available. This is why I've been adding more to the ancient era. :)
 
I wasn't talking about the frequency at all. It's more about making the pool balanced in the variety. ;)

And I guess they do repeat as the count starts anew in every game, right?
 
Does the pool needing to be exhausted count ALL opportunities or just opportunities of a specific class like Plot or Building? I really would dislike not being able to get more building opportunities simply because I have not had an archer stumble in to the correct opportunity situation.
 
I'm not sure how to best explain it, but this is the overall process:

  1. Each turn has a rising chance of an opportunity.
  2. If the chance happens:
    • Get a list of opportunities which can happen this turn and have not run recently.
    • If the list is empty reset all "ran recently" and check again.
    • If the list is still empty, no opportunities are currently possible, so skip this turn.
    • Otherwise run a random opportunity from the list, and flag it as "ran recently."
    • Block future opportunities.
    • Continue incrementing the chance.
  3. When the stored chance reaches 100%:
    • Reset chance to 0%.
    • Unblock opportunities.
 
I just had an in-game aha! moment while dealing with an opportunity that offered +6:c5science: vs +2:c5happy:. This is close to balanced in the early game, but is nowhere near balanced after multiple +% modifiers are in place, especially for :c5science:Science, whose modifiers exceed 100% on a regular basis.

I just grabbed some data from a save state with Gandhi playing a peaceful Cultural game turn 200 (Renaissance) and found the following modifiers (manually calculated by dividing total yield by base yield):


I suspect that, on average, food < gold < production < culture < science in terms of late-game modifiers. I'm not really sure what a good fix/adjustment for this would be though. I guess I was thinking that mid-late game modifiers would be a decent estimate for a good % to adjust these yields by (at least as a first pass), since the +base boost from an early-game Opportunity lasts for the whole game when I grabbed the numbers above.


On a mostly unrelated note, I was thinking that some instant +Great Person points would be a cool thing to get out of an Opportunity. :p
 
Good idea about the Great Person points. It should be easy to do, and much easier to balance than a completely free Great Person. I've written down a note for later.

I agree the value of yields shifts from early to late game. It also depends a lot on terrain: if we have many coastal cities, the value of production is higher than if we're surrounded by hills. I just try and aim for something of a middle ground.
 
Top Bottom