You want to grant the power to player 0 - Here's a nice function:
void WallopArea(float x = 0.0,float z = 0.0, string powername="") {
if (powername=="") {
int i = rmRandInt(1,3); // RANDOM
if (i==1) powername = "Earthquake";
if (i==2) powername = "Meteor";
if (i==3) powername = "Forest Fire";
}
rmAddTriggerEffect("Grant God Power");
rmSetTriggerEffectParamInt("PlayerID",0);
rmSetTriggerEffectParam("PowerName","Vision");
rmSetTriggerEffectParamInt("Count",1);
rmAddTriggerEffect("Invoke God Power");
rmSetTriggerEffectParamInt("PlayerID",0);
rmSetTriggerEffectParam("PowerName","Vision");
rmSetTriggerEffectParam("DstPoint1",x+",0,"+z);
rmAddTriggerEffect("Grant God Power");
rmSetTriggerEffectParamInt("PlayerID",0);
rmSetTriggerEffectParam("PowerName",powername);
rmSetTriggerEffectParamInt("Count",1);
rmAddTriggerEffect("Invoke God Power");
rmSetTriggerEffectParamInt("PlayerID",0);
rmSetTriggerEffectParam("PowerName",powername);
rmSetTriggerEffectParam("DstPoint1",x+",0,"+z);
//rmAddTriggerEffect("Send Chat");
//rmSetTriggerEffectParamInt("PlayerID",0);
//rmSetTriggerEffectParam("Message","Striking At x,z !" + x + " : " + z);
}
Then in your main() routine call it like so:
float jj=.5;
float kk=.5;
rmCreateTrigger("eruptvolcano1");
rmSwitchToTrigger(rmTriggerID("eruptvolcano1"));
WallopArea(jj,kk);
This will strike with a random volcano-type effect at the center of the map.
call it like so to specify the effect:
WallopArea(jj,kk,"earthquake");
To see this in all it's glory look at my RM called EscapeMonkeyIsland - at
EscapeMonkeyIsland.comThis RM has a center volcano (doesn't everyone?) that erupts in 5 seperate cycles randomly striking around the map and on the 5th hitting each players tc directly - at about the 30min mark.
Go luck.