Brought up to date with the newest T2BoL I've located

This commit is contained in:
Robert MacGregor 2015-08-30 02:30:29 -04:00
parent 8c96cba3e1
commit accd31895e
287 changed files with 108557 additions and 107608 deletions

View file

@ -1,37 +1,37 @@
//Alpha Sector (broke) script
package AlphaSector //Package is our mission Name
{
function defineGeneralAI()
{
//These arrays are for general bots
$Bot[0,"Name"] = "Jeff Harding"; //ftl, Jeff.
$Bot[0,"Race"] = "Human";
//Very important or the console will get spammed.
//Bioderms and Criollos MUST be Male.
//Draakans can be types A, B, or C.
$Bot[0,"Sex"] = "Male";
$Bot[0,"Skin"] = "Beagle"; //Skin. Don't use the actual team name. (Blood Eagle for example)
$Bot[0,"Voice"] = "Male1"; //Voice. Don't use the fancy name (Psycho for example).
$Bot[0,"VoicePitch"] = 1;
$Bot[0,"Team"] = 1; //Human
$Bot[0,"Weapons"] = "Blaster"; //List the weapons with spaces. The first weapon listed will be the one he has out on spawn.
$Bot[0,"Pack"] = "MiningTool";
$Bot[0,"Armor"] = "Light";
$Bot[0,"Objectives"] = false; //The bot goes NOWHERE!
//The ammo for each weapon in "Weapons", make sure it's in the same spot in the string as the weapon.
//If the weapon doesn't use ammo, just place a zero.
$Bot[0,"Ammo"] = "0";
$Bot[0,"RepairKits"] = 1; //Yea.. rep kits
$Bot[0,"Mines"] = 0; //Mines!!
$Bot[0,"Grenades"] = 0; //Grenades. I'll make it so you can tell which kind of nades.
$Bot[0,"Transform"] = "-159.193 -131.751 277.517 0 0 -1 1.1602"; //First 3 numbers are the position. The rest is the rotation.
//These are for detailing on the bots.. shouldn't really be used unless you got a good reason to.
$Bot[0,"Health"] = 1; //I'm pretty sure 1 is the max for all armors.
$BotCount = 1; //Tell the game how many general AI's there are.
}
};
//Alpha Sector (broke) script
package AlphaSector //Package is our mission Name
{
function defineGeneralAI()
{
//These arrays are for general bots
$Bot[0,"Name"] = "Jeff Harding"; //ftl, Jeff.
$Bot[0,"Race"] = "Human";
//Very important or the console will get spammed.
//Bioderms and Criollos MUST be Male.
//Draakans can be types A, B, or C.
$Bot[0,"Sex"] = "Male";
$Bot[0,"Skin"] = "Beagle"; //Skin. Don't use the actual team name. (Blood Eagle for example)
$Bot[0,"Voice"] = "Male1"; //Voice. Don't use the fancy name (Psycho for example).
$Bot[0,"VoicePitch"] = 1;
$Bot[0,"Team"] = 1; //Human
$Bot[0,"Weapons"] = "Blaster"; //List the weapons with spaces. The first weapon listed will be the one he has out on spawn.
$Bot[0,"Pack"] = "MiningTool";
$Bot[0,"Armor"] = "Light";
$Bot[0,"Objectives"] = false; //The bot goes NOWHERE!
//The ammo for each weapon in "Weapons", make sure it's in the same spot in the string as the weapon.
//If the weapon doesn't use ammo, just place a zero.
$Bot[0,"Ammo"] = "0";
$Bot[0,"RepairKits"] = 1; //Yea.. rep kits
$Bot[0,"Mines"] = 0; //Mines!!
$Bot[0,"Grenades"] = 0; //Grenades. I'll make it so you can tell which kind of nades.
$Bot[0,"Transform"] = "-159.193 -131.751 277.517 0 0 -1 1.1602"; //First 3 numbers are the position. The rest is the rotation.
//These are for detailing on the bots.. shouldn't really be used unless you got a good reason to.
$Bot[0,"Health"] = 1; //I'm pretty sure 1 is the max for all armors.
$BotCount = 1; //Tell the game how many general AI's there are.
}
};

File diff suppressed because it is too large Load diff

View file

