mirror of
https://github.com/ChocoTaco1/TacoServer.git
synced 2026-07-15 16:14:35 +00:00
Added Tourney check
This commit is contained in:
parent
2dd032d856
commit
219a4e6cca
1 changed files with 12 additions and 8 deletions
|
|
@ -109,9 +109,11 @@ function resetBuyVehicle(%client)
|
||||||
// Info: Delay on calculating flag stats
|
// Info: Delay on calculating flag stats
|
||||||
function ShapeBase::throwObject(%this,%obj)
|
function ShapeBase::throwObject(%this,%obj)
|
||||||
{
|
{
|
||||||
|
//------------------------------------------------------------------
|
||||||
// z0dd - ZOD, 4/15/02. Allow respawn switching during tourney wait.
|
// z0dd - ZOD, 4/15/02. Allow respawn switching during tourney wait.
|
||||||
if(!$MatchStarted)
|
if(!$MatchStarted && $Host::TournamentMode) //Added Tourney check
|
||||||
return;
|
return;
|
||||||
|
//------------------------------------------------------------------
|
||||||
|
|
||||||
// z0dd - ZOD, 5/26/02. Remove anti-hover so flag can be thrown properly
|
// z0dd - ZOD, 5/26/02. Remove anti-hover so flag can be thrown properly
|
||||||
if(%obj.getDataBlock().getName() $= "Flag")
|
if(%obj.getDataBlock().getName() $= "Flag")
|
||||||
|
|
@ -121,9 +123,9 @@ function ShapeBase::throwObject(%this,%obj)
|
||||||
if(Game.Class $= CTFGame || Game.Class $= PracticeCTFGame || Game.Class $= SCtFGame)
|
if(Game.Class $= CTFGame || Game.Class $= PracticeCTFGame || Game.Class $= SCtFGame)
|
||||||
%obj.searchSchedule = Game.schedule(10, "startFlagCollisionSearch", %obj);
|
%obj.searchSchedule = Game.schedule(10, "startFlagCollisionSearch", %obj);
|
||||||
}
|
}
|
||||||
|
//------------------------------------------------------------------
|
||||||
%srcCorpse = (%this.getState() $= "Dead"); // z0dd - ZOD, 4/14/02. Flag tossed from corpse
|
|
||||||
|
|
||||||
|
%srcCorpse = (%this.getState() $= "Dead"); // z0dd - ZOD, 4/14/02. Flag tossed from corpse
|
||||||
//if the object is being thrown by a corpse, use a random vector
|
//if the object is being thrown by a corpse, use a random vector
|
||||||
if (%srcCorpse && %obj.getDataBlock().getName() !$= "Flag") // z0dd - ZOD, 4/14/02. Except for flags..
|
if (%srcCorpse && %obj.getDataBlock().getName() !$= "Flag") // z0dd - ZOD, 4/14/02. Except for flags..
|
||||||
{
|
{
|
||||||
|
|
@ -151,14 +153,16 @@ function ShapeBase::throwObject(%this,%obj)
|
||||||
if (%obj.getDataBlock().getName() $= "Flag")
|
if (%obj.getDataBlock().getName() $= "Flag")
|
||||||
{
|
{
|
||||||
%vec = vectorScale(%vec, (%srcCorpse ? 40 : 75)); // z0dd - ZOD, 4/14/02. Throw flag force. Value was 40
|
%vec = vectorScale(%vec, (%srcCorpse ? 40 : 75)); // z0dd - ZOD, 4/14/02. Throw flag force. Value was 40
|
||||||
|
// ------------------------------------------------------------
|
||||||
// z0dd - ZOD, 9/27/02. Delay on grabbing flag after tossing it
|
// z0dd - ZOD, 9/27/02. Delay on grabbing flag after tossing it
|
||||||
%this.flagTossWait = true;
|
%this.flagTossWait = true;
|
||||||
%this.schedule(1000, resetFlagTossWait);
|
%this.schedule(1000, resetFlagTossWait);
|
||||||
|
// ------------------------------------------------------------
|
||||||
|
|
||||||
// Delay on calculating stats
|
// Delay on calculating stats
|
||||||
%this.flagStatsWait = true;
|
%this.flagStatsWait = true;
|
||||||
%this.schedule(5000, resetFlagStatsWait);
|
%this.schedule(5000, resetFlagStatsWait);
|
||||||
|
// ------------------------------------------------------------
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|
@ -167,7 +171,7 @@ function ShapeBase::throwObject(%this,%obj)
|
||||||
%obj.setCollisionTimeout(%this);
|
%obj.setCollisionTimeout(%this);
|
||||||
%data = %obj.getDatablock();
|
%data = %obj.getDatablock();
|
||||||
|
|
||||||
%data.onThrow(%obj, %this);
|
%data.onThrow(%obj,%this);
|
||||||
|
|
||||||
//call the AI hook
|
//call the AI hook
|
||||||
AIThrowObject(%obj);
|
AIThrowObject(%obj);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue