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

Engine.InventoryManager

Extends
Actor
Modifiers
native

Core.Object
|   
+-- Engine.Actor
   |   
   +-- Engine.InventoryManager

Direct Known Subclasses:

UTInventoryManager

Constants Summary
Inherited Contants from Engine.Actor
ACTORMAXSTEPHEIGHT, MINFLOORZ, RBSTATE_ANGVELSCALE, RBSTATE_LINVELSCALE, RB_NeedsUpdate, RB_None, RB_Sleeping, REP_RBLOCATION_ERROR_TOLERANCE_SQ, TRACEFLAG_Blocking, TRACEFLAG_Bullet, TRACEFLAG_PhysicsVolumes, TRACEFLAG_SkipMovers
Inherited Contants from Core.Object
DegToRad, INDEX_NONE, MaxInt, Pi, RadToDeg

Variables Summary
boolbMustHoldWeapon
InventoryInventoryChain
WeaponLastAttemptedSwitchToWeapon
Array<int>PendingFire
WeaponPendingWeapon
Inherited Variables from Engine.Actor
Acceleration, AllComponents, Attached, bAlwaysEncroachCheck, bAlwaysRelevant, bAlwaysTick, Base, BaseBoneName, BaseSkelComponent, bBlockActors, bBlocksNavigation, bBlocksTeleport, bBounce, bCanBeAdheredTo, bCanBeDamaged, bCanBeFrictionedTo, bCanTeleport, bClientDemoRecording, bCollideActors, bCollideComplex, bCollideWhenPlacing, bCollideWorld, bComponentOutsideWorld, bConsiderAllStaticMeshComponentsForStreaming, bDebug, bDeleteMe, bDemoOwner, bDemoRecording, bDestroyedByInterpActor, bDestroyInPainVolume, bEdShouldSnap, bExchangedRoles, bForceNetUpdate, bGameRelevant, bHardAttach, bHasAlternateTargetLocation, bHidden, bHiddenEd, bHiddenEdCustom, bHiddenEdGroup, bHurtEntry, bIgnoreBaseRotation, bIgnoreEncroachers, bIgnoreRigidBodyPawns, bIsMoving, bJustTeleported, bKillDuringLevelTransition, bLockLocation, BlockRigidBody, bMovable, bNetDirty, bNetInitial, bNetInitialRotation, bNetOwner, bNetTemporary, bNeverReplicateRotation, bNoDelete, bNoEncroachCheck, bOnlyDirtyReplication, bOnlyOwnerSee, bOnlyRelevantToOwner, bOrientOnSlope, bPathColliding, bPathTemp, bPendingDelete, bPendingNetUpdate, bPhysRigidBodyOutOfWorldCheck, bPostRenderIfNotVisible, bProjTarget, bPushedByEncroachers, bRepClientDemo, bReplicateInstigator, bReplicateMovement, bReplicateRigidBodyLocation, bRouteBeginPlayEvenIfStatic, bScriptInitialized, bShadowParented, bShouldBaseAtStartup, bSkipActorPropertyReplication, bStasis, bStatic, bTearOff, bTempEditor, bTicked, bUpdateSimulatedPosition, bWorldGeometry, Children, CollisionComponent, CollisionType, Components, CreationTime, CustomTimeDilation, DesiredRotation, DetachFence, DrawScale, DrawScale3D, GeneratedEvents, Group, InitialState, Instigator, LastNetUpdateTime, LastRenderTime, LatentActions, LatentFloat, LatentSeqNode, LifeSpan, Location, MessageClass, MinDistForNetRBCorrection, NetPriority, NetTag, NetUpdateFrequency, NetUpdateTime, OverlapTag, Owner, PendingTouch, Physics, PhysicsVolume, PrePivot, RelativeLocation, RelativeRotation, RemoteRole, Role, Rotation, RotationRate, SupportedEvents, Tag, TickGroup, Timers, Touching, Velocity, WorldInfo
Inherited Variables from Core.Object
Class, HashNext, HashOuterNext, Linker, LinkerIndex, Name, NetIndex, ObjectArchetype, ObjectFlags, ObjectInternalInteger, Outer, StateFrame, VfTableObject

Enumerations Summary
Inherited Enumerations from Engine.Actor
ECollisionType, EDoubleClickDir, EMoveDir, ENetRole, EPhysics, ETravelType
Inherited Enumerations from Core.Object
EAxis, EInputEvent, EInterpCurveMode, EInterpMethodType, ETickingGroup

