//SLO file for Pre-damaging objects on map //also gives player starting tech //VTOLs handled in separate script //cam2AX.SLO /* ******************** */ /* Declared Variables */ /* ******************** */ //starting power for this campaign public int startPow, player; //Predamage structures public int numStructs, numDroids; public STRUCTURE structs[10]; public DROID droids[2]; private int count, temp; public SOUND incomingSnd; //briefing when landed public INTMESSAGE brief; trigger vidTrig(CALL_VIDEO_QUIT); event start(CALL_GAMEINIT) { //set starting power setPowerLevel(startPow, player); //set rubble under buildings - tile 67 setRubbleTile(67); //pre damage structures count = 0; while (count < numStructs) { //forceDamageObject(structs[count], damStructs[count]); forceDamageObject(structs[count], random(20) + 40); //anywhere from 40% to 60% health count = count + 1; } //pre damage droids count = 0; while (count < numDroids) { //forceDamageObject(structs[count], damStructs[count]); forceDamageObject(droids[count], random(20) + 40); //anywhere from 45% to 60% health count = count + 1; } //take over the selectedPlayer's units to avoid id number clashes on later levels //this needs to be done AFTER the units have been damaged. The coords were taken from //the world editor takeOverDroidsInArea(0,0, 10900, 11800, 12900, 13650); } event removeBrief(inactive) { removeMessage(brief, MISS_MSG, 0); setEventTrigger(removeBrief, inactive); } event giveBrief(wait, 100) { //need Warning message here!!!! playSound(incomingSnd, player); pause(20); setEventTrigger(removeBrief, vidTrig); addMessage(brief, MISS_MSG, 0, true); setEventTrigger(giveBrief, inactive); }