Worst-case scenario: the UEd Goblin wipes the map and burns down your house.

UE3:UTWeaponPawn (UDK)

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
UDK Object >> Actor >> Pawn >> Vehicle >> SVehicle >> UTVehicleBase >> UTWeaponPawn
Package: 
UTGame
Direct subclass:
UTClientSideWeaponPawn
This class in other games:
UT3


Properties

MySeatIndex

Type: int

Modifiers: repnotify

An index in to the Seats array of the vehicle housing this WeaponPawn. It is replicated

Default value: -1

MyVehicle

Type: UTVehicle

Modifiers: repnotify

MyVehicle points to the vehicle that houses this WeaponPawn and is replicated

MyVehicleWeapon

Type: UTVehicleWeapon

Modifiers: repnotify

MyVehicleWeapon points to the weapon assoicated with this WeaponPawn and is replcated

Default values

Property Value
BaseEyeHeight 180.0
bCollideActors False
bCollideWorld False
bFollowLookDir True
bIgnoreBaseRotation True
bOnlyRelevantToOwner True
bProjTarget False
bStationary True
bTurnInPlace True
EyeHeight 180.0
InventoryManagerClass Class'UTGame.UTInventoryManager'
Physics PHYS_None
StayUprightConstraintInstance RB_ConstraintInstance'UTGame.Default__UTWeaponPawn:MyStayUprightConstraintInstance'
StayUprightConstraintSetup RB_StayUprightSetup'UTGame.Default__UTWeaponPawn:MyStayUprightSetup'

Subobjects

CollisionCylinder

Class: Engine.CylinderComponent

Inherits from: UTVehicleBase.CollisionCylinder

Property Value
BlockActors False
BlockNonZeroExtent False
BlockZeroExtent False
CollideActors False
CollisionHeight 0.0
CollisionRadius 0.0
ReplacementPrimitive None

MyStayUprightConstraintInstance

Class: Engine.RB_ConstraintInstance

Inherits from: UTVehicleBase.MyStayUprightConstraintInstance

No new values.

MyStayUprightSetup

Class: Engine.RB_StayUprightSetup

Inherits from: UTVehicleBase.MyStayUprightSetup

No new values.

SVehicleMesh

Class: Engine.SkeletalMeshComponent

Inherits from: UTVehicleBase.SVehicleMesh

Property Value
ReplacementPrimitive None

Functions

Native functions

GetTargetLocation

simulated native function Object.Vector GetTargetLocation (optional Actor RequestedBy, optional bool bRequestAlternateLoc) const

Overrides: Vehicle.GetTargetLocation

(Description copied from Vehicle.GetTargetLocation)


Returns:

Figure out who we are targetting.

Events

BaseChange

singular event BaseChange ()

Overrides: Pawn.BaseChange

Event called after actor's base changes.

DriverLeave

event bool DriverLeave (bool bForceLeave)

Overrides: Vehicle.DriverLeave

Called from the Controller when player wants to get out.

HoldGameObject

simulated event HoldGameObject (UTCarriedObject GameObj)

Overrides: UTVehicleBase.HoldGameObject

(Description copied from UTVehicleBase.HoldGameObject)
HoldGameObject() Attach GameObject to mesh.

Parameters:

  • GameObj - Game object to hold

ReplicatedEvent

simulated event ReplicatedEvent (name VarName)

Overrides: Vehicle.ReplicatedEvent

We use NetNotify to signal that critical data has been replicated. when the Vehicle, Weapon and SeatIndex have all arrived, we setup ourself up locally.

Parameters:

  • VarName - Name of the variable replicated

Other instance functions

AddVelocity

function AddVelocity (Object.Vector NewVelocity, Object.Vector HitLocation, class<DamageTypedamageType, optional Actor.TraceHitInfo HitInfo)

Overrides: SVehicle.AddVelocity


AdjustCameraScale

simulated function AdjustCameraScale (bool bIn)

Overrides: Pawn.AdjustCameraScale

moves the camera in or out

Parameters:

  • bIn - If true, we should zoom the camera in

ApplyWeaponEffects

simulated function ApplyWeaponEffects (int OverlayFlags, optional int SeatIndex)

Overrides: UTVehicleBase.ApplyWeaponEffects

applies weapon effects based on the passed in bitfield

AttachDriver

simulated function AttachDriver (Pawn P)

Overrides: Vehicle.AttachDriver

Attach the Driver to the vehicle. If he's visible, find him a place, otherwhise hind him

Parameters:

  • P - the Pawn the attach

CalcCamera

simulated function bool CalcCamera (float fDeltaTime, out Object.Vector out_CamLoc, out Object.Rotator out_CamRot, out float out_FOV)

Overrides: SVehicle.CalcCamera

Caculates the Camera position. WeaponPawn's forward this to their vehicle

Parameters:

  • fDeltatime - How long since the last calculation
  • out_CamLoc - The final camera location (out)
  • out_CamRot - The final camera rotation (out)
  • out_FOV - The final FOV to use (out)

ClearFlashCount

simulated function ClearFlashCount (Weapon Who)

Overrides: Pawn.ClearFlashCount

We need to pass ClearFlashCount calls to the controlling vehicle

ClearFlashLocation

simulated function ClearFlashLocation (Weapon Who)

