In kingdoms crusade there were some units that were "unique" meaning that one can only have one of them at a time.
Is there any way to put this into the export_descr_unit file?
In kingdoms crusade there were some units that were "unique" meaning that one can only have one of them at a time.
Is there any way to put this into the export_descr_unit file?
I think you might have to script some stuff in campaign_script, or descr_strat, and you might want to do something in EDB. So no, it can't be done via EDU.
Give a better description of what you want exactly and I or someone else will explain how to get it.
Last edited by Taiji; February 22, 2012 at 02:16 AM.
You can do this with any unit with some simple scripting...You can use this a guidline script for each unit you want to be unique...Here's an example of the script to write in campaign_script file...Obviously you can change or add more unit's if desired....
And this is an example of what your entries in the EDB should look like;Code:;------------------- RECRUITMENT - UNIQUE UNITS -------------------; ;Only one unique unit can exist at a time ;Jerusalem ;Marshall of the Templars ;Constable of Jerusalem ;Antioch ;Marshall of the Hospitallers ;Canons of the Holy Sepulcher ;Test if the unit doesn't exist at start of turn ;Increment event counter - allows recruitment set_event_counter no_templar_marshall 0 set_event_counter no_jerusalem_constable 0 set_event_counter no_hospitaller_marshall 0 set_event_counter no_canon_sepluchre 0 monitor_event FactionTurnStart FactionType jerusalem and I_EventCounter no_templar_marshall == 0 and not I_UnitExists jerusalem Marshall of the Templars add_events event counter no_templar_marshall date 0 end_add_events end_monitor monitor_event FactionTurnStart FactionType jerusalem and I_EventCounter no_jerusalem_constable == 0 and not I_UnitExists jerusalem Constable of Jerusalem add_events event counter no_jerusalem_constable date 0 end_add_events end_monitor monitor_event FactionTurnStart FactionType antioch and I_EventCounter no_hospitaller_marshall == 0 and not I_UnitExists antioch Marshall of the Hospitallers add_events event counter no_hospitaller_marshall date 0 end_add_events end_monitor monitor_event FactionTurnStart FactionType antioch and I_EventCounter no_canon_sepluchre == 0 and not I_UnitExists antioch Canons of the Holy Sepulcher add_events event counter no_canon_sepluchre date 0 end_add_events end_monitor ;Test if the unit exists at start of turn ;Decrement event counter - stops recruitment monitor_event AddedToTrainingQueue UnitType Marshall of the Templars and I_EventCounter no_templar_marshall == 1 set_event_counter no_templar_marshall 0 end_monitor monitor_event AddedToTrainingQueue UnitType Constable of Jerusalem and I_EventCounter no_jerusalem_constable == 1 set_event_counter no_jerusalem_constable 0 end_monitor monitor_event AddedToTrainingQueue UnitType Marshall of the Hospitallers and I_EventCounter no_hospitaller_marshall == 1 set_event_counter no_hospitaller_marshall 0 end_monitor monitor_event AddedToTrainingQueue UnitType Canons of the Holy Sepulcher and I_EventCounter no_canon_sepluchre == 1 set_event_counter no_canon_sepluchre 0 end_monitor
Code:recruit_pool "Constable of Jerusalem" 0 0.1 0.999 0 requires factions { jerusalem, } and event_counter no_jerusalem_constable 1 recruit_pool "Marshall of the Hospitallers" 0 0.1 0.999 0 requires factions { antioch, } and event_counter no_hospitaller_marshall 1 recruit_pool "Marshall of the Templars" 0 0.1 0.999 0 requires factions { jerusalem, } and event_counter no_templar_marshall 1 recruit_pool "Canons of the Holy Sepulcher" 0 0.1 0.999 0 requires factions { antioch, } and event_counter no_canon_sepluchre 1