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

Botpack.ThighPads


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
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
//=============================================================================
// ThighPads.
//=============================================================================
class ThighPads extends TournamentPickup;

#exec MESH IMPORT MESH=ThighPads ANIVFILE=MODELS\ThighPads_a.3d DATAFILE=MODELS\ThighPads_d.3d X=0 Y=0 Z=0
#exec MESH ORIGIN MESH=ThighPads X=0 Y=0 Z=0
#exec MESH SEQUENCE MESH=ThighPads SEQ=All                      STARTFRAME=0 NUMFRAMES=1
#exec MESH SEQUENCE MESH=ThighPads SEQ=sit                      STARTFRAME=0 NUMFRAMES=1
#exec MESHMAP NEW   MESHMAP=ThighPads MESH=ThighPads
#exec MESHMAP SCALE MESHMAP=ThighPads X=0.04 Y=0.04 Z=0.08
#exec TEXTURE IMPORT NAME=JThighPads_01 FILE=MODELS\ThighPads1.PCX GROUP=Skins LODSET=2
#exec MESHMAP SETTEXTURE MESHMAP=ThighPads NUM=1 TEXTURE=JThighPads_01
#exec MESHMAP SETTEXTURE MESHMAP=ThighPads NUM=2 TEXTURE=JThighPads_01

function bool HandlePickupQuery( inventory Item )
{
    local inventory S;

    if ( item.class == class ) 
    {
        S = Pawn(Owner).FindInventoryType(class'UT_Shieldbelt');    
        if (  S==None )
        {
            if ( Charge<Item.Charge )   
                Charge = Item.Charge;
        }
        else
            Charge = Clamp(S.Default.Charge - S.Charge, Charge, Item.Charge );
        if (Level.Game.LocalLog != None)
            Level.Game.LocalLog.LogPickup(Item, Pawn(Owner));
        if (Level.Game.WorldLog != None)
            Level.Game.WorldLog.LogPickup(Item, Pawn(Owner));
        if ( PickupMessageClass == None )
            Pawn(Owner).ClientMessage(PickupMessage, 'Pickup');
        else
            Pawn(Owner).ReceiveLocalizedMessage( PickupMessageClass, 0, None, None, Self.Class );
        Item.PlaySound (PickupSound,,2.0);
        Item.SetReSpawn();
        return true;                
    }
    if ( Inventory == None )
        return false;

    return Inventory.HandlePickupQuery(Item);
}

function inventory SpawnCopy( pawn Other )
{
    local inventory Copy, S;

    Copy = Super.SpawnCopy(Other);
    S = Other.FindInventoryType(class'UT_Shieldbelt');  
    if ( S != None )
    {
        Copy.Charge = Min(Copy.Charge, S.Default.Charge - S.Charge);
        if ( Copy.Charge <= 0 )
        { 
            S.Charge -= 1;
            Copy.Charge = 1;
        }
    }
    return Copy;
}

defaultproperties
{
     bDisplayableInv=True
     bRotatingPickup=True
     PickupMessage="You got the Thigh Pads."
     ItemName="Thigh Pads"
     RespawnTime=30.000000
     PickupViewMesh=LodMesh'Botpack.ThighPads'
     Charge=50
     ArmorAbsorption=50
     bIsAnArmor=True
     AbsorptionPriority=7
     MaxDesireability=1.800000
     PickupSound=Sound'Botpack.Pickups.ArmorUT'
     Icon=Texture'UnrealShare.Icons.I_Armor'
     Mesh=LodMesh'Botpack.ThighPads'
     AmbientGlow=64
}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Class file time: Do 19.5.2005 19:42:14.000 - Creation time: Fr 7.6.2013 13:16:05.133 - Created with UnCodeX