Fixed Some Mistakes

This commit is contained in:
Robert Fritzen 2014-08-02 17:29:12 -05:00
parent f226c40a54
commit 9cfcf412db
6 changed files with 28 additions and 18 deletions

View file

@ -322,10 +322,9 @@ function GameConnection::AwardKillstreak(%client, %streakVal, %plz) {
if(!%client.isActiveStreak(%streakVal) && ($Killstreak::Setting != 2) && !$TWM::PlayingHelljump) { if(!%client.isActiveStreak(%streakVal) && ($Killstreak::Setting != 2) && !$TWM::PlayingHelljump) {
return; return;
} }
if(!%client.ksListInstance) { if(!isSet(%client.ksListInstance)) {
%client.ksListInstance = initList(); %client.ksListInstance = initList();
} }
%client.player.setInventory(KillstreakBeacon, 1, true);
%cAmt = 0; %cAmt = 0;
switch(%streakVal) { switch(%streakVal) {
case 1: case 1:
@ -443,6 +442,7 @@ function GameConnection::AwardKillstreak(%client, %streakVal, %plz) {
} }
} }
} }
%client.player.setInventory(KillstreakBeacon, 1, true);
} }
//Modified 12-17-09 to take into consideration of hosts changing the kill values //Modified 12-17-09 to take into consideration of hosts changing the kill values

View file

@ -103,11 +103,11 @@ datablock ShapeBaseImageData(EditGunImage) {
function EditGunImage::onMount(%this, %obj, %slot) { function EditGunImage::onMount(%this, %obj, %slot) {
Parent::onMount(%this, %obj, %slot); Parent::onMount(%this, %obj, %slot);
DispEditorToolInfo(%obj); DispEditorToolInfo(%obj);
if(!isSet(%obj.EditPMode)) { if(!isSet(%obj.client.EditPMode)) {
%obj.EditPMode = 0; %obj.client.EditPMode = 0;
} }
if(!isSet(%obj.EditSMode)) { if(!isSet(%obj.client.EditSMode)) {
%obj.EditSMode = 0; %obj.client.EditSMode = 0;
} }
//Phantom139: Added //Phantom139: Added
%obj.hasMineModes = 1; %obj.hasMineModes = 1;

View file

@ -221,10 +221,10 @@ function ConstructionToolImage::onMount(%this,%obj,%slot) {
%obj.errMsgSent = false; %obj.errMsgSent = false;
%obj.client.setWeaponsHudActive(%this.item); %obj.client.setWeaponsHudActive(%this.item);
%obj.usingConstructionTool = true; %obj.usingConstructionTool = true;
if (!%obj.constructionToolMode) if (!isSet(%obj.client.constructionToolMode))
%obj.constructionToolMode = 0; %obj.client.constructionToolMode = 0;
if (!%obj.constructionToolMode2) if (!isSet(%obj.client.constructionToolMode2))
%obj.constructionToolMode2 = 0; %obj.client.constructionToolMode2 = 0;
//Phantom139: Added //Phantom139: Added
%obj.hasMineModes = 1; %obj.hasMineModes = 1;
%obj.hasGrenadeModes = 1; %obj.hasGrenadeModes = 1;

View file

@ -545,10 +545,10 @@ function MergeToolImage::onFire(%data,%obj,%slot)
function MergeToolImage::onMount(%this,%obj,%slot) function MergeToolImage::onMount(%this,%obj,%slot)
{ {
if(%obj.MTMode $= "") if(%obj.client.MTMode $= "")
%obj.MTMode = 0; %obj.client.MTMode = 0;
if(%obj.MTSubMode $= "") if(%obj.client.MTSubMode $= "")
%obj.MTSubMode = 0; %obj.client.MTSubMode = 0;
%obj.usingMTelec = 1; %obj.usingMTelec = 1;
//Phantom139: Added //Phantom139: Added
%obj.hasMineModes = 1; %obj.hasMineModes = 1;

View file

@ -210,10 +210,10 @@ function SuperChaingunImage::onFire(%data,%obj,%slot) {
function SuperChaingunImage::onMount(%this,%obj,%slot) { function SuperChaingunImage::onMount(%this,%obj,%slot) {
%obj.usingSuperChaingun = true; %obj.usingSuperChaingun = true;
if (!%obj.superChaingunMode) if (!%obj.client.superChaingunMode)
%obj.superChaingunMode = 0; %obj.client.superChaingunMode = 0;
if (!%obj.superChaingunMode2) if (!%obj.client.superChaingunMode2)
%obj.superChaingunMode2 = 0; %obj.client.superChaingunMode2 = 0;
%obj.hasMineModes = 1; %obj.hasMineModes = 1;
%obj.hasGrenadeModes = 1; %obj.hasGrenadeModes = 1;
displayWeaponInfo(%this, %obj, %obj.client.superChaingunMode, %obj.client.superChaingunMode2); displayWeaponInfo(%this, %obj, %obj.client.superChaingunMode, %obj.client.superChaingunMode2);
@ -238,6 +238,8 @@ function SuperChaingunImage::changeMode(%this, %obj, %key) {
case 2: case 2:
//Grenade Modes //Grenade Modes
%obj.client.superChaingunMode2++; %obj.client.superChaingunMode2++;
if(%obj.client.superChaingunMode != 1)
%obj.client.superChaingunMode2 = 0;
if (%obj.client.superChaingunMode == 1 && %obj.client.superChaingunMode2 == 2) if (%obj.client.superChaingunMode == 1 && %obj.client.superChaingunMode2 == 2)
%obj.client.superChaingunMode2 = 0; %obj.client.superChaingunMode2 = 0;
} }

View file

@ -73,6 +73,14 @@ datablock ShapeBaseImageData(KillstreakBeaconImage) {
}; };
function KillstreakBeaconImage::onMount(%this, %obj, %slot) { function KillstreakBeaconImage::onMount(%this, %obj, %slot) {
if(!isSet(%obj.client.ksListInstance)) {
%obj.client.ksListInstance = initList();
}
if(%obj.client.ksListInstance.count() <= 0) {
%obj.throwWeapon(1);
%obj.throwWeapon(0);
%obj.setInventory(KillstreakBeacon, 0, true);
}
Parent::onMount(%this, %obj, %slot); Parent::onMount(%this, %obj, %slot);
%obj.hasMineModes = 1; %obj.hasMineModes = 1;
%obj.hasGrenadeModes = 1; %obj.hasGrenadeModes = 1;