Overrides: Pawn.ClearFlashLocation

We need to pass ClearFlashLocation calls to the controlling vehicle

Died

function bool Died (Controller Killer, class<DamageTypeDamageType, Object.Vector HitLocation)

Overrides: SVehicle.Died

(Description copied from Pawn.Died)
This pawn has died.

Parameters:

  • Killer - Who killed this pawn
  • DamageType - What killed it
  • HitLocation - Where did the hit occur

Returns:

true if allowed

DisplayDebug

simulated function DisplayDebug (HUD HUD, out float out_YL, out float out_YPos)

Overrides: SVehicle.DisplayDebug

General Debug information

DisplayHud

function DisplayHud (UTHUD Hud, Canvas Canvas, Object.Vector2D HudPOS, optional int SIndex)

Overrides: UTVehicleBase.DisplayHud

Pass HUD Rendering to the Vehicle

DoJump

function bool DoJump (bool bUpdating)

Overrides: Pawn.DoJump


DriverLeft

function DriverLeft ()

Overrides: UTVehicleBase.DriverLeft

Called when the driver leaves the WeaponPawn. We forward it along as a PassengerLeave call to the controlling vehicle.

DropToGround

function DropToGround ()

Overrides: Pawn.DropToGround


FaceRotation

simulated function FaceRotation (Object.Rotator NewRotation, float DeltaTime)

Overrides: Vehicle.FaceRotation

Vehicles ignore 'face rotation'.

GetCollisionRadius

simulated function float GetCollisionRadius ()

Overrides: Pawn.GetCollisionRadius

Returns:

the collision radius. In this case we return that of the vehicle if it exists

GetQuickPickCells

simulated function GetQuickPickCells (UTHUD Hud, out array<UTPawn.QuickPickCellCells, out int CurrentWeaponIndex)

Overrides: UTVehicleBase.GetQuickPickCells


GetVehicleDrivingStatName

function name GetVehicleDrivingStatName ()

Overrides: UTVehicleBase.GetVehicleDrivingStatName

Statistics gathering

IncrementFlashCount

simulated function IncrementFlashCount (Weapon Who, byte FireModeNum)

Overrides: Pawn.IncrementFlashCount

We need to pass IncreantFlashCount calls to the controlling vehicle

JumpOffPawn

function JumpOffPawn ()

Overrides: Pawn.JumpOffPawn


PlaceExitingDriver

function bool PlaceExitingDriver (optional Pawn ExitingDriver)

Overrides: Vehicle.PlaceExitingDriver

Called when the vehicle needs to place an exiting driver. Forward the call to the controlling vehicle

Parameters:

  • ExitingDriver - The pawn that is exiting

PossessedBy

function PossessedBy (Controller C, bool bVehicleTransition)

Overrides: Vehicle.PossessedBy

Called when the controller takes possession of the WeaponPawn. Upon Possession, make sure the weapon heads to the right state and set the eye height.

Parameters:

  • C - the controller taking posession
  • bVehicleTransition - Will be true if this the pawn is entering/leaving a vehicle

ProcessViewRotation

simulated function ProcessViewRotation (float DeltaTime, out Object.Rotator out_ViewRotation, out Object.Rotator out_DeltaRot)

Overrides: Pawn.ProcessViewRotation

(Description copied from Pawn.ProcessViewRotation)
Called from PlayerController UpdateRotation() -> ProcessViewRotation() to (pre)process player ViewRotation adds delta rot (player input), applies any limits and post-processing returns the final ViewRotation set on PlayerController

Parameters:

  • DeltaTime - time since last frame
  • ViewRotation - actual PlayerController view rotation
  • out_DeltaRot - delta rotation to be applied on ViewRotation. Represents player's input.

Returns:

processed ViewRotation to be set on PlayerController.

QuickPick

simulated function QuickPick (int Quad)

Overrides: UTVehicleBase.QuickPick


ServerAdjacentSeat

reliable server function ServerAdjacentSeat (int Direction, Controller C)

Overrides: UTVehicleBase.ServerAdjacentSeat

request change to adjacent vehicle seat

ServerChangeSeat

reliable server function ServerChangeSeat (int RequestedSeat)

Overrides: UTVehicleBase.ServerChangeSeat

(Description copied from UTVehicleBase.ServerChangeSeat)
Called when a client is requesting a seat change

Network: Server-Side

SetBaseEyeheight

simulated function SetBaseEyeheight ()

Overrides: Vehicle.SetBaseEyeheight

Set the Base Eye height. We override it here to pull it from the CameraEyeHeight variable of in the seat array

SetFiringMode

simulated function SetFiringMode (Weapon Weap, byte FiringModeNum)

Overrides: Pawn.SetFiringMode

Set firing mode replication for remote clients trigger update notification. Network: LocalPlayer and Server

SetFlashLocation

simulated function SetFlashLocation (Weapon Who, byte FireModeNum, Object.Vector NewLoc)

Overrides: Pawn.SetFlashLocation

We need to pass SetFlashLocation calls to the controlling vehicle

SetMovementPhysics

function SetMovementPhysics ()

Overrides: Pawn.SetMovementPhysics


TooCloseToAttack

function bool TooCloseToAttack (Actor Other)

Overrides: Pawn.TooCloseToAttack