Structures Summary
Inherited Structures from Engine.Actor
AnimSlotDesc, AnimSlotInfo, AsyncLineCheckResult, CollisionImpactData, ImpactInfo, NavReference, ReplicatedHitImpulse, RigidBodyContactInfo, RigidBodyState, TimerData, TraceHitInfo
Inherited Structures from Core.Object
Box, BoxSphereBounds, Color, Cylinder, double, DynamicMap_Mirror, Guid, IndirectArray_Mirror, InterpCurveFloat, InterpCurvePointFloat, InterpCurvePointQuat, InterpCurvePointTwoVectors, InterpCurvePointVector, InterpCurvePointVector2D, InterpCurveQuat, InterpCurveTwoVectors, InterpCurveVector, InterpCurveVector2D, IntPoint, LinearColor, Map_Mirror, Matrix, MultiMap_Mirror, Plane, pointer, Quat, qword, RawDistribution, RenderCommandFence, Rotator, TextureMipBulkData_Mirror, ThreadSafeCounter, TPOV, TwoVectors, UntypedBulkData_Mirror, Vector, Vector2D, Vector4

Functions Summary
functionbool AddInventory (Inventory NewItem, optional bool bDoNotActivate))
functionbool CancelWeaponChange ()))
function ChangedWeapon ()))
function ClientSyncWeapon (Weapon NewWeapon))
function ClientWeaponSet (Weapon NewWeapon, bool bOptionalSet))
functionInventory CreateInventory (class<Inventory> NewInventoryItemClass, optional bool bDoNotActivate))
event Destroyed ()))
event DiscardInventory ()))
function DrawHud (HUD H ))
function DumpWeaponStats ()))
eventInventory FindInventoryType (class<Inventory> DesiredClass, optional bool bAllowSubclass))
functionWeapon GetBestWeapon (optional bool bForceADifferentWeapon ))
functionfloat GetWeaponRatingFor (Weapon W ))
functionbool HandlePickupQuery (class<Inventory> ItemClass, Actor Pickup))
function InventoryActors (class<Inventory> BaseClass, out Inventory Inv)
functionbool IsActiveWeapon (Weapon ThisWeapon ))
functionint ModifyDamage (int Damage, Controller instigatedBy, vector HitLocation, vector Momentum, class DamageType ))
function NextWeapon ()))
function OwnerEvent (name EventName))
event PostBeginPlay ()))
function PrevWeapon ()))
function RemoveFromInventory (Inventory ItemToRemove))
function ServerSetCurrentWeapon (Weapon DesiredWeapon))
function SetCurrentWeapon (Weapon DesiredWeapon))
function SetPendingWeapon (Weapon DesiredWeapon))
function SetupFor (Pawn P))
function StartFire (byte FireModeNum))
function StopFire (byte FireModeNum ))
function SwitchToBestWeapon (optional bool bForceADifferentWeapon ))
Inherited Functions from Engine.Actor
ActivateEventClass, AllActors, AllOwnedComponents, Attach, AttachComponent, AutonomousPhysics, BaseChange, BasedActors, BecomeViewTarget, BeginAnimControl, BroadcastLocalizedMessage, BroadcastLocalizedTeamMessage, Bump, CalcCamera, CanSplash, ChartData, CheckForErrors, CheckHitInfo, CheckMaxEffectDistance, ChildActors, ClampRotation, ClearLatentAction, ClearTimer, Clock, CollidingActors, CollisionChanged, ComponentList, ConsoleCommand, ConstraintBrokenNotify, ContainsPoint, CreateAudioComponent, DebugFreezeGame, Destroy, Destroyed, Detach, DetachComponent, DisplayDebug, DoKismetAttachment, DrawDebugBox, DrawDebugCone, DrawDebugCoordinateSystem, DrawDebugCylinder, DrawDebugLine, DrawDebugSphere, DynamicActors, EffectIsRelevant, EncroachedBy, EncroachingOn, EndViewTarget, Falling, FastTrace, FellOutOfWorld, FindActorsOfClass, FindBase, FindEventsOfClass, FindGoodEndView, FindSpot, FinishAnim, FinishAnimControl, FlushPersistentDebugLines, ForceNetRelevant, ForceUpdateComponents, GainedChild, GetActorEyesViewPoint, GetActorFaceFXAsset, GetBaseMost, GetBoundingCylinder, GetComponentsBoundingBox, GetDebugName, GetDestination, GetFaceFXAudioComponent, GetGravityZ, GetHumanReadableName, GetItemName, GetLocalString, GetLocationStringFor, GetPackageGuid, GetPhysicsName, GetTargetLocation, GetTeamNum, GetTerminalVelocity, GetTimerCount, GetTimerRate, GetURLMap, GetUTFlag, HealDamage, HitWall, HurtRadius, InterpolationChanged, InterpolationFinished, InterpolationStarted, IsActorPlayingFaceFXAnim, IsBasedOn, IsInPain, IsInVolume, IsOverlapping, IsOwnedBy, IsPlayerOwned, IsStationary, IsTimerActive, KilledBy, Landed, LocalPlayerControllers, LostChild, MakeNoise, MatchStarting, ModifyHearSoundComponent, Move, MoveSmooth, MovingWhichWay, NativePostRenderFor, NotifyLocalPlayerTeamReceived, NotifySkelControlBeyondLimit, OnAnimEnd, OnAnimPlay, OnAttachToActor, OnCauseDamage, OnChangeCollision, OnDestroy, OnHealDamage, OnMakeNoise, OnRanOver, OnSetBlockRigidBody, OnSetPhysics, OnTeleport, OnToggleHidden, OutsideWorldBounds, OverlappingActors, OverRotated, PawnBaseDied, PhysicsVolumeChange, PickedUpBy, PlayActorFaceFXAnim, PlayerCanSeeMe, PlaySound, PlayTeleportEffect, PointCheckComponent, PostBeginPlay, PostInitAnimTree, PostRenderFor, PostTeleport, PostTouch, PreBeginPlay, PreTeleport, RanInto, ReplaceText, ReplicatedEvent, Reset, RigidBodyCollision, RootMotionExtracted, RootMotionModeChanged, ScriptGetTeamNum, SetAnimPosition, SetAnimWeights, SetBase, SetCollision, SetCollisionSize, SetDrawScale, SetDrawScale3D, SetForcedInitialReplicatedProperty, SetGRI, SetHardAttach, SetHidden, SetHUDLocation, SetInitialState, SetLocation, SetMorphWeight, SetNetUpdateTime, SetOnlyOwnerSee, SetOwner, SetPhysics, SetRelativeLocation, SetRelativeRotation, SetRotation, SetSkelControlScale, SetTickGroup, SetTimer, SetZone, ShutDown, Sleep, Spawn, SpawnedByKismet, SpecialHandling, StopActorFaceFXAnim, StopsProjectile, SuggestTossVelocity, TakeDamage, TakeRadiusDamage, Tick, Timer, TimeSince, TornOff, Touch, TouchingActors, Trace, TraceActors, TraceComponent, TriggerEventClass, UnClock, UnTouch, UsedBy, VisibleActors, VisibleCollidingActors
Inherited Functions from Core.Object
!, !=, $, $=, %, &, &&, *, **, *=, +, ++, +=, -, --, -=, / , /=, <, <<, <=, ==, >, >=, >>, >>>, @, @=, Abs, Acos, Asc, Asin, Atan, BeginState, ByteToFloat, Caps, Chr, Clamp, ClampLength, ClampRotAxis, ClassIsChildOf, ClearConfig, ClockwiseFrom, ColorToLinearColor, ContinuedState, Cos, Cross, Disable, Dot, DumpStateStack, DynamicLoadObject, Enable, EndState, Exp, FClamp, FCubicInterp, FindDeltaAngle, FindObject, FInterpEaseIn, FInterpEaseInOut, FInterpEaseOut, FInterpTo, FloatToByte, FMax, FMin, FPctByRange, FRand, GetAngularDegreesFromRadians, GetAngularDistance, GetAngularFromDotDist, GetAxes, GetDotDistance, GetEnum, GetFuncName, GetHeadingAngle, GetNetFuncName, GetPackageName, GetPerObjectConfigSections, GetRangePctByValue, GetRangeValueByPct, GetSpecialValue, GetStateName, GetUnAxes, GotoState, InStr, IsA, IsChildState, IsInState, IsNetScript, IsPendingKill, IsUTracing, IsZero, JoinArray, Left, Len, Lerp, Localize, Locs, Loge, LogInternal, MakeColor, MakeLinearColor, Max, Mid, Min, MirrorVectorByNormal, Normal, Normalize, NormalizeRotAxis, OrthoRotation, ParseStringIntoArray, PathName, PausedState, PointDistToLine, PointDistToPlane, PointInBox, PoppedState, PopState, ProjectOnTo, PushedState, PushState, QuatDot, QuatFindBetween, QuatFromAxisAndAngle, QuatFromRotator, QuatInvert, QuatProduct, QuatRotateVector, QuatSlerp, QuatToRotator, Rand, RandRange, RDiff, Repl, Right, RInterpTo, RLerp, RotRand, Round, RSize, RSmerp, SaveConfig, SClampRotAxis, ScriptTrace, SetSpecialValue, SetUTracing, Sin, Split, Sqrt, Square, StaticClearConfig, StaticSaveConfig, Tan, TimeStamp, ToHex, TransformVectorByRotation, UnwindHeading, vect2d, VInterpTo, VLerp, VRand, VSize, VSize2D, VSizeSq, VSizeSq2D, VSmerp, WarnInternal, ^, ^^, |, ||, ~, ~=


