My program doesn't have bugs. It just develops random features.

Legacy:WeaponLocker

From Unreal Wiki, The Unreal Engine Documentation Site
Revision as of 22:29, 17 December 2005 by SuperApe (Talk) (Created.)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
UT2004 :: Actor >> Pickup >> WeaponLocker (Package: XWeapons)

The WeaponLocker is a mutli-pickup base for weapons. Extra ammo is available for each weapon as well.

Struct[edit]

WeaponEntry[edit]

Both these properties are available for editing.

class<Weapon> WeaponClass 
The weapon class available for pickup.
int ExtraAmmo 
Amount of extra ammo for this weapon.

PawnToucher[edit]

Both these properties are hidden.

Pawn
The Pawn attempting to get the weapons.
float NextTouchTime 
The next time in Level.Seconds the Pawn can pickup weapons.

Properties[edit]

Main[edit]

bool bSentinelProtected 
Protected by an ASVehicle_Sentinel Pawn.
array<WeaponEntry> Weapons 
The weapons this lockers has available.

Hidden[edit]

string LockerString (localized) 
FX_WeaponLocker Effect 
array<PawnToucher> Customers 
The Pawn customers that have visited this WeaponLocker.

Functions[edit]

bool AddCustomer( Pawn P ) 
bool HasCustomer( Pawn P ) 
PostNetBeginPlay() (simulated) 
Calls Super.PostNetBeginPlay(). Sets MaxDesireability = 0. If bHidden, returns. Sets MaxDesireability higher for each WeaponClass.Default.AIRating is has. Calls SpawnLockerWeapon(). If Level.NetMode != NM_DedicatedServer, calls Effect = Spawn(class'FX_WeaponLocker', Self,, Location, Rotation ).
Destroyed() (simulated) 
Destroys Effect before calling Super.Destroyed().
UpdateHUD( HUD H ) (simulated, static) 
Sets H.LastPickupTime = H.Level.TimeSeconds and H.LastWeaponPickupTime = H.LastPickupTime.
Reset() 
EMPTY
SpawnLockerWeapon() (simulated) 
Spawns the Weapon Meshes from a Mesh Emitter.
string GetHumanReadableName() (simulated) 
Returns LockerString.
float BotDesireability( Pawn Bot) 
Tell the bot how much it wants this weapon pickup. Called when the bot is trying to decide which inventory pickup to go after next.
float DetourWeight( Pawn Other, float PathWeight ) 
Value of this path to take a quick detour. (usually 0, used when on route to distant objective, but want to grab inventory for example)
UpdatePrecacheMaterials() (simulated) 

States[edit]

LockerPickup (auto)[edit]

Functions[edit]

bool ReadyToPickup( float MaxWait ) 
Returns true.
bool ValidTouch( Actor Other ) (simulated) 
Validate touch (if valid return true to let other pick me up and trigger event).
Touch( Actor Other ) (simulated) 
If touched by a player pawn, let him pick this up.

Disabled[edit]

Functions[edit]

BeginState() (simulated) 
Destroys all LockerWeapon class actors. Destroys Effect.

Related Topics[edit]

Discussion[edit]

SuperApe: Created.