Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames

DeusEx.AugAqualung


00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
//=============================================================================
// AugAqualung.
//=============================================================================
class AugAqualung extends Augmentation;

var float mult, pct;

var float mpAugValue;
var float mpEnergyDrain;

state Active
{
Begin:
    mult = Player.SkillSystem.GetSkillLevelValue(class'SkillSwimming');
    pct = Player.swimTimer / Player.swimDuration;
    Player.UnderWaterTime = LevelValues[CurrentLevel];
    Player.swimDuration = Player.UnderWaterTime * mult;
    Player.swimTimer = Player.swimDuration * pct;

    if (( Level.NetMode != NM_Standalone ) && Player.IsA('Human') )
    {
        mult = Player.SkillSystem.GetSkillLevelValue(class'SkillSwimming');
        Player.WaterSpeed = Human(Player).Default.mpWaterSpeed * 2.0 * mult;
    }
}

function Deactivate()
{
    Super.Deactivate();
    
    mult = Player.SkillSystem.GetSkillLevelValue(class'SkillSwimming');
    pct = Player.swimTimer / Player.swimDuration;
    Player.UnderWaterTime = Player.Default.UnderWaterTime;
    Player.swimDuration = Player.UnderWaterTime * mult;
    Player.swimTimer = Player.swimDuration * pct;

    if (( Level.NetMode != NM_Standalone ) && Player.IsA('Human') )
    {
        mult = Player.SkillSystem.GetSkillLevelValue(class'SkillSwimming');
        Player.WaterSpeed = Human(Player).Default.mpWaterSpeed * mult;
    }
}

simulated function PreBeginPlay()
{
    Super.PreBeginPlay();

    // If this is a netgame, then override defaults
    if ( Level.NetMode != NM_StandAlone )
    {
        LevelValues[3] = mpAugValue;
        EnergyRate = mpEnergyDrain;
    }
}

defaultproperties
{
     mpAugValue=240.000000
     mpEnergyDrain=10.000000
     EnergyRate=10.000000
     Icon=Texture'DeusExUI.UserInterface.AugIconAquaLung'
     smallIcon=Texture'DeusExUI.UserInterface.AugIconAquaLung_Small'
     AugmentationName="Aqualung"
     Description="Soda lime exostructures imbedded in the alveoli of the lungs convert CO2 to O2, extending the time an agent can remain underwater.|n|nTECH ONE: Lung capacity is extended slightly.|n|nTECH TWO: Lung capacity is extended moderately.|n|nTECH THREE: Lung capacity is extended significantly.|n|nTECH FOUR: An agent can stay underwater indefinitely."
     MPInfo="When active, you can stay underwater 12 times as long and swim twice as fast.  Energy Drain: Low"
     LevelValues(0)=30.000000
     LevelValues(1)=60.000000
     LevelValues(2)=120.000000
     LevelValues(3)=240.000000
     AugmentationLocation=LOC_Torso
     MPConflictSlot=9
}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Class file time: Mon 8/11/2021 16:22:52.000 - Creation time: Mon 8/11/2021 16:31:22.570 - Created with UnCodeX