| Home Page | Recent Changes | Preferences

TheHealer/TUTHealerSource

TUTHealer - The Healer Part 1 of 9 - Source Code

//------------------------------------------------------------------------------
// class name : TUTHealer
// class type : base
// description: the Tutorial Healer weapon
// author     : HSDanClark
//------------------------------------------------------------------------------
// TODO       : the TODO field is useful when you want to notate things you
//              think of and don't want to forget before you can get to them.
// 1. Add more comments.
// 2. Other stuff you can think of...
//------------------------------------------------------------------------------
class TUTHealer extends Weapon
    config(TUTUser);

#EXEC OBJ LOAD FILE=InterfaceContent.utx

var(FirstPerson) float NewEffectOffset;

simulated function vector GetEffectStart()
{
    local Vector X,Y,Z;

    if ( Instigator.IsFirstPerson() && (Hand == 0) )
    {
        GetViewAxes(X, Y, Z);
        if ( class'PlayerController'.Default.bSmallWeapons || Level.bClassicView )
            return (Instigator.Location +
                Instigator.CalcDrawOffset(self) +
                SmallEffectOffset.X * X  +
                SmallEffectOffset.Y * Y * Hand -
                NewEffectOffset * Z);
        else
            return (Instigator.Location +
                Instigator.CalcDrawOffset(self) +
                EffectOffset.X * X +
                EffectOffset.Y * Y * Hand +
                EffectOffset.Z * Z);
    }
    return Super.GetEffectStart();
}

simulated function Destroyed()
{
    Super.Destroyed();
}

simulated function bool StartFire(int Mode)
{
    return Super.StartFire(Mode);
}

// AI Interface
// ::TODO:: write the AI Interface!!!
// End AI Interface

function ConsumeAmmo(int mode, float load)
{
    Ammo[mode].UseAmmo(1);
}

simulated function IncrementFlashCount(int mode)
{
    Super.IncrementFlashCount(mode);
}

simulated function bool PutDown()
{
    return Super.PutDown();
}

simulated function BringUp(optional Weapon PrevWeapon)
{
    Super.BringUp(PrevWeapon);
}

defaultproperties
{
    bMatchWeapons=true
    ItemName="Tutorial Healer Gun"
    IconMaterial=Material'InterfaceContent.Hud.SkinA'
    IconCoords=(X1=200,Y1=190,X2=321,Y2=280)

    FireModeClass(0)=TUTHealerFire       // heal beam
    FireModeClass(1)=TUTHealerAltFire    // damage beam
    InventoryGroup=5
    DrawScale=1.0
    Mesh=mesh'Weapons.LinkGun_1st'
    BobDamping=1.575000
    PickupClass=class'TUTHealerPickup'
    EffectOffset=(X=100,Y=25,Z=-3)
    IdleAnimRate=0.03
    PutDownAnim=PutDown
    DisplayFOV=60

    PlayerViewOffset=(X=-2,Y=-2,Z=-3)
    SmallViewOffset=(X=10,Y=4,Z=-9)
    PlayerViewPivot=(Pitch=0,Roll=0,Yaw=500)
    UV2Texture=Material'XGameShaders.WeaponEnvShader'

    AttachmentClass=class'TUTHealerAttachment'
    SelectSound=Sound'WeaponSounds.LinkGun.SwitchToLinkGun'
    SelectForce="SwitchToTUTHealer"

    AIRating=+0.68
    CurrentRating=+0.68

    HudColor=(r=128,g=255,b=128,a=255)
    DefaultPriority=5

    CenteredOffsetY=-12.0
    CenteredYaw=-300
    CenteredRoll=3000
    NewEffectOffset=5.0
}

The Unreal Engine Documentation Site

Wiki Community

Topic Categories

Image Uploads

Random Page

Recent Changes

Offline Wiki

Unreal Engine

Console Commands

Terminology

FAQs

Help Desk

Mapping Topics

Mapping Lessons

UnrealEd Interface

UnrealScript Topics

UnrealScript Lessons

Making Mods

Class Tree

Modeling Topics

Chongqing Page

Log In