@ -1,415 +1,415 @@
// don't want this executing when building graphs
if($OFFLINE_NAV_BUILD)
return;
// Script for Training
//===================================================================================
//error("Training 1 script");
//Note: Quite messy right now.. I'll organize when it's done
//Not sure why this mission causes lots of console spam..
// variables
$numberOfEnemies[1] = 6;
$numberOfEnemies[2] = 6;
$numberOfEnemies[3] = 6;
$numberOfTeammates = 1;
$missionBotSkill[1] = 0.2;
$missionBotSkill[2] = 0.4;
$missionBotSkill[3] = 0.7;
// package and callbacks
package Beginning {
//BEGIN BEGINNING PACKAGE =======================================================================
function SinglePlayerGame::initGameVars(%game)
{
echo("initializing beginning (TDS mission 1) game vars");
Game.captorName = "Alchaldes"; //Main dude speaking
Game.controllerName = "Hammurabi"; //Guy at control panel
Game.guardOneName = "Romulus";
Game.guardTwoName = "Hercules";
}
function PlayGui::onWake(%this)
{
parent::onWake(%this);
//error("Waking training play gui");
// okay we know the victim...erm...player is looking
// and we hope they have a body so lets do this
if(!game.playedIntro) {
game.PlayGuiAwake = true;
beginBeginning();
}
}
function getTeammateGlobals()
{
$TeammateWarnom0 = "Gila";
$teammateSkill0 = 0.5;
$teammateVoice0 = Derm3;
$teammateEquipment0 = 0;
$teammateGender0 = B;
}
function MP3Audio::play(%this)
{
//too bad...no mp3 in training
}
function toggleCommanderMap(%val)
{
// No command Circuit fer' you!
}
function toggleTaskListDlg( %val )
{
// Tasks? What tasks? Get the ef out of there when given the chance!
}
function toggleInventoryHud( %val )
{
// Not even a message
}
function toggleNetDisplayHud( %val )
{
// Hello, McFly? This is training! There's no net in training!
}
function voiceCapture( %val )
{
// Uh, who do you think you are talking to?
}
function giveall()
{
error("When the going gets tough...wussies like you start cheating!");
messageClient($player, 0, "Cheating eh? What\'s next? Camping?");
}
// get the ball rolling
//------------------------------------------------------------------------------
function startCurrentMission()
{
playGui.add(outerChatHud);
//fade up from black
ServerConnection.setBlackOut(true, 0);
new actionMap(ModifiedMap);
modifiedMap.bind(mouse0, "xaxis", yaw);
modifiedMap.bind(mouse0, "yaxis", pitch);
}
function singlePlayerDead()
{
missionFailed($player.miscMsg[TDSGenericLoss]);
AIMissionEnd();
$objectiveQ[$enemyTeam].clear();
}
function beginBeginning()
{
if(game.playedIntro)
return;
$Beginning = ServerConnection.schedule(3000, setBlackOut, false, 4000);
$player.player.setTransform(DP.getTransform());
$enemy0.stepMove(AlchaldesVisit.getPosition());
yaw(1);
return;
game.playedIntro = true;
lockArmorHack(true); //Don't let our playah move
//Now set up the victim
turnPlayerToPosition($enemy0.player.getPosition());
$player.player.schedule(3000,"setInvincibleMode",$InvincibleTime,0.02);
schedule(3200,0,"hideHudHACK",false);
pitch(40);
if(!$firstperson)//Make sure we're in first person every time
toggleFirstPerson($player);
//Although both can't jet.. apparently b0ts need them to get around (even jumping down from stuff)
$player.player.setRechargeRate(0);
$player.player.setEnergyLevel(0);
$teammate0.player.setTransform(Warnom0.getTransform());
//Alchaldes (leader of Criollos)
$enemy0.aimAt($player.player.getPosition());
$enemy0.player.clearInventory();
$enemy0.player.setInventory("EnergyPack",1); //Has a med condition; needs energy pack at all times
setName($enemy0,Game.CaptorName);
setSkin($enemy0,"HALO_SKIN");
//Hammurabi (Cloning -- lead researcher)
$enemy1.aimAt($player.player.getPosition());
$enemy1.player.clearInventory();
$enemy1.player.setInventory("EnergyPack",1);
setName($enemy1,Game.ControllerName);
setVoice($enemy1,"Derm3");
setSkin($enemy1,"HALO_SKIN");
//Guard 1 (Looking at Dolosus)
$enemy2.aimAt($player.player.getPosition());
setName($enemy2,Game.GuardOneName);
setVoice($enemy2,"Derm3");
setSkin($enemy2,"HALO_SKIN");
//Guard 2 (Looking at Gila)
$enemy3.aimAt($teammate0.player.getPosition());
setName($enemy3,Game.GuardTwoName);
setVoice($enemy3,"Derm3");
setSkin($enemy3,"HALO_SKIN");
doText(TDS_M101);
doText(TDS_M102,3000);
doText(TDS_M103,3100);
doText(TDS_M104,3200);
doText(TDS_M105,3300);
doText(TDS_M106,3400);
doText(TDS_M107,3500);
doText(TDS_M108,3600);
doText(TDS_M109,3700);
doText(TDS_M101b,3800);
doText(TDS_M102b,3900);
doText(TDS_M103b,4000);
doText(TDS_M104b,4100);
doText(TDS_M105b,4200);
doText(TDS_M106b,4300);
doText(TDS_M107b,4400);
doText(TDS_M108b,4500);
doText(TDS_M109b,4600);
doText(TDS_M101c,4700);
doText(TDS_M102c,4800);
doText(TDS_M103c,4900);
doText(TDS_M104c,5000);
doText(TDS_M105c,5100);
doText(TDS_M106c,5200);
doText(TDS_M107c,5300);
}
function giveEscortTask(%bot, %target)
{
%newObjective = new AIObjective(AIOEscortPlayer)
{
dataBlock = "AIObjectiveMarker";
weightLevel1 = 10000;
description = "Escort Player";
targetClientId = %target;
offense = true;
};
//echo(%newObjective);
MissionCleanup.add(%newObjective);
$ObjectiveQ[$playerTeam].add(%newObjective);
%bot.stepEscort(%target);
%bot.escort = %newObjective;
}
function detonateAll()
{
ResearchTurret.applyDamage(400);
SecondaryResearch.applyDamage(400);
MainResearch.applyDamage(400);
Turret1.applyDamage(400);
Turret2.applyDamage(400);
Turret3.applyDamage(400);
BaseSensor.applyDamage(400);
BaseGen2.applyDamage(400);
DefenceGen.applyDamage(400);
ReactorGen2.applyDamage(400);
ReactorGen1.applyDamage(0.5);
InventoryStation1.applyDamage(400);
InventoryStation2.applyDamage(400);
InventoryStation3.applyDamage(400);
InventoryStation5.applyDamage(400);
messageAll('msgAll',"\c4Intercom: Main reactor absorbed most of the energy; high damage has been done to the whole network!");
schedule(1500,0,"messageAll",'msgAll',"\c4Gila: Good! Sounds like any defences they have is down.");
//Alright, give the guards and other b0ts the objectives
$enemy2.addTask(AIEngageTask);
$enemy3.addTask(AIEngageTask);
$enemy4.addTask(AIEngageTask);
$enemy5.addTask(AIEngageTask);
}
function storyMoveToHammurabi()
{
$enemy0.stepMove(AlchaldesWorried.getPosition());
$enemy0.schedule(2000,"aimAt",$enemy1.player.getPosition());
$enemy2.aimAt($enemy0.player.getPosition());
$enemy3.aimAt($enemy0.player.getPosition());
}
function storyMoveToGila()
{
$enemy0.stepMove(AlchaldesObserve.getPosition());
$enemy1.stepMove(HammurabiObserve.getPosition());
$enemy0.schedule(2000,"aimAt",$teammate0.player.getPosition());
$enemy1.schedule(2000,"aimAt",$teammate0.player.getPosition());
}
function storyMoveToDolosus()
{
$enemy0.stepMove(enemy0.getPosition());
$enemy1.stepMove(enemy1.getPosition());
$enemy0.schedule(2000,"aimAt",$player.player.getPosition());
$enemy1.schedule(2000,"aimAt",$player.player.getPosition());
}
function hideHudHACK(%bool)
{
objectiveHud.setVisible(%bool);
hudClusterBack.setVisible(%bool);
inventoryHud.setVisible(%bool);
backPackFrame.setVisible(%bool);
weaponsHud.setVisible(%bool);
clockHUD.setVisible(%bool);
retCenterHUD.setVisible(%bool);
}
//------------------------------------------------------------------------------
function SinglePlayerGame::equip(%game, %player)
{
//ya start with nothing...NOTHING!
%player.clearInventory();
for(%i =0; %i<$InventoryHudCount; %i++)
%player.client.setInventoryHudItem($InventoryHudData[%i, itemDataName], 0, 1);
%player.client.clearBackpackIcon();
%set = %player.client.equipment;
if (%player.client.race $= "Draakan")
{
%player.setInventory(Flamer,1);
%player.use(Flamer);
}
else
{
%player.setInventory("Chaingun",1,true);
%player.setInventory("ChaingunAmmo",999,true);
%player.setInventory("Disc",1,true);
%player.setInventory("DiscAmmo",999,true);
%player.setInventory("Shocklance",1,true);
%player.setInventory("AmmoPack",1,true);
%player.use("Chaingun");
}
}
function spawnSinglePlayer()
{
resetWildCat();
parent::spawnSinglePlayer();
}
function turnPlayerToPosition(%pos)
{
%vec = VectorSub($player.player.position, %pos);
%angle = mATan( getWord(%vec, 0), getWord(%vec, 1) );
%angle = %angle + 3.141529;
%newTransform = $player.player.position SPC "0 0 1" SPC %angle;
$player.player.setTransform(%newTransform);
}
function singlePlayerGame::onAIRespawn(%game, %client)
{
// DONT add the default tasks
//error("default tasks not added");
}
function singlePlayerGame::playerSpawned(%game, %player)
{
parent::playerSpawned(%game, %player);
}
function singlePlayerGame::gameOver(%game)
{
//enable the voice chat menu again...
if (isObject(training1BlockMap))
{
training1BlockMap.pop();
training1BlockMap.delete();
}
if(HelpTextGui.isVisible())
helpTextGui.setVisible(false);
//Make sure our hidden HUD elements are visible again
hideHudHACK(true);
//Make sure our sounds stopped playing
doSpecialEffect(5);
//re-enable the use of the settings button...
SinglePlayerEscSettingsBtn.setActive(1);
Parent::gameOver();
}
function trainingPreloads() //Load any skins..
{
navGraph.preload("skins/Gecko.lbioderm", true);
navGraph.preload("skins/Gecko.mbioderm", true);
navGraph.preload("skins/Gecko.hbioderm", true);
navGraph.preload("skins/base.lbioderm", true);
navGraph.preload("skins/HALO_Skin.lbioderm", true);
navGraph.preload("skins/HALO_Skin.mbioderm", true);
navGraph.preload("skins/HALO_Skin.hbioderm", true);
navGraph.preload("skins/sensor_pulse_large", true);
navGraph.preload("skins/base.hmale", false);
navGraph.preload("skins/beagle.hmale", false);
navGraph.preload("skins/base.mmale", false);
navGraph.preload("skins/beagle.mmale", false);
navGraph.preload("skins/base.lmale", false);
navGraph.preload("skins/swolf.mmale", false);
navGraph.preload("skins/beagle.lmale", false);
}
function SinglePlayerGame::missionLoadDone(%game)
{
Parent::missionLoadDone(%game);
trainingPreloads();
}
function serverCmdBuildClientTask(%client, %task, %team)
{
// player shouldnt be able to use the voice commands to do anything
}
function cancel(%sched)
{
parent::Cancel(%sched);
return true;
}
function lockArmorHack(%val)
{
if (%val)
{
movemap.pop();
modifiedmap.push();
}
else
{
movemap.push();
modifiedmap.pop();
}
//$player.player.setMoveState(true);
//$player.player.schedule(1000,"setMoveState", false);
}
function SinglePlayerGame::enterMissionArea(%game, %player){}
function SinglePlayerGame::leaveMissionArea(%game, %player)
{
schedule(1000,0,"missionComplete", $player.miscMsg[TDSBeginningWin] );
moveMap.schedule(1000, "pop");
}
};
activatePackage(Beginning);
// don't want this executing when building graphs
if($OFFLINE_NAV_BUILD)
return;
// Script for Training
//===================================================================================
//error("Training 1 script");
//Note: Quite messy right now.. I'll organize when it's done
//Not sure why this mission causes lots of console spam..
// variables
$numberOfEnemies[1] = 6;
$numberOfEnemies[2] = 6;
$numberOfEnemies[3] = 6;
$numberOfTeammates = 1;
$missionBotSkill[1] = 0.2;
$missionBotSkill[2] = 0.4;
$missionBotSkill[3] = 0.7;
// package and callbacks
package Beginning {
//BEGIN BEGINNING PACKAGE =======================================================================
function SinglePlayerGame::initGameVars(%game)
{
echo("initializing beginning (TDS mission 1) game vars");
Game.captorName = "Alchaldes"; //Main dude speaking
Game.controllerName = "Hammurabi"; //Guy at control panel
Game.guardOneName = "Romulus";
Game.guardTwoName = "Hercules";
}
function PlayGui::onWake(%this)
{
parent::onWake(%this);
//error("Waking training play gui");
// okay we know the victim...erm...player is looking
// and we hope they have a body so lets do this
if(!game.playedIntro) {
game.PlayGuiAwake = true;
beginBeginning();
}
}
function getTeammateGlobals()
{
$TeammateWarnom0 = "Gila";
$teammateSkill0 = 0.5;
$teammateVoice0 = Derm3;
$teammateEquipment0 = 0;
$teammateGender0 = B;
}
function MP3Audio::play(%this)
{
//too bad...no mp3 in training
}
function toggleCommanderMap(%val)
{
// No command Circuit fer' you!
}
function toggleTaskListDlg( %val )
{
// Tasks? What tasks? Get the ef out of there when given the chance!
}
function toggleInventoryHud( %val )
{
// Not even a message
}
function toggleNetDisplayHud( %val )
{
// Hello, McFly? This is training! There's no net in training!
}
function voiceCapture( %val )
{
// Uh, who do you think you are talking to?
}
function giveall()
{
error("When the going gets tough...wussies like you start cheating!");
messageClient($player, 0, "Cheating eh? What\'s next? Camping?");
}
// get the ball rolling
//------------------------------------------------------------------------------
function startCurrentMission()
{
playGui.add(outerChatHud);
//fade up from black
ServerConnection.setBlackOut(true, 0);
new actionMap(ModifiedMap);
modifiedMap.bind(mouse0, "xaxis", yaw);
modifiedMap.bind(mouse0, "yaxis", pitch);
}
function singlePlayerDead()
{
missionFailed($player.miscMsg[TDSGenericLoss]);
AIMissionEnd();
$objectiveQ[$enemyTeam].clear();
}
function beginBeginning()
{
if(game.playedIntro)
return;
$Beginning = ServerConnection.schedule(3000, setBlackOut, false, 4000);
$player.player.setTransform(DP.getTransform());
$enemy0.stepMove(AlchaldesVisit.getPosition());
yaw(1);
return;
game.playedIntro = true;
lockArmorHack(true); //Don't let our playah move
//Now set up the victim
turnPlayerToPosition($enemy0.player.getPosition());
$player.player.schedule(3000,"setInvincibleMode",$InvincibleTime,0.02);
schedule(3200,0,"hideHudHACK",false);
pitch(40);
if(!$firstperson)//Make sure we're in first person every time
toggleFirstPerson($player);
//Although both can't jet.. apparently b0ts need them to get around (even jumping down from stuff)
$player.player.setRechargeRate(0);
$player.player.setEnergyLevel(0);
$teammate0.player.setTransform(Warnom0.getTransform());
//Alchaldes (leader of Criollos)
$enemy0.aimAt($player.player.getPosition());
$enemy0.player.clearInventory();
$enemy0.player.setInventory("EnergyPack",1); //Has a med condition; needs energy pack at all times
setName($enemy0,Game.CaptorName);
setSkin($enemy0,"HALO_SKIN");
//Hammurabi (Cloning -- lead researcher)
$enemy1.aimAt($player.player.getPosition());
$enemy1.player.clearInventory();
$enemy1.player.setInventory("EnergyPack",1);
setName($enemy1,Game.ControllerName);
setVoice($enemy1,"Derm3");
setSkin($enemy1,"HALO_SKIN");
//Guard 1 (Looking at Dolosus)
$enemy2.aimAt($player.player.getPosition());
setName($enemy2,Game.GuardOneName);
setVoice($enemy2,"Derm3");
setSkin($enemy2,"HALO_SKIN");
//Guard 2 (Looking at Gila)
$enemy3.aimAt($teammate0.player.getPosition());
setName($enemy3,Game.GuardTwoName);
setVoice($enemy3,"Derm3");
setSkin($enemy3,"HALO_SKIN");
doText(TDS_M101);
doText(TDS_M102,3000);
doText(TDS_M103,3100);
doText(TDS_M104,3200);
doText(TDS_M105,3300);
doText(TDS_M106,3400);
doText(TDS_M107,3500);
doText(TDS_M108,3600);
doText(TDS_M109,3700);
doText(TDS_M101b,3800);
doText(TDS_M102b,3900);
doText(TDS_M103b,4000);
doText(TDS_M104b,4100);
doText(TDS_M105b,4200);
doText(TDS_M106b,4300);
doText(TDS_M107b,4400);
doText(TDS_M108b,4500);
doText(TDS_M109b,4600);
doText(TDS_M101c,4700);
doText(TDS_M102c,4800);
doText(TDS_M103c,4900);
doText(TDS_M104c,5000);
doText(TDS_M105c,5100);
doText(TDS_M106c,5200);
doText(TDS_M107c,5300);
}
function giveEscortTask(%bot, %target)
{
%newObjective = new AIObjective(AIOEscortPlayer)
{
dataBlock = "AIObjectiveMarker";
weightLevel1 = 10000;
description = "Escort Player";
targetClientId = %target;
offense = true;
};
//echo(%newObjective);
MissionCleanup.add(%newObjective);
$ObjectiveQ[$playerTeam].add(%newObjective);
%bot.stepEscort(%target);
%bot.escort = %newObjective;
}
function detonateAll()
{
ResearchTurret.applyDamage(400);
SecondaryResearch.applyDamage(400);
MainResearch.applyDamage(400);
Turret1.applyDamage(400);
Turret2.applyDamage(400);
Turret3.applyDamage(400);
BaseSensor.applyDamage(400);
BaseGen2.applyDamage(400);
DefenceGen.applyDamage(400);
ReactorGen2.applyDamage(400);
ReactorGen1.applyDamage(0.5);
InventoryStation1.applyDamage(400);
InventoryStation2.applyDamage(400);
InventoryStation3.applyDamage(400);
InventoryStation5.applyDamage(400);
messageAll('msgAll',"\c4Intercom: Main reactor absorbed most of the energy; high damage has been done to the whole network!");
schedule(1500,0,"messageAll",'msgAll',"\c4Gila: Good! Sounds like any defences they have is down.");
//Alright, give the guards and other b0ts the objectives
$enemy2.addTask(AIEngageTask);
$enemy3.addTask(AIEngageTask);
$enemy4.addTask(AIEngageTask);
$enemy5.addTask(AIEngageTask);
}
function storyMoveToHammurabi()
{
$enemy0.stepMove(AlchaldesWorried.getPosition());
$enemy0.schedule(2000,"aimAt",$enemy1.player.getPosition());
$enemy2.aimAt($enemy0.player.getPosition());
$enemy3.aimAt($enemy0.player.getPosition());
}
function storyMoveToGila()
{
$enemy0.stepMove(AlchaldesObserve.getPosition());
$enemy1.stepMove(HammurabiObserve.getPosition());
$enemy0.schedule(2000,"aimAt",$teammate0.player.getPosition());
$enemy1.schedule(2000,"aimAt",$teammate0.player.getPosition());
}
function storyMoveToDolosus()
{
$enemy0.stepMove(enemy0.getPosition());
$enemy1.stepMove(enemy1.getPosition());
$enemy0.schedule(2000,"aimAt",$player.player.getPosition());
$enemy1.schedule(2000,"aimAt",$player.player.getPosition());
}
function hideHudHACK(%bool)
{
objectiveHud.setVisible(%bool);
hudClusterBack.setVisible(%bool);
inventoryHud.setVisible(%bool);
backPackFrame.setVisible(%bool);
weaponsHud.setVisible(%bool);
clockHUD.setVisible(%bool);
retCenterHUD.setVisible(%bool);
}
//------------------------------------------------------------------------------
function SinglePlayerGame::equip(%game, %player)
{
//ya start with nothing...NOTHING!
%player.clearInventory();
for(%i =0; %i<$InventoryHudCount; %i++)
%player.client.setInventoryHudItem($InventoryHudData[%i, itemDataName], 0, 1);
%player.client.clearBackpackIcon();
%set = %player.client.equipment;
if (%player.client.race $= "Draakan")
{
%player.setInventory(Flamer,1);
%player.use(Flamer);
}
else
{
%player.setInventory("Chaingun",1,true);
%player.setInventory("ChaingunAmmo",999,true);
%player.setInventory("Disc",1,true);
%player.setInventory("DiscAmmo",999,true);
%player.setInventory("Shocklance",1,true);
%player.setInventory("AmmoPack",1,true);
%player.use("Chaingun");
}
}
function spawnSinglePlayer()
{
resetWildCat();
parent::spawnSinglePlayer();
}
function turnPlayerToPosition(%pos)
{
%vec = VectorSub($player.player.position, %pos);
%angle = mATan( getWord(%vec, 0), getWord(%vec, 1) );
%angle = %angle + 3.141529;
%newTransform = $player.player.position SPC "0 0 1" SPC %angle;
$player.player.setTransform(%newTransform);
}
function singlePlayerGame::onAIRespawn(%game, %client)
{
// DONT add the default tasks
//error("default tasks not added");
}
function singlePlayerGame::playerSpawned(%game, %player)
{
parent::playerSpawned(%game, %player);
}
function singlePlayerGame::gameOver(%game)
{
//enable the voice chat menu again...
if (isObject(training1BlockMap))
{
training1BlockMap.pop();
training1BlockMap.delete();
}
if(HelpTextGui.isVisible())
helpTextGui.setVisible(false);
//Make sure our hidden HUD elements are visible again
hideHudHACK(true);
//Make sure our sounds stopped playing
doSpecialEffect(5);
//re-enable the use of the settings button...
SinglePlayerEscSettingsBtn.setActive(1);
Parent::gameOver();
}
function trainingPreloads() //Load any skins..
{
navGraph.preload("skins/Gecko.lbioderm", true);
navGraph.preload("skins/Gecko.mbioderm", true);
navGraph.preload("skins/Gecko.hbioderm", true);
navGraph.preload("skins/base.lbioderm", true);
navGraph.preload("skins/HALO_Skin.lbioderm", true);
navGraph.preload("skins/HALO_Skin.mbioderm", true);
navGraph.preload("skins/HALO_Skin.hbioderm", true);
navGraph.preload("skins/sensor_pulse_large", true);
navGraph.preload("skins/base.hmale", false);
navGraph.preload("skins/beagle.hmale", false);
navGraph.preload("skins/base.mmale", false);
navGraph.preload("skins/beagle.mmale", false);
navGraph.preload("skins/base.lmale", false);
navGraph.preload("skins/swolf.mmale", false);
navGraph.preload("skins/beagle.lmale", false);
}
function SinglePlayerGame::missionLoadDone(%game)
{
Parent::missionLoadDone(%game);
trainingPreloads();
}
function serverCmdBuildClientTask(%client, %task, %team)
{
// player shouldnt be able to use the voice commands to do anything
}
function cancel(%sched)
{
parent::Cancel(%sched);
return true;
}
function lockArmorHack(%val)
{
if (%val)
{
movemap.pop();
modifiedmap.push();
}
else
{
movemap.push();
modifiedmap.pop();
}
//$player.player.setMoveState(true);
//$player.player.schedule(1000,"setMoveState", false);
}
function SinglePlayerGame::enterMissionArea(%game, %player){}
function SinglePlayerGame::leaveMissionArea(%game, %player)
{
schedule(1000,0,"missionComplete", $player.miscMsg[TDSBeginningWin] );
moveMap.schedule(1000, "pop");
}
};
activatePackage(Beginning);