Variables Detail

bMustHoldWeapon Source code

var bool bMustHoldWeapon;
if true, don't allow player to put down weapon without switching to another one

InventoryChain Source code

var Inventory InventoryChain;
First inventory item in inventory linked list

LastAttemptedSwitchToWeapon Source code

var Weapon LastAttemptedSwitchToWeapon;

PendingFire Source code

var Array<int> PendingFire;
Holds the current "Fire" status for both firing modes

PendingWeapon Source code

var Weapon PendingWeapon;
Player will switch to PendingWeapon, once the current weapon has been put down. @fixme laurent -- PendingWeapon should be made protected, because too many bugs result by setting this variable directly. It's only safe to read it, but to change it, SetCurrentWeapon() should be used.


Functions Detail

AddInventory Source code

simulated function bool AddInventory ( Inventory NewItem, optional bool bDoNotActivate) )
Adds an existing inventory item to the list. Returns true to indicate it was added, false if it was already in the list.
@param NewItem Item to add to inventory manager.
@return true if item was added, false otherwise.

CancelWeaponChange Source code

simulated function bool CancelWeaponChange ( ) )
Prevents player from being without a weapon.

ChangedWeapon Source code

simulated function ChangedWeapon ( ) )
ChangedWeapon is called when the current weapon is finished being deactivated

