Originally Posted by
Gigantus
That would require a small monitor in the script which fires an event. The event can then be used in the EDB to give an equivalent negative growth bonus for the AI.
Train of thought:
Script
- test for playing level (CampaignDifficulty = very_hard)
- and test for AI player
- fire event
EDB
- negative growth requirement = event_counter [name] 1
Result:
Code:
monitor_event FactionTurnStart not FactionIsLocal
and CampaignDifficulty = very_hard
set_event_counter AI_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and CampaignDifficulty = very_hard
set_event_counter AI_growth 0
end_monitor
Code:
population_growth_bonus bonus -2 requires factions { all, } and event_counter AI_growth 1
Thats not working.... after several tests that i made every time that "faction is local" the counter "AI_growth" resets for the AI too and he gets the bonus...
the only way i found to remove the special bonus for the ai is that
into the campaign_script file,
Code:
;;;;;;;;;;; Growth script ;;;;;;;;;;;;;;;;;
declare_counter AI_growth
declare_counter byzantium_growth
declare_counter egypt_growth
declare_counter france_growth
declare_counter papal_growth
declare_counter sicily_growth
declare_counter turks_growth
declare_counter damascus_growth
declare_counter venice_growth
declare_counter russia_growth
declare_counter moors_growth
declare_counter mongols_growth
declare_counter timurids_growth
declare_counter tuareg_growth
declare_counter azumi_growth
declare_counter cilicia_growth
declare_counter hungary_growth
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled byzantium
set_event_counter byzantium_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled byzantium
set_event_counter byzantium_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled egypt
set_event_counter egypt_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled egypt
set_event_counter egypt_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled france
set_event_counter france_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled france
set_event_counter france_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled papal_states
set_event_counter papal_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled papal_states
set_event_counter papal_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled sicily
set_event_counter sicily_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled sicily
set_event_counter sicily_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled turks
set_event_counter turks_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled turks
set_event_counter turks_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled damascus
set_event_counter damascus_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled damascus
set_event_counter damascus_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled venice
set_event_counter venice_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled venice
set_event_counter venice_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled russia
set_event_counter russia_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled russia
set_event_counter russia_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled venice
set_event_counter moors_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled moors
set_event_counter moors_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled moors
set_event_counter moors_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled mongols
set_event_counter mongols_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled mongols
set_event_counter mongols_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled mongols
set_event_counter mongols_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled timurids
set_event_counter timurids_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled timurids
set_event_counter timurids_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled tuareg
set_event_counter tuareg_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled tuareg
set_event_counter tuareg_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled azumi
set_event_counter azumi_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled azumi
set_event_counter azumi_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled cilicia
set_event_counter cilicia_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled cilicia
set_event_counter cilicia_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
and I_IsFactionAIControlled hungary
set_event_counter hungary_growth 1
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
and I_IsFactionAIControlled hungary
set_event_counter hungary_growth 1
end_monitor
monitor_event FactionTurnStart FactionIsLocal
set_event_counter AI_growth 2
end_monitor
monitor_event FactionTurnStart not FactionIsLocal
set_event_counter AI_growth 2
end_monitor
into the export_descr_buildings for every capability sections of the core_building levels
Code:
castle castle requires factions { northern_european, middle_eastern, eastern_european, greek, southern_european, }
{
convert_to 1
capability
{
wall_level 2
tower_level 1
gate_strength 1
gate_defences 2
law_bonus bonus 3
recruitment_slots 3 requires factions { northern_european, aztecs, middle_eastern, eastern_european, greek, southern_european, }
free_upkeep bonus 4
population_growth_bonus bonus -4 requires factions { byzantium, } and event_counter byzantium_growth 1
population_growth_bonus bonus -4 requires factions { egypt, } and event_counter egypt_growth 1
population_growth_bonus bonus -4 requires factions { france, } and event_counter france_growth 1
population_growth_bonus bonus -4 requires factions { papal_states, } and event_counter papal_growth 1
population_growth_bonus bonus -4 requires factions { sicily, } and event_counter sicily_growth 1
population_growth_bonus bonus -4 requires factions { turks, } and event_counter turks_growth 1
population_growth_bonus bonus -4 requires factions { damascus, } and event_counter damascus_growth 1
population_growth_bonus bonus -4 requires factions { venice, } and event_counter venice_growth 1
population_growth_bonus bonus -4 requires factions { russia, } and event_counter russia_growth 1
population_growth_bonus bonus -4 requires factions { moors, } and event_counter moors_growth 1
population_growth_bonus bonus -4 requires factions { mongols, } and event_counter mongols_growth 1
population_growth_bonus bonus -4 requires factions { timurids, } and event_counter timurids_growth 1
population_growth_bonus bonus -4 requires factions { tuareg, } and event_counter tuareg_growth 1
population_growth_bonus bonus -4 requires factions { azumi, } and event_counter azumi_growth 1
population_growth_bonus bonus -4 requires factions { cilicia, } and event_counter cilicia_growth 1
population_growth_bonus bonus -4 requires factions { hungary, } and event_counter hungary_growth 1
population_growth_bonus bonus -4 requires factions { all, } and event_counter AI_growth 2