File diff suppressed because it is too large Load diff

View file

@ -1,370 +1,370 @@
// don't want this executing when building graphs
if($OFFLINE_NAV_BUILD)
return;
// Script for Training
//===================================================================================
//error("Training 1 script");
//Note: Quite messy right now.. I'll organize when it's done
// package and callbacks
activatePackage(HotZone);
// variables
$numberOfEnemies[1] = 1;
$numberOfEnemies[2] = 1;
$numberOfEnemies[3] = 1;
$numberOfTeammates = 1;
$missionBotSkill[1] = 0.0;
$missionBotSkill[2] = 0.4;
$missionBotSkill[3] = 0.7;
// additional mission Audio
datablock AudioProfile(HeartbeatSound)
{
filename = "fx/misc/heartbeat.wav";
description = Audio2D;
preload = true;
looping = false;
};
package HotZone {
//BEGIN TRAINING PACKAGE =======================================================================
function SinglePlayerGame::initGameVars(%game)
{
echo("initializing training1 game vars");
}
function getTeammateGlobals()
{
$TeammateWarnom0 = "Raptor";
$teammateskill0 = 0.5;
$teammateVoice0 = Derm3;
$teammateEquipment0 = 0;
$teammateGender0 = Male;
$TeammateWarnom1 = "Cobra";
$teammateSkill1 = 0.5;
$teammateVoice1 = Derm3;
$teammateEquipment1 = 0;
$teammateGender1 = C;
$TeammateWarnom2 = "Sharp Tooth";
$teammateSkill2 = 0.5;
$teammateVoice2 = Derm3;
$teammateEquipment2 = 0;
$teammateGender2 = A;
$TeammateWarnom3 = "Snake";
$teammateSkill3 = 0.5;
$teammateVoice3 = Derm3;
$teammateEquipment3 = 0;
$teammateGender3 = A;
$TeammateWarnom4 = "Gila";
$teammateSkill4 = 0.5;
$teammateVoice4 = Derm3;
$teammateEquipment4 = 0;
$teammateGender4 = B;
}
function AIFollowPath::assume(%task, %client)
{
%task.setWeightFreq(30);
%task.setMonitorFreq(10);
// //next, start the pilot on his way to mounting the vehicle
// %client.pilotVehicle = true;
// %client.stepMove($player.flyer.position, 0.25, $AIModeMountVehicle);
}
function AIFollowPath::weight(%task, %client)
{
%task.setWeight(10000);
}
function AIFollowPath::monitor(%task, %client)
{
//messageall(0, " AITraining1Pilot::monitor "@%task.locationIndex);
%group = nameToId(FlightPath);
if(!%task.locationIndex)
%task.locationIndex = 0;
//HACK ALERT!!!
//since the path for this mission is completely straight, always head for the end of the path
//%location = %group.getObject(%task.locationIndex);
%location = %group.getObject(%group.getCount() - 1);
//see if we've mounted yet
if(%client.vehicleMounted)
{
%client.setPilotDestination(%location.position);
//else see if we're close enough to the current destination to choose the next
%pos = %client.vehicleMounted.position;
%pos2D = getWord(%pos, 0) SPC getWord(%pos, 1) SPC "0";
%dest = %group.getObject(%task.locationIndex).position;
%dest2D = getWord(%dest, 0) SPC getWord(%dest, 1) SPC "0";
if (VectorDist(%dest2D, %pos2D) < 20)
{
if(%group.getCount() > %task.locationIndex + 1) {
%task.locationIndex++;
cinematicEvent(%task.locationIndex);
}
//else messageAll(0, "Ride Over");
}
}
else
%client.stepMove($player.flyer.position, 0.25, $AIModeExpress);
}
function PlayGui::onWake(%this)
{
parent::onWake(%this);
//error("Waking training play gui");
// okay we know the victim...erm...player is looking
// and we hope they have a body so lets do this
if(!game.playedIntro) {
game.PlayGuiAwake = true;
beginMission();
}
}
function aiSetLoadout(%client)
{
%client.player.clearInventory();
%client.player.setArmor("heavy");
%client.player.setInventory("Chaingun",1,true);
%client.player.setInventory("ChaingunAmmo",999,true);
%client.player.setInventory("Disc",1,true);
%client.player.setInventory("Discammo",999,true);
%client.player.setInventory("Shocklance",1,true);
%client.player.setInventory("MissileLauncher",1,true);
%client.player.setInventory("MissileLauncherAmmo",999,true);
%client.player.setInventory("Mortar",1,true);
%client.player.setInventory("MortarAmmo",999,true);
%client.player.setInventory("AmmoPack",1,true);
%client.player.use("Mortar");
}
function beginHotZone() //Don't let the game reset itself a bunch of times
{
if (Game.playedIntro)
return;
%spawn = nameToId(introFlyerSP);
$player.flyer = new FlyingVehicle(Flyer) {
position = %spawn.position;
rotation = %spawn.rotation;
scale = "1 1 1";
dataBlock = "HAPCFlyer";
};
%pilot = $teammate0;
game.playedIntro = true;
$player.flyer.pilot = $teammate0;
setTargetSkin(%pilot.target, $teamSkin[$playerTeam]);
%pilot.player.setArmor(light);
%pilot.pilotVehicle = false;
$player.flyer.mountObject(%pilot.player, 0);
%pilot.setControlObject($player.flyer);
%pilot.setPilotPitchRange(-0.2, 0.05, 0.05);
%pilot.addTask(AIFollowPath);
$player.flyer.mountObject($player.player, 1);
$player.flyer.mountObject($teammate1.player, 2);
$player.flyer.mountObject($teammate2.player, 3);
$player.flyer.mountObject($teammate3.player, 4);
$player.flyer.mountObject($teammate4.player, 5);
aiSetLoadout($teammate1);
aiSetLoadout($teammate2);
aiSetLoadout($teammate3);
aiSetLoadout($teammate4);
$player.player.setTransform($player.player.position SPC %spawn.rotation);
$HotZoneBlackout = ServerConnection.schedule(3000, setBlackOut, false, 4000);
//Has to be added after all the bots.. otherwise they die by lava somehow
new WaterBlock(Lava) {
position = "-224 -264 93.1568";
rotation = "1 0 0 0";
scale = "768 608 27.0092";
liquidType = "Lava";
density = "1";
viscosity = "15";
waveMagnitude = "1";
surfaceTexture = "LiquidTiles/Lava";
surfaceOpacity = "1";
envMapTexture = "lava/skies/lava_starrynite_emap";
envMapIntensity = "0.2";
submergeTexture[0] = "special/lavadeath_1";
submergeTexture[1] = "special/lavadeath_2";
removeWetEdges = "1";
locked = "true";
};
}
function MP3Audio::play(%this)
{
//too bad...no mp3 in training
}
function toggleCommanderMap(%val)
{
if ( %val )
messageClient($player, 0, $player.miscMsg[noCC]);
}
function toggleTaskListDlg( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noTaskListDlg] );
}
function toggleInventoryHud( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noInventoryHUD] );
}
function toggleNetDisplayHud( %val )
{
// Hello, McFly? This is training! There's no net in training!
}
function voiceCapture( %val )
{
// Uh, who do you think you are talking to?
}
function giveall()
{
error("When the going gets tough...wussies like you start cheating!");
messageClient($player, 0, "Cheating eh? What\'s next? Camping?");
}
// get the ball rolling
//------------------------------------------------------------------------------
function startCurrentMission()
{
playGui.add(outerChatHud);
//fade up from black
ServerConnection.setBlackOut(true, 0);
}
//------------------------------------------------------------------------------
function SinglePlayerGame::equip(%game, %player)
{
//ya start with nothing...NOTHING!
%player.clearInventory();
for(%i =0; %i<$InventoryHudCount; %i++)
%player.client.setInventoryHudItem($InventoryHudData[%i, itemDataName], 0, 1);
%player.client.clearBackpackIcon();
%set = %player.client.equipment;
echo("using default equipment");
%player.setArmor("Light");
%player.setInventory(RepairKit,1);
%player.setInventory(Chaingun, 1);
%player.setInventory(ChaingunAmmo, 100);
%player.setInventory(Disc,1);
%player.setInventory(DiscAmmo, 20);
%player.setInventory(Shocklance, 1);
%player.setInventory(AmmoPack, 1);
//DefaultGame.cs does not assign flamer..
%player.setInventory(flamer, 1);
%player.weaponCount = 4;
%player.use(Chaingun);
}
function spawnSinglePlayer()
{
resetWildCat();
parent::spawnSinglePlayer();
}
function singlePlayerGame::onAIRespawn(%game, %client)
{
// DONT add the default tasks
//error("default tasks not added");
}
function singlePlayerGame::playerSpawned(%game, %player)
{
parent::playerSpawned(%game, %player);
}
function singlePlayerGame::gameOver(%game)
{
//enable the voice chat menu again...
if (isObject(training1BlockMap))
{
training1BlockMap.pop();
training1BlockMap.delete();
}
if(HelpTextGui.isVisible())
helpTextGui.setVisible(false);
//re-enable the use of the settings button...
SinglePlayerEscSettingsBtn.setActive(1);
Parent::gameOver();
}
function trainingPreloads() //Load any skins..
{
navGraph.preload("skins/Gecko.lbioderm", true);
navGraph.preload("skins/Gecko.mbioderm", true);
navGraph.preload("skins/Gecko.hbioderm", true);
navGraph.preload("skins/base.lbioderm", true);
navGraph.preload("skins/HALO_Skin.lbioderm", true);
navGraph.preload("skins/HALO_Skin.mbioderm", true);
navGraph.preload("skins/HALO_Skin.hbioderm", true);
navGraph.preload("skins/sensor_pulse_large", true);
navGraph.preload("skins/base.hmale", false);
navGraph.preload("skins/beagle.hmale", false);
navGraph.preload("skins/base.mmale", false);
navGraph.preload("skins/beagle.mmale", false);
navGraph.preload("skins/base.lmale", false);
navGraph.preload("skins/swolf.mmale", false);
navGraph.preload("skins/beagle.lmale", false);
}
function SinglePlayerGame::missionLoadDone(%game)
{
Parent::missionLoadDone(%game);
trainingPreloads();
}
function serverCmdBuildClientTask(%client, %task, %team)
{
// player shouldnt be able to use the voice commands to do anything
}
};
package vehicleHack
{
function AIConnection::isMountingVehicle(%client){ return true; }
};
activatePackage(vehicleHack);
function setActionThread(%player,%anim,%bool)
{
%player.setActionThread(%anim,%bool);
}
// don't want this executing when building graphs
if($OFFLINE_NAV_BUILD)
return;
// Script for Training
//===================================================================================
//error("Training 1 script");
//Note: Quite messy right now.. I'll organize when it's done
// package and callbacks
activatePackage(HotZone);
// variables
$numberOfEnemies[1] = 1;
$numberOfEnemies[2] = 1;
$numberOfEnemies[3] = 1;
$numberOfTeammates = 1;
$missionBotSkill[1] = 0.0;
$missionBotSkill[2] = 0.4;
$missionBotSkill[3] = 0.7;
// additional mission Audio
datablock AudioProfile(HeartbeatSound)
{
filename = "fx/misc/heartbeat.wav";
description = Audio2D;
preload = true;
looping = false;
};
package HotZone {
//BEGIN TRAINING PACKAGE =======================================================================
function SinglePlayerGame::initGameVars(%game)
{
echo("initializing training1 game vars");
}
function getTeammateGlobals()
{
$TeammateWarnom0 = "Raptor";
$teammateskill0 = 0.5;
$teammateVoice0 = Derm3;
$teammateEquipment0 = 0;
$teammateGender0 = Male;
$TeammateWarnom1 = "Cobra";
$teammateSkill1 = 0.5;
$teammateVoice1 = Derm3;
$teammateEquipment1 = 0;
$teammateGender1 = C;
$TeammateWarnom2 = "Sharp Tooth";
$teammateSkill2 = 0.5;
$teammateVoice2 = Derm3;
$teammateEquipment2 = 0;
$teammateGender2 = A;
$TeammateWarnom3 = "Snake";
$teammateSkill3 = 0.5;
$teammateVoice3 = Derm3;
$teammateEquipment3 = 0;
$teammateGender3 = A;
$TeammateWarnom4 = "Gila";
$teammateSkill4 = 0.5;
$teammateVoice4 = Derm3;
$teammateEquipment4 = 0;
$teammateGender4 = B;
}
function AIFollowPath::assume(%task, %client)
{
%task.setWeightFreq(30);
%task.setMonitorFreq(10);
// //next, start the pilot on his way to mounting the vehicle
// %client.pilotVehicle = true;
// %client.stepMove($player.flyer.position, 0.25, $AIModeMountVehicle);
}
function AIFollowPath::weight(%task, %client)
{
%task.setWeight(10000);
}
function AIFollowPath::monitor(%task, %client)
{
//messageall(0, " AITraining1Pilot::monitor "@%task.locationIndex);
%group = nameToId(FlightPath);
if(!%task.locationIndex)
%task.locationIndex = 0;
//HACK ALERT!!!
//since the path for this mission is completely straight, always head for the end of the path
//%location = %group.getObject(%task.locationIndex);
%location = %group.getObject(%group.getCount() - 1);
//see if we've mounted yet
if(%client.vehicleMounted)
{
%client.setPilotDestination(%location.position);
//else see if we're close enough to the current destination to choose the next
%pos = %client.vehicleMounted.position;
%pos2D = getWord(%pos, 0) SPC getWord(%pos, 1) SPC "0";
%dest = %group.getObject(%task.locationIndex).position;
%dest2D = getWord(%dest, 0) SPC getWord(%dest, 1) SPC "0";
if (VectorDist(%dest2D, %pos2D) < 20)
{
if(%group.getCount() > %task.locationIndex + 1) {
%task.locationIndex++;
cinematicEvent(%task.locationIndex);
}
//else messageAll(0, "Ride Over");
}
}
else
%client.stepMove($player.flyer.position, 0.25, $AIModeExpress);
}
function PlayGui::onWake(%this)
{
parent::onWake(%this);
//error("Waking training play gui");
// okay we know the victim...erm...player is looking
// and we hope they have a body so lets do this
if(!game.playedIntro) {
game.PlayGuiAwake = true;
beginMission();
}
}
function aiSetLoadout(%client)
{
%client.player.clearInventory();
%client.player.setArmor("heavy");
%client.player.setInventory("Chaingun",1,true);
%client.player.setInventory("ChaingunAmmo",999,true);
%client.player.setInventory("Disc",1,true);
%client.player.setInventory("Discammo",999,true);
%client.player.setInventory("Shocklance",1,true);
%client.player.setInventory("MissileLauncher",1,true);
%client.player.setInventory("MissileLauncherAmmo",999,true);
%client.player.setInventory("Mortar",1,true);
%client.player.setInventory("MortarAmmo",999,true);
%client.player.setInventory("AmmoPack",1,true);
%client.player.use("Mortar");
}
function beginHotZone() //Don't let the game reset itself a bunch of times
{
if (Game.playedIntro)
return;
%spawn = nameToId(introFlyerSP);
$player.flyer = new FlyingVehicle(Flyer) {
position = %spawn.position;
rotation = %spawn.rotation;
scale = "1 1 1";
dataBlock = "HAPCFlyer";
};
%pilot = $teammate0;
game.playedIntro = true;
$player.flyer.pilot = $teammate0;
setTargetSkin(%pilot.target, $teamSkin[$playerTeam]);
%pilot.player.setArmor(light);
%pilot.pilotVehicle = false;
$player.flyer.mountObject(%pilot.player, 0);
%pilot.setControlObject($player.flyer);
%pilot.setPilotPitchRange(-0.2, 0.05, 0.05);
%pilot.addTask(AIFollowPath);
$player.flyer.mountObject($player.player, 1);
$player.flyer.mountObject($teammate1.player, 2);
$player.flyer.mountObject($teammate2.player, 3);
$player.flyer.mountObject($teammate3.player, 4);
$player.flyer.mountObject($teammate4.player, 5);
aiSetLoadout($teammate1);
aiSetLoadout($teammate2);
aiSetLoadout($teammate3);
aiSetLoadout($teammate4);
$player.player.setTransform($player.player.position SPC %spawn.rotation);
$HotZoneBlackout = ServerConnection.schedule(3000, setBlackOut, false, 4000);
//Has to be added after all the bots.. otherwise they die by lava somehow
new WaterBlock(Lava) {
position = "-224 -264 93.1568";
rotation = "1 0 0 0";
scale = "768 608 27.0092";
liquidType = "Lava";
density = "1";
viscosity = "15";
waveMagnitude = "1";
surfaceTexture = "LiquidTiles/Lava";
surfaceOpacity = "1";
envMapTexture = "lava/skies/lava_starrynite_emap";
envMapIntensity = "0.2";
submergeTexture[0] = "special/lavadeath_1";
submergeTexture[1] = "special/lavadeath_2";
removeWetEdges = "1";
locked = "true";
};
}
function MP3Audio::play(%this)
{
//too bad...no mp3 in training
}
function toggleCommanderMap(%val)
{
if ( %val )
messageClient($player, 0, $player.miscMsg[noCC]);
}
function toggleTaskListDlg( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noTaskListDlg] );
}
function toggleInventoryHud( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noInventoryHUD] );
}
function toggleNetDisplayHud( %val )
{
// Hello, McFly? This is training! There's no net in training!
}
function voiceCapture( %val )
{
// Uh, who do you think you are talking to?
}
function giveall()
{
error("When the going gets tough...wussies like you start cheating!");
messageClient($player, 0, "Cheating eh? What\'s next? Camping?");
}
// get the ball rolling
//------------------------------------------------------------------------------
function startCurrentMission()
{
playGui.add(outerChatHud);
//fade up from black
ServerConnection.setBlackOut(true, 0);
}
//------------------------------------------------------------------------------
function SinglePlayerGame::equip(%game, %player)
{
//ya start with nothing...NOTHING!
%player.clearInventory();
for(%i =0; %i<$InventoryHudCount; %i++)
%player.client.setInventoryHudItem($InventoryHudData[%i, itemDataName], 0, 1);
%player.client.clearBackpackIcon();
%set = %player.client.equipment;
echo("using default equipment");
%player.setArmor("Light");
%player.setInventory(RepairKit,1);
%player.setInventory(Chaingun, 1);
%player.setInventory(ChaingunAmmo, 100);
%player.setInventory(Disc,1);
%player.setInventory(DiscAmmo, 20);
%player.setInventory(Shocklance, 1);
%player.setInventory(AmmoPack, 1);
//DefaultGame.cs does not assign flamer..
%player.setInventory(flamer, 1);
%player.weaponCount = 4;
%player.use(Chaingun);
}
function spawnSinglePlayer()
{
resetWildCat();
parent::spawnSinglePlayer();
}
function singlePlayerGame::onAIRespawn(%game, %client)
{
// DONT add the default tasks
//error("default tasks not added");
}
function singlePlayerGame::playerSpawned(%game, %player)
{
parent::playerSpawned(%game, %player);
}
function singlePlayerGame::gameOver(%game)
{
//enable the voice chat menu again...
if (isObject(training1BlockMap))
{
training1BlockMap.pop();
training1BlockMap.delete();
}
if(HelpTextGui.isVisible())
helpTextGui.setVisible(false);
//re-enable the use of the settings button...
SinglePlayerEscSettingsBtn.setActive(1);
Parent::gameOver();
}
function trainingPreloads() //Load any skins..
{
navGraph.preload("skins/Gecko.lbioderm", true);
navGraph.preload("skins/Gecko.mbioderm", true);
navGraph.preload("skins/Gecko.hbioderm", true);
navGraph.preload("skins/base.lbioderm", true);
navGraph.preload("skins/HALO_Skin.lbioderm", true);
navGraph.preload("skins/HALO_Skin.mbioderm", true);
navGraph.preload("skins/HALO_Skin.hbioderm", true);
navGraph.preload("skins/sensor_pulse_large", true);
navGraph.preload("skins/base.hmale", false);
navGraph.preload("skins/beagle.hmale", false);
navGraph.preload("skins/base.mmale", false);
navGraph.preload("skins/beagle.mmale", false);
navGraph.preload("skins/base.lmale", false);
navGraph.preload("skins/swolf.mmale", false);
navGraph.preload("skins/beagle.lmale", false);
}
function SinglePlayerGame::missionLoadDone(%game)
{
Parent::missionLoadDone(%game);
trainingPreloads();
}
function serverCmdBuildClientTask(%client, %task, %team)
{
// player shouldnt be able to use the voice commands to do anything
}
};
package vehicleHack
{
function AIConnection::isMountingVehicle(%client){ return true; }
};
activatePackage(vehicleHack);
function setActionThread(%player,%anim,%bool)
{
%player.setActionThread(%anim,%bool);
}

