mirror of
https://github.com/ChocoTaco1/TacoServer.git
synced 2026-01-19 16:14:44 +00:00
LCTF Things
This commit is contained in:
parent
5f323ddb27
commit
bac741baf6
|
|
@ -132,7 +132,7 @@ function LCTFGame::initGameVars(%game)
|
||||||
%game.SCORE_PER_REPAIR_DEP_TUR = 3;
|
%game.SCORE_PER_REPAIR_DEP_TUR = 3;
|
||||||
%game.SCORE_PER_REPAIR_DEP_INV = 2;
|
%game.SCORE_PER_REPAIR_DEP_INV = 2;
|
||||||
|
|
||||||
%game.FLAG_RETURN_DELAY = 45 * 1000;
|
%game.FLAG_RETURN_DELAY = 25 * 1000;
|
||||||
|
|
||||||
%game.TIME_CONSIDERED_FLAGCARRIER_THREAT = 3 * 1000;
|
%game.TIME_CONSIDERED_FLAGCARRIER_THREAT = 3 * 1000;
|
||||||
%game.RADIUS_GEN_DEFENSE = 20;
|
%game.RADIUS_GEN_DEFENSE = 20;
|
||||||
|
|
@ -2521,61 +2521,58 @@ function Player::maxInventory(%this, %data){
|
||||||
|
|
||||||
function LCTFGame::LCTFOneMine(%game, %admin, %arg1, %arg2, %arg3, %arg4)
|
function LCTFGame::LCTFOneMine(%game, %admin, %arg1, %arg2, %arg3, %arg4)
|
||||||
{
|
{
|
||||||
if( $countdownStarted && $MatchStarted )
|
if(%admin)
|
||||||
{
|
{
|
||||||
if(%admin)
|
killeveryone();
|
||||||
{
|
|
||||||
killeveryone();
|
|
||||||
|
|
||||||
if($Host::LCTFOneMine)
|
if($Host::LCTFOneMine)
|
||||||
{
|
{
|
||||||
messageAll('MsgAdminForce', '\c2The Admin has disabled One Mine Inventory.');
|
messageAll('MsgAdminForce', '\c2The Admin has disabled One Mine Inventory.');
|
||||||
|
|
||||||
|
if (isActivePackage(LCTFOneMine))
|
||||||
|
deactivatePackage(LCTFOneMine);
|
||||||
|
|
||||||
|
$Host::LCTFOneMine = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
messageAll('MsgAdminForce', '\c2The Admin has enabled One Mine Inventory.');
|
||||||
|
|
||||||
|
if (!isActivePackage(LCTFOneMine))
|
||||||
|
activatePackage(LCTFOneMine);
|
||||||
|
|
||||||
|
$Host::LCTFOneMine = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
%totalVotes = %game.totalVotesFor + %game.totalVotesAgainst;
|
||||||
|
if(%totalVotes > 0 && (%game.totalVotesFor / ClientGroup.getCount()) > ($Host::VotePasspercent / 100))
|
||||||
|
{
|
||||||
|
killeveryone();
|
||||||
|
|
||||||
|
if($Host::LCTFOneMine)
|
||||||
|
{
|
||||||
|
messageAll('MsgVotePassed', '\c2One Mine Inventory Disabled.');
|
||||||
|
|
||||||
if (isActivePackage(LCTFOneMine))
|
if (isActivePackage(LCTFOneMine))
|
||||||
deactivatePackage(LCTFOneMine);
|
deactivatePackage(LCTFOneMine);
|
||||||
|
|
||||||
$Host::LCTFOneMine = false;
|
$Host::LCTFOneMine = false;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
messageAll('MsgAdminForce', '\c2The Admin has enabled One Mine Inventory.');
|
messageAll('MsgVotePassed', '\c2One Mine Inventory Enabled.');
|
||||||
|
|
||||||
if (!isActivePackage(LCTFOneMine))
|
if (!isActivePackage(LCTFOneMine))
|
||||||
activatePackage(LCTFOneMine);
|
activatePackage(LCTFOneMine);
|
||||||
|
|
||||||
$Host::LCTFOneMine = true;
|
$Host::LCTFOneMine = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
messageAll('MsgVoteFailed', '\c2Mode change did not pass: %1 percent.', mFloor(%game.totalVotesFor/ClientGroup.getCount() * 100));
|
||||||
%totalVotes = %game.totalVotesFor + %game.totalVotesAgainst;
|
}
|
||||||
if(%totalVotes > 0 && (%game.totalVotesFor / ClientGroup.getCount()) > ($Host::VotePasspercent / 100))
|
|
||||||
{
|
|
||||||
killeveryone();
|
|
||||||
|
|
||||||
if($Host::LCTFOneMine)
|
|
||||||
{
|
|
||||||
messageAll('MsgVotePassed', '\c2One Mine Inventory Disabled.');
|
|
||||||
|
|
||||||
if (isActivePackage(LCTFOneMine))
|
|
||||||
deactivatePackage(LCTFOneMine);
|
|
||||||
|
|
||||||
$Host::LCTFOneMine = false;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
messageAll('MsgVotePassed', '\c2One Mine Inventory Enabled.');
|
|
||||||
|
|
||||||
if (!isActivePackage(LCTFOneMine))
|
|
||||||
activatePackage(LCTFOneMine);
|
|
||||||
|
|
||||||
$Host::LCTFOneMine = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
messageAll('MsgVoteFailed', '\c2Mode change did not pass: %1 percent.', mFloor(%game.totalVotesFor/ClientGroup.getCount() * 100));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// For voting to work properly - evo admin.ovl
|
// For voting to work properly - evo admin.ovl
|
||||||
|
|
|
||||||
|
|
@ -44,7 +44,12 @@ function loadMissionStage2()
|
||||||
|
|
||||||
//Tournament Mode specifics
|
//Tournament Mode specifics
|
||||||
if($Host::TournamentMode)
|
if($Host::TournamentMode)
|
||||||
$Host::TimeLimit = 30; //TimeLimit Always 30 minutes in Tourney Mode
|
{
|
||||||
|
if(!$CurrentMissionType $= "LCTF")
|
||||||
|
$Host::TimeLimit = 30; //TimeLimit Always 30 minutes in Tourney Mode
|
||||||
|
else //LCTF 20 Minutes
|
||||||
|
$Host::TimeLimit = 20; //TimeLimit Always 20 minutes in LCTF Tourney Mode
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//Disable if active
|
//Disable if active
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue