My plan was to to fire an informative message once a particular faction (f_hayasdan, player controlled)spiesdouble clicks on a slave settlement (sett_112). Because attention spans aren't what they used to be I intended to fire the message twice and then terminate the monitor.
The first obstacle was that the SettlementSelected event only works for player settlements. Bit of a bummer but then I remembered that spying on a settlement opens the info panel, so I gave it a twirl with SettlementPanelOpen. Worked really well - the first time only. Simply refuses to fire a second time, I suspect it has to do with the historic event message immediately replacing the open settlement panel.
Underneath the script that theoretically should fire every time the panel is opened:
This would be the absolute minimum for testing with vanilla (double click settlement to open panel) using england:Code:monitor_event SettlementPanelOpen SettlementName sett_112 and I_SettlementOwner sett_112 = slave and not I_IsFactionAIControlled f_hayasdan historic_event HE_SETT_112_SELECTED factions ( f_hayasdan, ) end_monitor
The weird thing is, that the message fires again when you use the selection arrows (next\previous settlement) to navigate through the panels when the settlement is owned by the player (obviously not available when owned by AI) but not when using a double click.Code:monitor_event SettlementPanelOpen SettlementName London ; player owned historic_event first_windmill end_monitor monitor_event SettlementPanelOpen SettlementName York ; slave owned historic_event first_windmill end_monitor







































Reply With Quote