File diff suppressed because it is too large Load diff

View file

@ -1,44 +1,44 @@
package Earth
{
function defineGeneralAI()
{
$Bot[0,"Name"] = "Jake Marvin";
$Bot[0,"Race"] = "Human";
$Bot[0,"Sex"] = "Male";
$Bot[0,"Skin"] = "Beagle";
$Bot[0,"Voice"] = "Male1";
$Bot[0,"VoicePitch"] = 1;
$Bot[0,"Team"] = 1;
$Bot[0,"Weapons"] = "Chaingun Disc Shocklance";
$Bot[0,"Pack"] = "AmmoPack";
$Bot[0,"Armor"] = "Light";
$Bot[0,"Objectives"] = false;
$Bot[0,"Ammo"] = "200 20 0";
$Bot[0,"RepairKits"] = 2;
$Bot[0,"Mines"] = 3;
$Bot[0,"Grenades"] = 3;
$Bot[0,"Transform"] = "442.099 -133.969 117.073 0 0 1 221.735";
$Bot[0,"Health"] = 1;
$Bot[1,"Name"] = "Luke Maverick";
$Bot[1,"Race"] = "Human";
$Bot[1,"Sex"] = "Male";
$Bot[1,"Skin"] = "Storm";
$Bot[1,"Voice"] = "Male3";
$Bot[1,"VoicePitch"] = 1;
$Bot[1,"Team"] = 1;
$Bot[1,"Weapons"] = "Blaster Shocklance";
$Bot[1,"Pack"] = "MiningTool";
$Bot[1,"UsePack"] = true;
$Bot[1,"Armor"] = "Light";
$Bot[1,"Objectives"] = false;
$Bot[1,"Ammo"] = "";
$Bot[1,"RepairKits"] = 2;
$Bot[1,"Mines"] = 0;
$Bot[1,"Grenades"] = 0;
$Bot[1,"Transform"] = "-1051.55 483.736 134.086 0 0 1 173.942";
$Bot[1,"Health"] = 1;
$BotCount = 2;
}
};
package Earth
{
function defineGeneralAI()
{
$Bot[0,"Name"] = "Jake Marvin";
$Bot[0,"Race"] = "Human";
$Bot[0,"Sex"] = "Male";
$Bot[0,"Skin"] = "Beagle";
$Bot[0,"Voice"] = "Male1";
$Bot[0,"VoicePitch"] = 1;
$Bot[0,"Team"] = 1;
$Bot[0,"Weapons"] = "Chaingun Disc Shocklance";
$Bot[0,"Pack"] = "AmmoPack";
$Bot[0,"Armor"] = "Light";
$Bot[0,"Objectives"] = false;
$Bot[0,"Ammo"] = "200 20 0";
$Bot[0,"RepairKits"] = 2;
$Bot[0,"Mines"] = 3;
$Bot[0,"Grenades"] = 3;
$Bot[0,"Transform"] = "442.099 -133.969 117.073 0 0 1 221.735";
$Bot[0,"Health"] = 1;
$Bot[1,"Name"] = "Luke Maverick";
$Bot[1,"Race"] = "Human";
$Bot[1,"Sex"] = "Male";
$Bot[1,"Skin"] = "Storm";
$Bot[1,"Voice"] = "Male3";
$Bot[1,"VoicePitch"] = 1;
$Bot[1,"Team"] = 1;
$Bot[1,"Weapons"] = "Blaster Shocklance";
$Bot[1,"Pack"] = "MiningTool";
$Bot[1,"UsePack"] = true;
$Bot[1,"Armor"] = "Light";
$Bot[1,"Objectives"] = false;
$Bot[1,"Ammo"] = "";
$Bot[1,"RepairKits"] = 2;
$Bot[1,"Mines"] = 0;
$Bot[1,"Grenades"] = 0;
$Bot[1,"Transform"] = "-1051.55 483.736 134.086 0 0 1 173.942";
$Bot[1,"Health"] = 1;
$BotCount = 2;
}
};

