View Full Version : Is it possible "de"-activate the script temporarily?
Atraphoenix
08-16-2009, 23:39
I have prepared some type of hotseat script mainly by modding the present scripts other than EBBS.
as you can estimate when I activated the hotseat script and switched to other faction also after I finished my turn with it when I returned to my first faction my goverment buildings are damaged because I did not exit game and restart.
so to avoid the goverment buildings damage is it possible to de-activate the script temporarily or de-activate then activate again.
In fact, it does not much bother me but I switch the faction I coded before pressing end turn button.
It did not make any difference.
The only solution I could think to stop this is just simple activate the hotseat script swtict factions then save and exit.
Any idea?
I suppose you could have some event counter condition in the indefinite loop that keeps the script alive. Then have for instance the generic script switch the condition criterion, so that you can activate the "end script function" through F1 etc.
Atraphoenix
08-17-2009, 11:10
This is how I converted other scripts into hotseat.
I changed to generic script like this to switch Sauromate
;
; This is a placeholder script. Its purpose is to provide a valid
; but completely safe script to resolve the Script command in
; the Generic_Script_Thread. See EXPORT_DESCR_ADVICE.TXT.
;
script
console_command toggle_perfect_spy
console_command control armenia
end_script
so when I activate the generic script I play as Saro.
after I finish my movements I switch back parthia for example with FD script that I have added this lines:
script
declare_show_me
declare_counter loop
monitor_event AbandonShowMe TrueCondition
suspend_unscripted_advice false
console_command force_diplomacy off
terminate_script
end_monitor
monitor_event ScrollClosed ScrollClosed diplomacy_scroll
ui_flash_stop
suspend_unscripted_advice false
console_command force_diplomacy off
terminate_script
end_monitor
suspend_unscripted_advice true
console_command force_diplomacy accept
console_command control parthia
while I_CompareCounter loop = 0
end_while
suspend_unscripted_advice false
end_script
so I have made a hotseat mode easily but I failed to stop damaging my goverment buildings.
so that most safe way methinks: do not press end turn activate generic script save, quit reload but do not activate until to return first faction played. that is the longest solution I could manage.
I switched more than 4 times between two faction without pressing end turn without any problem. I just want to learn if my goverment building damaged do I have to start the pahlavan reforms from the beginning or if I repair the building can I go on the Pahlava reform process.
Like if I switch saro and my reformed pastoralism damaged when I switched back parthia/Pahlava if I repair it, can I build reformed aristocracy then pahlavan reformed goverment or I have to destroy it then process_cq whole process from the beginning?
I think perhaps the easiest way to avoid damaging the governments is to remove the part of the script that damages the governments.
Atraphoenix
08-17-2009, 16:34
so that's the problem which part :sweatdrop:
That's where the computer's search function is the trick. You know the internal name of the buildings that are damaged. Search it out in EBBS. If you don't know the internal name, look up the internal name from the display name. Honestly, if you're going to mod stuff, you need to know how to find out about these kinds of things yourself.
Atraphoenix
08-17-2009, 17:22
As far as I estimate if I delete ";3: Government Building Management" AI will not build its own government and it stabs the script heavily .... :no:
BTW save, exit, restart, load, switch faction, return to main faction, then activate EBBS and end turn at the moment looks better than deleting 60.000 lines from EBBS... :shame:
I will just try to delete the factions section I want to play both.
bug hunting is like searching a needle in hay....
Thanks for help Bovi.
:inquisitive: I never suggested to delete the whole section. Search for set_building_health*government, and you'll find the statements.
Atraphoenix
08-18-2009, 08:37
:inquisitive: I never suggested to delete the whole section. Search for set_building_health*government, and you'll find the statements.
No you did not, I have just deleted parthia (pahlava) and armenia (saro) parts the second part of 3rd section in EBBS that has set_building_health government
like
if I_SettlementOwner Veldideno = parthia
and I_CompareCounter settlementowner_Veldideno != 16
console_command set_building_health Veldideno government 0
console_command set_building_health Veldideno minimumbuilding 0
console_command create_building Veldideno govnomad
end_if
and
for saro
if I_SettlementOwner Veldideno = armenia
and I_CompareCounter settlementowner_Veldideno != 19
console_command set_building_health Veldideno government 0
console_command set_building_health Veldideno minimumbuilding 0
console_command create_building Veldideno govnomad
end_if
and it worked :yes:
vBulletin® v3.7.1, Copyright ©2000-2025, Jelsoft Enterprises Ltd.