patpatpowercat -> Trigger on Hostilities Commence (12/6/2019 10:46:57 PM)
|
I am trying to figure out how to activate a list of missions once two sides commence hostilities. I understand how to activate the missions using lua ScenEdit_SetMission {isactive=true}, but I am trying to figure how to best trigger this action. Originally I was going to do it with a unit destroyed, but I don't want a 3rd side to commence hostilities between the two sides prematurely. So I was looking into firing a once a second trigger and using ScenEdit_GetSidePosture, have if it returns hostile than activate the missions. However, my lua knowledge isn't that great and I'm not sure how to take the return of the GetSidePosture and turn it into a variable for us in an if/then argument, or if this would be the optimal way of doing so. Any suggestions?
|
|
|
|