File diff suppressed because it is too large Load diff

View file

@ -1,36 +1,36 @@
//Example for map Script
package Example //Must be our mission name for package to activate before the functions are called.
{
function defineGeneralAI() //Called to load all general AI's for this map -- will be moved so it's stored in a BASIC file
{
//These arrays are for general bots
$Bot[0,"Name"] = "A bot.";
$Bot[0,"Race"] = "Human";
//Very important or the console will get spammed.
//Bioderms and Criollos MUST be Male.
//Draakans can be types A, B, or C.
$Bot[0,"Sex"] = "Male";
$Bot[0,"Skin"] = "Beagle"; //Skin. Don't use the actual team name. (Blood Eagle for example)
$Bot[0,"Voice"] = "Male1"; //Voice. Don't use the fancy name (Psycho for example).
$Bot[0,"VoicePitch"] = 1;
$Bot[0,"Team"] = 1; //Human
$Bot[0,"Weapons"] = "Chaingun Disc Shocklance"; //List the weapons with spaces. The first weapon listed will be the one he has out on spawn.
$Bot[0,"Pack"] = "AmmoPack";
//The ammo for each weapon in "Weapons", make sure it's in the same spot in the string as the weapon.
//If the weapon doesn't use ammo, just place a zero.
$Bot[0,"Ammo"] = "200 30 0";
$Bot[0,"RepairKits"] = 1; //Yea.. rep kits
$Bot[0,"Mines"] = 1; //Mines!!
$Bot[0,"Grenades"] = 3; //Grenades. I'll make it so you can tell which kind of nades.
$Bot[0,"Transform"] = "0 0 0 1 0 0 0"; //First 3 numbers are the position. The rest is the rotation.
//These are for detailing on the bots.. shouldn't really be used unless you got a good reason to.
$Bot[0,"Health"] = 1; //I'm pretty sure 1 is the max for all armors.
$BotCount = 1; //Tell the game how many general AI's there are.
}
};
//You don't have to activate this package yourself, the game activates it just before loading AI's
//Example for map Script
package Example //Must be our mission name for package to activate before the functions are called.
{
function defineGeneralAI() //Called to load all general AI's for this map -- will be moved so it's stored in a BASIC file
{
//These arrays are for general bots
$Bot[0,"Name"] = "A bot.";
$Bot[0,"Race"] = "Human";
//Very important or the console will get spammed.
//Bioderms and Criollos MUST be Male.
//Draakans can be types A, B, or C.
$Bot[0,"Sex"] = "Male";
$Bot[0,"Skin"] = "Beagle"; //Skin. Don't use the actual team name. (Blood Eagle for example)
$Bot[0,"Voice"] = "Male1"; //Voice. Don't use the fancy name (Psycho for example).
$Bot[0,"VoicePitch"] = 1;
$Bot[0,"Team"] = 1; //Human
$Bot[0,"Weapons"] = "Chaingun Disc Shocklance"; //List the weapons with spaces. The first weapon listed will be the one he has out on spawn.
$Bot[0,"Pack"] = "AmmoPack";
//The ammo for each weapon in "Weapons", make sure it's in the same spot in the string as the weapon.
//If the weapon doesn't use ammo, just place a zero.
$Bot[0,"Ammo"] = "200 30 0";
$Bot[0,"RepairKits"] = 1; //Yea.. rep kits
$Bot[0,"Mines"] = 1; //Mines!!
$Bot[0,"Grenades"] = 3; //Grenades. I'll make it so you can tell which kind of nades.
$Bot[0,"Transform"] = "0 0 0 1 0 0 0"; //First 3 numbers are the position. The rest is the rotation.
//These are for detailing on the bots.. shouldn't really be used unless you got a good reason to.
$Bot[0,"Health"] = 1; //I'm pretty sure 1 is the max for all armors.
$BotCount = 1; //Tell the game how many general AI's there are.
}
};
//You don't have to activate this package yourself, the game activates it just before loading AI's

View file