ClientSyncWeapon Source code

reliable client function ClientSyncWeapon ( Weapon NewWeapon) )
If the server detects that the client's weapon is out of sync, it will use this function to realign them. Network: LocalPlayer @Param NewWeapon The weapon the server wishes to force the client to

ClientWeaponSet Source code

simulated function ClientWeaponSet ( Weapon NewWeapon, bool bOptionalSet) )
Weapon just given to a player, check if player should switch to this weapon Network: LocalPlayer Called from Weapon.ClientWeaponSet()

CreateInventory Source code

simulated function Inventory CreateInventory ( class<Inventory> NewInventoryItemClass, optional bool bDoNotActivate) )
Spawns a new Inventory actor of NewInventoryItemClass type, and adds it to the Inventory Manager.
@param NewInventoryItemClass Class of inventory item to spawn and add.
@return Inventory actor, None if couldn't be spawned.

Destroyed Source code

event Destroyed ( ) )
Event called when inventory manager is destroyed, called from Pawn.Destroyed()

DiscardInventory Source code

simulated event DiscardInventory ( ) )
Discard full inventory, generally because the owner died

DrawHud Source code

simulated function DrawHud ( HUD H ) )
Hook called from HUD actor. Gives access to HUD and Canvas
@param H HUD

DumpWeaponStats Source code

exec simulated function DumpWeaponStats ( ) )
Dump debug stats in log of all weapons in inventory.

FindInventoryType Source code

simulated event Inventory FindInventoryType ( class<Inventory> DesiredClass, optional bool bAllowSubclass) )
returns the inventory item of the requested class if it exists in this inventory manager.
@param DesiredClass class of inventory item we're trying to find.
@param bAllowSubclass whether subclasses of the desired class are acceptable
@return Inventory actor if found, None otherwise.

GetBestWeapon Source code

simulated function Weapon GetBestWeapon ( optional bool bForceADifferentWeapon ) )
returns the best weapon for this Pawn in loadout

GetWeaponRatingFor Source code

simulated function float GetWeaponRatingFor ( Weapon W ) )
Returns a weight reflecting the desire to use the given weapon, used for AI and player best weapon selection.
@param Weapon W
@return Weapon rating (range -1.f to 1.f)

HandlePickupQuery Source code

function bool HandlePickupQuery ( class<Inventory> ItemClass, Actor Pickup) )
Handle Pickup. Can Pawn pickup this item?
@param ItemClass Class of Inventory our Owner is trying to pick up
@param Pickup the Actor containing that item (this may be a PickupFactory or it may be a DroppedPickup)
@return whether or not the Pickup actor should give its item to Other

InventoryActors Source code

native final iterator function InventoryActors ( class<Inventory> BaseClass, out Inventory Inv )
returns all Inventory Actors of class BaseClass
@param BaseClass Inventory actors returned are of, or childs of, this base class.
@output Inv Inventory actors returned.
@note this iterator bails if it encounters more than 100 items, since temporary loops in linked list may sometimes be created on network clients while link pointers are being replicated. For performance reasons you shouldn't have that many inventory items anyway.

IsActiveWeapon Source code

simulated function bool IsActiveWeapon ( Weapon ThisWeapon ) )
returns true if ThisWeapon is the Pawn's active weapon.
@param ThisWeapon weapon to test if it's the Pawn's active weapon.
@return true if ThisWeapon is the Pawn's current weapon

ModifyDamage Source code

function int ModifyDamage ( int Damage, Controller instigatedBy, vector HitLocation, vector Momentum, class<DamageType> DamageType ) )
Damage modifier. Is Pawn carrying items that can modify taken damage? Called from GameInfo.ReduceDamage()

NextWeapon Source code

simulated function NextWeapon ( ) )
Switches to Next weapon Network: Client

OwnerEvent Source code

simulated function OwnerEvent ( name EventName) )
Used to inform inventory when owner event occurs (for example jumping or weapon change)
@param EventName Name of event to forward to inventory items.

PostBeginPlay Source code

event PostBeginPlay ( ) )

PrevWeapon Source code

simulated function PrevWeapon ( ) )
Switches to Previous weapon Network: Client

RemoveFromInventory Source code

simulated function RemoveFromInventory ( Inventory ItemToRemove) )
Attempts to remove an item from the inventory list if it exists.
@param Item Item to remove from inventory

ServerSetCurrentWeapon Source code

reliable server function ServerSetCurrentWeapon ( Weapon DesiredWeapon) )
ServerSetCurrentWeapon begins the Putdown sequence on the server. This function makes the assumption that if TryPutDown succeeded on the client, it will succeed on the server. This function shouldn't be called from anywhere except SetCurrentWeapon Network: Dedicated Server

SetCurrentWeapon Source code

reliable client function SetCurrentWeapon ( Weapon DesiredWeapon) )
Set DesiredWeapon as Current (Active) Weapon. Network: LocalPlayer
@param DesiredWeapon, Desired weapon to assign to player

SetPendingWeapon Source code

simulated function SetPendingWeapon ( Weapon DesiredWeapon) )
Set the pending weapon for switching. This shouldn't be called outside of SetCurrentWeapon()

SetupFor Source code

function SetupFor ( Pawn P) )
Setup Inventory for Pawn P. Override this to change inventory assignment (from a pawn to another) Network: Server only

StartFire Source code

simulated function StartFire ( byte FireModeNum) )
Pawn desires to fire. By default it fires the Active Weapon if it exists. Called from PlayerController::StartFire() -> Pawn::StartFire() Network: Local Player
@param FireModeNum Fire mode number.

StopFire Source code

simulated function StopFire ( byte FireModeNum ) )
Pawn stops firing. i.e. player releases fire button, this may not stop weapon firing right away. (for example press button once for a burst fire) Network: Local Player
@param FireModeNum Fire mode number.

SwitchToBestWeapon Source code

simulated function SwitchToBestWeapon ( optional bool bForceADifferentWeapon ) )
Switch to best weapon available in loadout Network: LocalPlayer


Defaultproperties

defaultproperties
{
   RemoteRole=ROLE_SimulatedProxy
   TickGroup=TG_DuringAsyncWork
   bHidden=True
   bOnlyRelevantToOwner=True
   bReplicateInstigator=True
   bReplicateMovement=False
   bOnlyDirtyReplication=True
   NetPriority=1.400000
   CollisionType=COLLIDE_CustomDefault
   Name="Default__InventoryManager"
   ObjectArchetype=Actor'Engine.Default__Actor'
}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Creation time: sk 18-3-2018 10:00:38.526 - Created with UnCodeX