@ -1,370 +1,370 @@
// don't want this executing when building graphs
if($OFFLINE_NAV_BUILD)
return;
// Script for Training
//===================================================================================
//error("Training 1 script");
//Note: Quite messy right now.. I'll organize when it's done
// package and callbacks
activatePackage(HotZone);
// variables
$numberOfEnemies[1] = 0;
$numberOfEnemies[2] = 0;
$numberOfEnemies[3] = 0;
$numberOfTeammates = 5;
$missionBotSkill[1] = 0.0;
$missionBotSkill[2] = 0.4;
$missionBotSkill[3] = 0.7;
// additional mission Audio
datablock AudioProfile(HeartbeatSound)
{
filename = "fx/misc/heartbeat.wav";
description = Audio2D;
preload = true;
looping = false;
};
package HotZone {
//BEGIN TRAINING PACKAGE =======================================================================
function SinglePlayerGame::initGameVars(%game)
{
echo("initializing training1 game vars");
}
function getTeammateGlobals()
{
$TeammateWarnom0 = "Raptor";
$teammateskill0 = 0.5;
$teammateVoice0 = Derm3;
$teammateEquipment0 = 0;
$teammateGender0 = A;
$TeammateWarnom1 = "Cobra";
$teammateSkill1 = 0.5;
$teammateVoice1 = Derm3;
$teammateEquipment1 = 0;
$teammateGender1 = C;
$TeammateWarnom2 = "Sharp Tooth";
$teammateSkill2 = 0.5;
$teammateVoice2 = Derm3;
$teammateEquipment2 = 0;
$teammateGender2 = A;
$TeammateWarnom3 = "Snake";
$teammateSkill3 = 0.5;
$teammateVoice3 = Derm3;
$teammateEquipment3 = 0;
$teammateGender3 = A;
$TeammateWarnom4 = "Gila";
$teammateSkill4 = 0.5;
$teammateVoice4 = Derm3;
$teammateEquipment4 = 0;
$teammateGender4 = B;
}
function AIFollowPath::assume(%task, %client)
{
%task.setWeightFreq(30);
%task.setMonitorFreq(10);
// //next, start the pilot on his way to mounting the vehicle
// %client.pilotVehicle = true;
// %client.stepMove($player.flyer.position, 0.25, $AIModeMountVehicle);
}
function AIFollowPath::weight(%task, %client)
{
%task.setWeight(10000);
}
function AIFollowPath::monitor(%task, %client)
{
//messageall(0, " AITraining1Pilot::monitor "@%task.locationIndex);
%group = nameToId(FlightPath);
if(!%task.locationIndex)
%task.locationIndex = 0;
//HACK ALERT!!!
//since the path for this mission is completely straight, always head for the end of the path
//%location = %group.getObject(%task.locationIndex);
%location = %group.getObject(%group.getCount() - 1);
//see if we've mounted yet
if(%client.vehicleMounted)
{
%client.setPilotDestination(%location.position);
//else see if we're close enough to the current destination to choose the next
%pos = %client.vehicleMounted.position;
%pos2D = getWord(%pos, 0) SPC getWord(%pos, 1) SPC "0";
%dest = %group.getObject(%task.locationIndex).position;
%dest2D = getWord(%dest, 0) SPC getWord(%dest, 1) SPC "0";
if (VectorDist(%dest2D, %pos2D) < 20)
{
if(%group.getCount() > %task.locationIndex + 1) {
%task.locationIndex++;
cinematicEvent(%task.locationIndex);
}
//else messageAll(0, "Ride Over");
}
}
else
%client.stepMove($player.flyer.position, 0.25, $AIModeExpress);
}
function PlayGui::onWake(%this)
{
parent::onWake(%this);
//error("Waking training play gui");
// okay we know the victim...erm...player is looking
// and we hope they have a body so lets do this
if(!game.playedIntro) {
game.PlayGuiAwake = true;
beginHotZone();
}
}
function aiSetLoadout(%client)
{
%client.player.clearInventory();
%client.player.setArmor("heavy");
%client.player.setInventory("Chaingun",1,true);
%client.player.setInventory("ChaingunAmmo",999,true);
%client.player.setInventory("Disc",1,true);
%client.player.setInventory("Discammo",999,true);
%client.player.setInventory("Shocklance",1,true);
%client.player.setInventory("MissileLauncher",1,true);
%client.player.setInventory("MissileLauncherAmmo",999,true);
%client.player.setInventory("Mortar",1,true);
%client.player.setInventory("MortarAmmo",999,true);
%client.player.setInventory("AmmoPack",1,true);
%client.player.use("Mortar");
}
function beginHotZone() //Don't let the game reset itself a bunch of times
{
if (Game.playedIntro)
return;
%spawn = nameToId();
$player.flyer = new FlyingVehicle(Flyer) {
position = %spawn.position;
rotation = %spawn.rotation;
scale = "1 1 1";
dataBlock = "HAPCFlyer";
};
%pilot = $teammate0;
game.playedIntro = true;
$player.flyer.pilot = $teammate0;
setTargetSkin(%pilot.target, $teamSkin[$playerTeam]);
%pilot.player.setArmor(light);
%pilot.pilotVehicle = false;
$player.flyer.mountObject(%pilot.player, 0);
%pilot.setControlObject($player.flyer);
%pilot.setPilotPitchRange(-0.2, 0.05, 0.05);
%pilot.addTask(AIFollowPath);
$player.flyer.mountObject($player.player, 1);
$player.flyer.mountObject($teammate1.player, 2);
$player.flyer.mountObject($teammate2.player, 3);
$player.flyer.mountObject($teammate3.player, 4);
$player.flyer.mountObject($teammate4.player, 5);
aiSetLoadout($teammate1);
aiSetLoadout($teammate2);
aiSetLoadout($teammate3);
aiSetLoadout($teammate4);
$player.player.setTransform($player.player.position SPC %spawn.rotation);
$HotZoneBlackout = ServerConnection.schedule(3000, setBlackOut, false, 4000);
//Has to be added after all the bots.. otherwise they die by lava somehow
new WaterBlock(Lava) {
position = "-224 -264 93.1568";
rotation = "1 0 0 0";
scale = "768 608 27.0092";
liquidType = "Lava";
density = "1";
viscosity = "15";
waveMagnitude = "1";
surfaceTexture = "LiquidTiles/Lava";
surfaceOpacity = "1";
envMapTexture = "lava/skies/lava_starrynite_emap";
envMapIntensity = "0.2";
submergeTexture[0] = "special/lavadeath_1";
submergeTexture[1] = "special/lavadeath_2";
removeWetEdges = "1";
locked = "true";
};
}
function MP3Audio::play(%this)
{
//too bad...no mp3 in training
}
function toggleCommanderMap(%val)
{
if ( %val )
messageClient($player, 0, $player.miscMsg[noCC]);
}
function toggleTaskListDlg( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noTaskListDlg] );
}
function toggleInventoryHud( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noInventoryHUD] );
}
function toggleNetDisplayHud( %val )
{
// Hello, McFly? This is training! There's no net in training!
}
function voiceCapture( %val )
{
// Uh, who do you think you are talking to?
}
function giveall()
{
error("When the going gets tough...wussies like you start cheating!");
messageClient($player, 0, "Cheating eh? What\'s next? Camping?");
}
// get the ball rolling
//------------------------------------------------------------------------------
function startCurrentMission()
{
playGui.add(outerChatHud);
//fade up from black
ServerConnection.setBlackOut(true, 0);
}
//------------------------------------------------------------------------------
function SinglePlayerGame::equip(%game, %player)
{
//ya start with nothing...NOTHING!
%player.clearInventory();
for(%i =0; %i<$InventoryHudCount; %i++)
%player.client.setInventoryHudItem($InventoryHudData[%i, itemDataName], 0, 1);
%player.client.clearBackpackIcon();
%set = %player.client.equipment;
echo("using default equipment");
%player.setArmor("Light");
%player.setInventory(RepairKit,1);
%player.setInventory(Chaingun, 1);
%player.setInventory(ChaingunAmmo, 100);
%player.setInventory(Disc,1);
%player.setInventory(DiscAmmo, 20);
%player.setInventory(Shocklance, 1);
%player.setInventory(AmmoPack, 1);
//DefaultGame.cs does not assign flamer..
%player.setInventory(flamer, 1);
%player.weaponCount = 4;
%player.use(Chaingun);
}
function spawnSinglePlayer()
{
resetWildCat();
parent::spawnSinglePlayer();
}
function singlePlayerGame::onAIRespawn(%game, %client)
{
// DONT add the default tasks
//error("default tasks not added");
}
function singlePlayerGame::playerSpawned(%game, %player)
{
parent::playerSpawned(%game, %player);
}
function singlePlayerGame::gameOver(%game)
{
//enable the voice chat menu again...
if (isObject(training1BlockMap))
{
training1BlockMap.pop();
training1BlockMap.delete();
}
if(HelpTextGui.isVisible())
helpTextGui.setVisible(false);
//re-enable the use of the settings button...
SinglePlayerEscSettingsBtn.setActive(1);
Parent::gameOver();
}
function trainingPreloads() //Load any skins..
{
navGraph.preload("skins/Gecko.lbioderm", true);
navGraph.preload("skins/Gecko.mbioderm", true);
navGraph.preload("skins/Gecko.hbioderm", true);
navGraph.preload("skins/base.lbioderm", true);
navGraph.preload("skins/HALO_Skin.lbioderm", true);
navGraph.preload("skins/HALO_Skin.mbioderm", true);
navGraph.preload("skins/HALO_Skin.hbioderm", true);
navGraph.preload("skins/sensor_pulse_large", true);
navGraph.preload("skins/base.hmale", false);
navGraph.preload("skins/beagle.hmale", false);
navGraph.preload("skins/base.mmale", false);
navGraph.preload("skins/beagle.mmale", false);
navGraph.preload("skins/base.lmale", false);
navGraph.preload("skins/swolf.mmale", false);
navGraph.preload("skins/beagle.lmale", false);
}
function SinglePlayerGame::missionLoadDone(%game)
{
Parent::missionLoadDone(%game);
trainingPreloads();
}
function serverCmdBuildClientTask(%client, %task, %team)
{
// player shouldnt be able to use the voice commands to do anything
}
};
package vehicleHack
{
function AIConnection::isMountingVehicle(%client){ return true; }
};
activatePackage(vehicleHack);
function setActionThread(%player,%anim,%bool)
{
%player.setActionThread(%anim,%bool);
}
// don't want this executing when building graphs
if($OFFLINE_NAV_BUILD)
return;
// Script for Training
//===================================================================================
//error("Training 1 script");
//Note: Quite messy right now.. I'll organize when it's done
// package and callbacks
activatePackage(HotZone);
// variables
$numberOfEnemies[1] = 0;
$numberOfEnemies[2] = 0;
$numberOfEnemies[3] = 0;
$numberOfTeammates = 5;
$missionBotSkill[1] = 0.0;
$missionBotSkill[2] = 0.4;
$missionBotSkill[3] = 0.7;
// additional mission Audio
datablock AudioProfile(HeartbeatSound)
{
filename = "fx/misc/heartbeat.wav";
description = Audio2D;
preload = true;
looping = false;
};
package HotZone {
//BEGIN TRAINING PACKAGE =======================================================================
function SinglePlayerGame::initGameVars(%game)
{
echo("initializing training1 game vars");
}
function getTeammateGlobals()
{
$TeammateWarnom0 = "Raptor";
$teammateskill0 = 0.5;
$teammateVoice0 = Derm3;
$teammateEquipment0 = 0;
$teammateGender0 = A;
$TeammateWarnom1 = "Cobra";
$teammateSkill1 = 0.5;
$teammateVoice1 = Derm3;
$teammateEquipment1 = 0;
$teammateGender1 = C;
$TeammateWarnom2 = "Sharp Tooth";
$teammateSkill2 = 0.5;
$teammateVoice2 = Derm3;
$teammateEquipment2 = 0;
$teammateGender2 = A;
$TeammateWarnom3 = "Snake";
$teammateSkill3 = 0.5;
$teammateVoice3 = Derm3;
$teammateEquipment3 = 0;
$teammateGender3 = A;
$TeammateWarnom4 = "Gila";
$teammateSkill4 = 0.5;
$teammateVoice4 = Derm3;
$teammateEquipment4 = 0;
$teammateGender4 = B;
}
function AIFollowPath::assume(%task, %client)
{
%task.setWeightFreq(30);
%task.setMonitorFreq(10);
// //next, start the pilot on his way to mounting the vehicle
// %client.pilotVehicle = true;
// %client.stepMove($player.flyer.position, 0.25, $AIModeMountVehicle);
}
function AIFollowPath::weight(%task, %client)
{
%task.setWeight(10000);
}
function AIFollowPath::monitor(%task, %client)
{
//messageall(0, " AITraining1Pilot::monitor "@%task.locationIndex);
%group = nameToId(FlightPath);
if(!%task.locationIndex)
%task.locationIndex = 0;
//HACK ALERT!!!
//since the path for this mission is completely straight, always head for the end of the path
//%location = %group.getObject(%task.locationIndex);
%location = %group.getObject(%group.getCount() - 1);
//see if we've mounted yet
if(%client.vehicleMounted)
{
%client.setPilotDestination(%location.position);
//else see if we're close enough to the current destination to choose the next
%pos = %client.vehicleMounted.position;
%pos2D = getWord(%pos, 0) SPC getWord(%pos, 1) SPC "0";
%dest = %group.getObject(%task.locationIndex).position;
%dest2D = getWord(%dest, 0) SPC getWord(%dest, 1) SPC "0";
if (VectorDist(%dest2D, %pos2D) < 20)
{
if(%group.getCount() > %task.locationIndex + 1) {
%task.locationIndex++;
cinematicEvent(%task.locationIndex);
}
//else messageAll(0, "Ride Over");
}
}
else
%client.stepMove($player.flyer.position, 0.25, $AIModeExpress);
}
function PlayGui::onWake(%this)
{
parent::onWake(%this);
//error("Waking training play gui");
// okay we know the victim...erm...player is looking
// and we hope they have a body so lets do this
if(!game.playedIntro) {
game.PlayGuiAwake = true;
beginHotZone();
}
}
function aiSetLoadout(%client)
{
%client.player.clearInventory();
%client.player.setArmor("heavy");
%client.player.setInventory("Chaingun",1,true);
%client.player.setInventory("ChaingunAmmo",999,true);
%client.player.setInventory("Disc",1,true);
%client.player.setInventory("Discammo",999,true);
%client.player.setInventory("Shocklance",1,true);
%client.player.setInventory("MissileLauncher",1,true);
%client.player.setInventory("MissileLauncherAmmo",999,true);
%client.player.setInventory("Mortar",1,true);
%client.player.setInventory("MortarAmmo",999,true);
%client.player.setInventory("AmmoPack",1,true);
%client.player.use("Mortar");
}
function beginHotZone() //Don't let the game reset itself a bunch of times
{
if (Game.playedIntro)
return;
%spawn = nameToId();
$player.flyer = new FlyingVehicle(Flyer) {
position = %spawn.position;
rotation = %spawn.rotation;
scale = "1 1 1";
dataBlock = "HAPCFlyer";
};
%pilot = $teammate0;
game.playedIntro = true;
$player.flyer.pilot = $teammate0;
setTargetSkin(%pilot.target, $teamSkin[$playerTeam]);
%pilot.player.setArmor(light);
%pilot.pilotVehicle = false;
$player.flyer.mountObject(%pilot.player, 0);
%pilot.setControlObject($player.flyer);
%pilot.setPilotPitchRange(-0.2, 0.05, 0.05);
%pilot.addTask(AIFollowPath);
$player.flyer.mountObject($player.player, 1);
$player.flyer.mountObject($teammate1.player, 2);
$player.flyer.mountObject($teammate2.player, 3);
$player.flyer.mountObject($teammate3.player, 4);
$player.flyer.mountObject($teammate4.player, 5);
aiSetLoadout($teammate1);
aiSetLoadout($teammate2);
aiSetLoadout($teammate3);
aiSetLoadout($teammate4);
$player.player.setTransform($player.player.position SPC %spawn.rotation);
$HotZoneBlackout = ServerConnection.schedule(3000, setBlackOut, false, 4000);
//Has to be added after all the bots.. otherwise they die by lava somehow
new WaterBlock(Lava) {
position = "-224 -264 93.1568";
rotation = "1 0 0 0";
scale = "768 608 27.0092";
liquidType = "Lava";
density = "1";
viscosity = "15";
waveMagnitude = "1";
surfaceTexture = "LiquidTiles/Lava";
surfaceOpacity = "1";
envMapTexture = "lava/skies/lava_starrynite_emap";
envMapIntensity = "0.2";
submergeTexture[0] = "special/lavadeath_1";
submergeTexture[1] = "special/lavadeath_2";
removeWetEdges = "1";
locked = "true";
};
}
function MP3Audio::play(%this)
{
//too bad...no mp3 in training
}
function toggleCommanderMap(%val)
{
if ( %val )
messageClient($player, 0, $player.miscMsg[noCC]);
}
function toggleTaskListDlg( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noTaskListDlg] );
}
function toggleInventoryHud( %val )
{
if ( %val )
messageClient( $player, 0, $player.miscMsg[noInventoryHUD] );
}
function toggleNetDisplayHud( %val )
{
// Hello, McFly? This is training! There's no net in training!
}
function voiceCapture( %val )
{
// Uh, who do you think you are talking to?
}
function giveall()
{
error("When the going gets tough...wussies like you start cheating!");
messageClient($player, 0, "Cheating eh? What\'s next? Camping?");
}
// get the ball rolling
//------------------------------------------------------------------------------
function startCurrentMission()
{
playGui.add(outerChatHud);
//fade up from black
ServerConnection.setBlackOut(true, 0);
}
//------------------------------------------------------------------------------
function SinglePlayerGame::equip(%game, %player)
{
//ya start with nothing...NOTHING!
%player.clearInventory();
for(%i =0; %i<$InventoryHudCount; %i++)
%player.client.setInventoryHudItem($InventoryHudData[%i, itemDataName], 0, 1);
%player.client.clearBackpackIcon();
%set = %player.client.equipment;
echo("using default equipment");
%player.setArmor("Light");
%player.setInventory(RepairKit,1);
%player.setInventory(Chaingun, 1);
%player.setInventory(ChaingunAmmo, 100);
%player.setInventory(Disc,1);
%player.setInventory(DiscAmmo, 20);
%player.setInventory(Shocklance, 1);
%player.setInventory(AmmoPack, 1);
//DefaultGame.cs does not assign flamer..
%player.setInventory(flamer, 1);
%player.weaponCount = 4;
%player.use(Chaingun);
}
function spawnSinglePlayer()
{
resetWildCat();
parent::spawnSinglePlayer();
}
function singlePlayerGame::onAIRespawn(%game, %client)
{
// DONT add the default tasks
//error("default tasks not added");
}
function singlePlayerGame::playerSpawned(%game, %player)
{
parent::playerSpawned(%game, %player);
}
function singlePlayerGame::gameOver(%game)
{
//enable the voice chat menu again...
if (isObject(training1BlockMap))
{
training1BlockMap.pop();
training1BlockMap.delete();
}
if(HelpTextGui.isVisible())
helpTextGui.setVisible(false);
//re-enable the use of the settings button...
SinglePlayerEscSettingsBtn.setActive(1);
Parent::gameOver();
}
function trainingPreloads() //Load any skins..
{
navGraph.preload("skins/Gecko.lbioderm", true);
navGraph.preload("skins/Gecko.mbioderm", true);
navGraph.preload("skins/Gecko.hbioderm", true);
navGraph.preload("skins/base.lbioderm", true);
navGraph.preload("skins/HALO_Skin.lbioderm", true);
navGraph.preload("skins/HALO_Skin.mbioderm", true);
navGraph.preload("skins/HALO_Skin.hbioderm", true);
navGraph.preload("skins/sensor_pulse_large", true);
navGraph.preload("skins/base.hmale", false);
navGraph.preload("skins/beagle.hmale", false);
navGraph.preload("skins/base.mmale", false);
navGraph.preload("skins/beagle.mmale", false);
navGraph.preload("skins/base.lmale", false);
navGraph.preload("skins/swolf.mmale", false);
navGraph.preload("skins/beagle.lmale", false);
}
function SinglePlayerGame::missionLoadDone(%game)
{
Parent::missionLoadDone(%game);
trainingPreloads();
}
function serverCmdBuildClientTask(%client, %task, %team)
{
// player shouldnt be able to use the voice commands to do anything
}
};
package vehicleHack
{
function AIConnection::isMountingVehicle(%client){ return true; }
};
activatePackage(vehicleHack);
function setActionThread(%player,%anim,%bool)
{
%player.setActionThread(%anim,%bool);
}

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -1,295 +1,295 @@
// MissionTypes = SinglePlayer
// DisplayName = Recruit
//--- MISSION BRIEFING BEGIN ---
//I am Raptor, your trainer..
//--- MISSION BRIEFING END ---
// PlanetName = Xeron, 3960 CE
// Bitmap = trn_5draconis
//--- MISSION STRING BEGIN ---
//<spush><font:Univers Condensed:18>OBJECTIVES:<spop>
//<bitmap:bullet_2><lmargin:24>Bleck<lmargin:0>
//--- MISSION STRING END ---
//--- MISSION BLURB BEGIN ---
//In the year 3060 CE, the first Alpha Viper training facility was built. It is now 900 years old on the day of your last training session before the war.
//--- MISSION BLURB END ---
//--- OBJECT WRITE BEGIN ---
new SimGroup(MissionGroup) {
cdTrack = "6";
powerCount = "0";
musicTrack = "desert";
new MissionArea(MissionArea) {
area = "-1024 -1024 2048 2048";
flightCeiling = "4000";
flightCeilingRange = "20";
locked = "true";
};
new SimGroup(Teams) {
powerCount = "0";
new SimGroup(Team1) {
powerCount = "0";
new SimGroup(spawnspheres) {
powerCount = "0";
};
new SimGroup(base0) {
new InteriorInstance() {
position = "415.795 109.654 111.4";
rotation = "0 0 1 139.229";
scale = "1 1 1";
interiorFile = "dbase_nefRaindance.dif";
showTerrainInside = "0";
};
new StaticShape() {
position = "452.967 135.507 98.3632";
rotation = "0 0 -1 40.107";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "GeneratorLarge";
lockCount = "0";
homingCount = "0";
Target = "33";
};
new StaticShape() {
position = "441.541 148.661 98.3793";
rotation = "0 0 1 139.802";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "GeneratorLarge";
lockCount = "0";
homingCount = "0";
Target = "34";
};
new StaticShape() {
position = "453.912 147.716 98.357";
rotation = "0 0 1 229.183";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "GeneratorLarge";
lockCount = "0";
homingCount = "0";
Target = "35";
};
new StaticShape() {
position = "438.218 134.772 120.525";
rotation = "1 0 0 0";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "SensorLargePulse";
lockCount = "0";
homingCount = "0";
Target = "36";
};
};
new SimGroup(dropPoints) {
new SimGroup(respawns) {
new Camera(RaptorSpawn) {
position = "428.742 126.147 99.5136";
rotation = "0 0 1 50.4203";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "1";
};
new Camera(PlayerSpawn) {
position = "432.421 129.211 99.1953";
rotation = "0 0 1 50.9932";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
};
new Camera(Spawn01) {
position = "434.675 126.105 99.4532";
rotation = "0 0 1 48.7014";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
};
new Camera(Spawn02) {
position = "430.299 131.876 99.634";
rotation = "0 0 1 51.5662";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
};
};
};
};
new SimGroup(team0) {
powerCount = "0";
};
new Sun(Sun) {
position = "0 0 0";
rotation = "1 0 0 0";
scale = "1 1 1";
direction = "0.57735 0.57735 -0.57735";
color = "1.000000 1.000000 1.000000 1.000000";
ambient = "0.500000 0.500000 0.500000 1.000000";
texture[0] = "special/sunFlare";
texture[1] = "special/sunFlare02";
texture[2] = "special/LensFlare/flare01";
texture[3] = "special/LensFlare/flare02";
texture[4] = "special/LensFlare/flare03";
lensFlareScale = "0.7";
lensFlareIntensity = "1";
frontFlareSize = "300";
backFlareSize = "450";
flareColor = "1.000000 1.000000 1.000000 1.000000";
locked = "true";
};
new TerrainBlock(Terrain) {
rotation = "1 0 0 0";
scale = "1 1 1";
detailTexture = "details/lavadet1";
terrainFile = "Training.ter";
squareSize = "8";
emptySquares = "217661 217676 86852 152390 87108 152646 218429 218444 232883 233139 364467 299189 364981 299702 234423";
position = "-1024 -1024 0";
};
new NavigationGraph(NavGraph) {
conjoinAngleDev = "50";
cullDensity = "0.3";
customArea = "0 0 0 0";
rotation = "0 0 0 0";
locked = "true";
scale = "1 1 1";
coverage = "0";
conjoinBowlDev = "20";
GraphFile = "Training.nav";
position = "0 0 0 1";
};
new SimGroup(ObserverDropPoints) {
powerCount = "0";
new Camera() {
position = "0 0 200";
rotation = "1 0 0 0";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
locked = "true";
};
};
new Sky(Sky) {
position = "692 -352 0";
rotation = "1 0 0 0";
scale = "1 1 1";
cloudHeightPer[0] = "0.349971";
cloudHeightPer[1] = "0.25";
cloudHeightPer[2] = "0.199973";
cloudSpeed1 = "0.0001";
cloudSpeed2 = "0.0002";
cloudSpeed3 = "0.0003";
visibleDistance = "550";
useSkyTextures = "1";
renderBottomTexture = "0";
SkySolidColor = "0.300000 0.100000 0.000000 0.800000";
fogDistance = "250";
fogColor = "0.300000 0.100000 0.000000 0.800000";
fogVolume1 = "100 0 85";
fogVolume2 = "600 85 270";
fogVolume3 = "0 0 0";
materialList = "sky_lava_starrynight.dml";
windVelocity = "1 0 0";
windEffectPrecipitation = "0";
fogVolumeColor1 = "128.000000 128.000000 128.000000 0.000000";
fogVolumeColor2 = "128.000000 128.000000 128.000000 0.000000";
fogVolumeColor3 = "128.000000 128.000000 128.000000 0.000000";
high_visibleDistance = "-1";
high_fogDistance = "-1";
high_fogVolume1 = "-1 5.98911e+07 1.03256e-38";
high_fogVolume2 = "-1 4.39735e+21 1.1119e-16";
high_fogVolume3 = "-1 6.71258e+22 1.21749e+22";
locked = "true";
};
};
new SimGroup(RandomOrganics) {
new TSStatic() {
position = "352.297 188.881 160.856";
rotation = "0 0 1 136.364";
scale = "1 1 1";
shapeName = "dorg16.dts";
};
new TSStatic() {
position = "380.548 229.443 175.643";
rotation = "0 0 -1 1.71778";
scale = "1 1 1";
shapeName = "dorg17.dts";
};
new TSStatic() {
position = "333.627 257.188 177.605";
rotation = "1 0 0 0";
scale = "1 1 1";
shapeName = "dorg19.dts";
};
new TSStatic() {
position = "567.086 57.3387 137.477";
rotation = "0 0 1 141.521";
scale = "1 1 1";
shapeName = "dorg16.dts";
};
new TSStatic() {
position = "477.072 -72.6936 150.153";
rotation = "0 0 1 132.353";
scale = "1 1 1";
shapeName = "dorg19.dts";
};
new TSStatic() {
position = "488.239 8.63118 159.288";
rotation = "0 0 1 91.1003";
scale = "1 1 1";
shapeName = "dorg18.dts";
};
new TSStatic() {
position = "558.369 176.842 152.425";
rotation = "0 0 1 27.502";
scale = "1 1 1";
shapeName = "dorg16.dts";
};
};
new SimGroup(environment) {
};
};
//--- OBJECT WRITE END ---
//Execute our mission script.
exec("scripts/Training.cs");
// MissionTypes = SinglePlayer
// DisplayName = Recruit
//--- MISSION BRIEFING BEGIN ---
//I am Raptor, your trainer..
//--- MISSION BRIEFING END ---
// PlanetName = Xeron, 3960 CE
// Bitmap = trn_5draconis
//--- MISSION STRING BEGIN ---
//<spush><font:Univers Condensed:18>OBJECTIVES:<spop>
//<bitmap:bullet_2><lmargin:24>Bleck<lmargin:0>
//--- MISSION STRING END ---
//--- MISSION BLURB BEGIN ---
//In the year 3060 CE, the first Alpha Viper training facility was built. It is now 900 years old on the day of your last training session before the war.
//--- MISSION BLURB END ---
//--- OBJECT WRITE BEGIN ---
new SimGroup(MissionGroup) {
cdTrack = "6";
powerCount = "0";
musicTrack = "desert";
new MissionArea(MissionArea) {
area = "-1024 -1024 2048 2048";
flightCeiling = "4000";
flightCeilingRange = "20";
locked = "true";
};
new SimGroup(Teams) {
powerCount = "0";
new SimGroup(Team1) {
powerCount = "0";
new SimGroup(spawnspheres) {
powerCount = "0";
};
new SimGroup(base0) {
new InteriorInstance() {
position = "415.795 109.654 111.4";
rotation = "0 0 1 139.229";
scale = "1 1 1";
interiorFile = "dbase_nefRaindance.dif";
showTerrainInside = "0";
};
new StaticShape() {
position = "452.967 135.507 98.3632";
rotation = "0 0 -1 40.107";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "GeneratorLarge";
lockCount = "0";
homingCount = "0";
Target = "33";
};
new StaticShape() {
position = "441.541 148.661 98.3793";
rotation = "0 0 1 139.802";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "GeneratorLarge";
lockCount = "0";
homingCount = "0";
Target = "34";
};
new StaticShape() {
position = "453.912 147.716 98.357";
rotation = "0 0 1 229.183";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "GeneratorLarge";
lockCount = "0";
homingCount = "0";
Target = "35";
};
new StaticShape() {
position = "438.218 134.772 120.525";
rotation = "1 0 0 0";
scale = "1 1 1";
nameTag = "Main";
dataBlock = "SensorLargePulse";
lockCount = "0";
homingCount = "0";
Target = "36";
};
};
new SimGroup(dropPoints) {
new SimGroup(respawns) {
new Camera(RaptorSpawn) {
position = "428.742 126.147 99.5136";
rotation = "0 0 1 50.4203";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "1";
};
new Camera(PlayerSpawn) {
position = "432.421 129.211 99.1953";
rotation = "0 0 1 50.9932";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
};
new Camera(Spawn01) {
position = "434.675 126.105 99.4532";
rotation = "0 0 1 48.7014";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
};
new Camera(Spawn02) {
position = "430.299 131.876 99.634";
rotation = "0 0 1 51.5662";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
};
};
};
};
new SimGroup(team0) {
powerCount = "0";
};
new Sun(Sun) {
position = "0 0 0";
rotation = "1 0 0 0";
scale = "1 1 1";
direction = "0.57735 0.57735 -0.57735";
color = "1.000000 1.000000 1.000000 1.000000";
ambient = "0.500000 0.500000 0.500000 1.000000";
texture[0] = "special/sunFlare";
texture[1] = "special/sunFlare02";
texture[2] = "special/LensFlare/flare01";
texture[3] = "special/LensFlare/flare02";
texture[4] = "special/LensFlare/flare03";
lensFlareScale = "0.7";
lensFlareIntensity = "1";
frontFlareSize = "300";
backFlareSize = "450";
flareColor = "1.000000 1.000000 1.000000 1.000000";
locked = "true";
};
new TerrainBlock(Terrain) {
rotation = "1 0 0 0";
scale = "1 1 1";
detailTexture = "details/lavadet1";
terrainFile = "Training.ter";
squareSize = "8";
emptySquares = "217661 217676 86852 152390 87108 152646 218429 218444 232883 233139 364467 299189 364981 299702 234423";
position = "-1024 -1024 0";
};
new NavigationGraph(NavGraph) {
conjoinAngleDev = "50";
cullDensity = "0.3";
customArea = "0 0 0 0";
rotation = "0 0 0 0";
locked = "true";
scale = "1 1 1";
coverage = "0";
conjoinBowlDev = "20";
GraphFile = "Training.nav";
position = "0 0 0 1";
};
new SimGroup(ObserverDropPoints) {
powerCount = "0";
new Camera() {
position = "0 0 200";
rotation = "1 0 0 0";
scale = "1 1 1";
dataBlock = "Observer";
lockCount = "0";
homingCount = "0";
team = "0";
locked = "true";
};
};
new Sky(Sky) {
position = "692 -352 0";
rotation = "1 0 0 0";
scale = "1 1 1";
cloudHeightPer[0] = "0.349971";
cloudHeightPer[1] = "0.25";
cloudHeightPer[2] = "0.199973";
cloudSpeed1 = "0.0001";
cloudSpeed2 = "0.0002";
cloudSpeed3 = "0.0003";
visibleDistance = "550";
useSkyTextures = "1";
renderBottomTexture = "0";
SkySolidColor = "0.300000 0.100000 0.000000 0.800000";
fogDistance = "250";
fogColor = "0.300000 0.100000 0.000000 0.800000";
fogVolume1 = "100 0 85";
fogVolume2 = "600 85 270";
fogVolume3 = "0 0 0";
materialList = "sky_lava_starrynight.dml";
windVelocity = "1 0 0";
windEffectPrecipitation = "0";
fogVolumeColor1 = "128.000000 128.000000 128.000000 0.000000";
fogVolumeColor2 = "128.000000 128.000000 128.000000 0.000000";
fogVolumeColor3 = "128.000000 128.000000 128.000000 0.000000";
high_visibleDistance = "-1";
high_fogDistance = "-1";
high_fogVolume1 = "-1 5.98911e+07 1.03256e-38";
high_fogVolume2 = "-1 4.39735e+21 1.1119e-16";
high_fogVolume3 = "-1 6.71258e+22 1.21749e+22";
locked = "true";
};
};
new SimGroup(RandomOrganics) {
new TSStatic() {
position = "352.297 188.881 160.856";
rotation = "0 0 1 136.364";
scale = "1 1 1";
shapeName = "dorg16.dts";
};
new TSStatic() {
position = "380.548 229.443 175.643";
rotation = "0 0 -1 1.71778";
scale = "1 1 1";
shapeName = "dorg17.dts";
};
new TSStatic() {
position = "333.627 257.188 177.605";
rotation = "1 0 0 0";
scale = "1 1 1";
shapeName = "dorg19.dts";
};
new TSStatic() {
position = "567.086 57.3387 137.477";
rotation = "0 0 1 141.521";
scale = "1 1 1";
shapeName = "dorg16.dts";
};
new TSStatic() {
position = "477.072 -72.6936 150.153";
rotation = "0 0 1 132.353";
scale = "1 1 1";
shapeName = "dorg19.dts";
};
new TSStatic() {
position = "488.239 8.63118 159.288";
rotation = "0 0 1 91.1003";
scale = "1 1 1";
shapeName = "dorg18.dts";
};
new TSStatic() {
position = "558.369 176.842 152.425";
rotation = "0 0 1 27.502";
scale = "1 1 1";
shapeName = "dorg16.dts";
};
};
new SimGroup(environment) {
};
};
//--- OBJECT WRITE END ---
//Execute our mission script.
exec("scripts/Training.cs");

File diff suppressed because it is too large Load diff