I love the smell of UnrealEd crashing in the morning. – tarquin

UE3:UTWeap_Avril (UT3)

From Unreal Wiki, The Unreal Engine Documentation Site
Revision as of 07:22, 16 August 2009 by Wormbo (Talk | contribs) (added missing members)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
UT3 Object >> Actor >> Inventory >> Weapon >> GameWeapon >> UTWeapon >> UTWeap_Avril

Contents

Package: 
UTGame
Direct subclass:
UTWeap_Avril_Content

Copyright 1998-2008 Epic Games, Inc. All Rights Reserved.

Properties[edit]

Property group 'Locking'[edit]

LockAcquireTime[edit]

Type: float

How long does the player need to target an actor to lock on to it

Default value: 0.05

LockCheckTime[edit]

Type: float

The frequency with which we will check for a lock

Default value: 0.05

LockRange[edit]

Type: int

How far out should we be considering actors for a lock

Default value: 22000

LockTolerance[edit]

Type: float

Once locked, how long can the player go without painting the object before they lose the lock

Default value: 0.4

Internal variables[edit]

bLockedOnTarget[edit]

Type: bool

When true, this weapon is locked on target

bTargetingLaserActive[edit]

Type: bool

set when holding altfire for targeting laser (can't use normal state system because it can fire simultaneously with primary)

bTargetLockingActive[edit]

Type: bool

If true, weapon will try to lock onto targets

ConsoleLockAim[edit]

Type: float

angle for locking for lock targets when on Console

Default value: 0.992

DeferredReloadTime[edit]

Type: float

If you shortcircut the reload, the time will get deferred until you bring the weapon back up

FireTime[edit]

Type: float

How long the fire sequence takes

Default value: 1.0

LaserEffect[edit]

Type: ParticleSystemComponent

component for the laser effect

LastLockedOnTime[edit]

Type: float

How long since the Lock Target has been valid

LastTargetedProjectilesCheckTime[edit]

Type: float

last time TargetedProjectiles list was updated

LastTargetLockCheckTime[edit]

Type: float

Last time target lock was checked

LastValidTargetTime[edit]

Type: float

When was the last time we had a valid target

LockAcquiredSound[edit]

Type: SoundCue

Sound Effects to play when Locking

LockAim[edit]

Type: float

angle for locking for lock targets

Default value: 0.996

LockedTarget[edit]

Type: Actor

Modifiers: repnotify

What "target" is this weapon locked on to

LockLostSound[edit]

Type: SoundCue


MaxControlledProjectiles[edit]

Type: int

the maximum number of projectiles we're allowed to control simultaneously

Default value: 8

MyRocket[edit]

Type: UTProj_AvrilRocketBase

Modifiers: repnotify

A pointer to the currently controlled rocket

NoAmmoWeaponPutDownAnim[edit]

Type: name

Animation to play when there is no ammo

PendingLockedTarget[edit]

Type: Actor

What "target" is current pending to be locked on to

PendingLockedTargetTime[edit]

Type: float

When did the pending Target become valid

ReloadAnimSpeed[edit]

Type: float

The speed of a deferred reload

ReloadCue[edit]

Type: SoundCue


ReloadSound[edit]

Type: AudioComponent


ReloadTime[edit]

Type: float

How long the reload sequence takes

Default value: 3.0

TargetedProjectiles[edit]

Type: array<UTProjectile>

list of known mines/rockets to affect

TargetingLaserAmbientSound[edit]

Type: SoundCue

laser sounds

TargetingLaserStartSound[edit]

Type: SoundCue

laser sounds

TargetingLaserStopSound[edit]

Type: SoundCue

laser sounds

WeaponReloadAnim[edit]

Type: name

Anim to play while reloading

Default values[edit]

Property Value
AIRating 0.55
AmmoCount 5
bLeadTarget False
bSplashJump True
bTargetAdhesionEnabled True
bTargetFrictionEnabled True
bWarnIfInLocker True
bZoomedFireMode[1] 1
CrossHairCoordinates
Member Value
U 384.0
CurrentRating 0.55
EquipTime 0.75
FireInterval[0] 4.0
FireInterval[1] 0.0
FireOffset
Member Value
X 16.0
Y 8.0
Z -5.0
GroupWeight 0.6
IconCoordinates
Member Value
U 728.0
UL 145.0
V 427.0
VL 52.0
IconHeight 47
IconWidth 29
IconX 460
IconY 343
InventoryGroup 10
ItemName "Longbow AVRiL"
LockerAmmoCount 5
LockerRotation
Member Value
Pitch 0
Roll -16384
Yaw 0
MaxAmmoCount 15
MaxDesireability 0.7
MaxPitchLag 300.0
MaxYawLag 400.0
MinReloadPct[0] 0.15
MinReloadPct[1] 0.15
MuzzleFlashLightClass Class'UTGame.UTRocketMuzzleFlashLight'
PickupMessage "Longbow AVRiL"
Priority 1.5
PutDownTime 0.45
QuickPickGroup 1
QuickPickWeight 0.9
ShotCost[1] 0
ShouldFireOnRelease[0] 1
TickGroup TG_PostAsyncWork
WeaponColor
Member Value
A 255
B 0
G 0
R 255
WeaponFireTypes[0] EWFT_Projectile
WeaponFireTypes[1] EWFT_None
ZoomedRate 200.0
ZoomedTargetFOV 40.0

Subobjects[edit]

FirstPersonMesh[edit]

Class: UTGame.UTSkeletalMeshComponent

Inherits from: UTWeapon.FirstPersonMesh

No new values.

PickupMesh[edit]

Class: Engine.SkeletalMeshComponent

Inherits from: UTWeapon.PickupMesh

No new values.

Functions[edit]

Native functions[edit]

CanLockOnTo[edit]

native function bool CanLockOnTo (Actor TA)

Given an actor (TA) determine if we can lock on to it. By default only allow locking on to pawns. Some weapons may want to be able to lock on to other actors.

CheckTargetLock[edit]

native function CheckTargetLock ()

The function checks to see if we are locked on a target

UpdateLockTarget[edit]

native function UpdateLockTarget (Actor NewLockTarget)


Events[edit]

AdjustLockTarget[edit]

event AdjustLockTarget (Actor NewLockTarget)

This function is used to adjust the LockTarget.

Called by UpdateLockTarget() only when NewLockTarget is different from LockTarget

Destroyed[edit]

simulated event Destroyed ()

Overrides: UTWeapon.Destroyed

Event called when weapon actor is destroyed

ReplicatedEvent[edit]

simulated event ReplicatedEvent (name VarName)

Overrides: UTWeapon.ReplicatedEvent


SetPosition[edit]

simulated event SetPosition (UTPawn Holder)

Overrides: UTWeapon.SetPosition

This function aligns the gun model in the world

Tick[edit]

simulated event Tick (float DeltaTime)

Overrides: Actor.Tick


Other instance functions[edit]

ActiveRenderOverlays[edit]

simulated function ActiveRenderOverlays (HUD H)

Overrides: UTWeapon.ActiveRenderOverlays

Draw the Avril hud

AttachWeaponTo[edit]

simulated function AttachWeaponTo (SkeletalMeshComponent MeshCpnt, optional name SocketName)

Overrides: UTWeapon.AttachWeaponTo

(Description copied from UTWeapon.AttachWeaponTo)
Attach Weapon Mesh, Weapon MuzzleFlash and Muzzle Flash Dynamic Light to a SkeletalMesh

Parameters:

  • who - is the pawn to attach to

BeginFire[edit]

simulated function BeginFire (byte FireModeNum)

Overrides: Weapon.BeginFire

BeginFire is the point at which the server and client sync up their code path. It's job is to set the weapon in to the firing state. Network: LocalPlayer and Server

BestMode[edit]

function byte BestMode ()

Overrides: UTWeapon.BestMode

BestMode() choose between regular or alt-fire

CanThrow[edit]

simulated function bool CanThrow ()

Overrides: UTWeapon.CanThrow

Returns true if this item can be thrown out.

CheckLockZoom[edit]

simulated function CheckLockZoom ()

called when locked target changes, check if we should start or stop the zooming due to the target change

CheckZoom[edit]

simulated function bool CheckZoom (byte FireModeNum)

Overrides: UTWeapon.CheckZoom

(Description copied from UTWeapon.CheckZoom)
We Override beginfire to add support for zooming. Should only be called from BeginFire()

Parameters:

  • FireModeNum - The current Firing Mode

Returns:

true we should abort the BeginFire call

EndFire[edit]

simulated function EndFire (byte FireModeNum)

Overrides: UTWeapon.EndFire

We Override endfire to add support for zooming

FastReload[edit]

simulated function FastReload ()


FindTargetedProjectiles[edit]

function FindTargetedProjectiles (Object.Vector TargetLocation, out array<UTSpiderMineTrapTraps)

called on a timer to fill the list of projectiles affected by the targeting laser

GetAIRating[edit]

function float GetAIRating ()

Overrides: Weapon.GetAIRating

AI interface

GetEquipTime[edit]

simulated function float GetEquipTime ()

Overrides: UTWeapon.GetEquipTime


GetWeaponDebug[edit]

simulated function GetWeaponDebug (out array<stringDebugInfo)

Overrides: Weapon.GetWeaponDebug

Retrieves important weapon debug information as an array of strings. That can then be dumped or displayed on HUD.

PassThroughDamage[edit]

simulated function bool PassThroughDamage (Actor HitActor)

Overrides: Weapon.PassThroughDamage

returns true if should pass trace through this hitactor

PlayFireEffects[edit]

simulated function PlayFireEffects (byte FireModeNum, optional Object.Vector HitLocation)

Overrides: UTWeapon.PlayFireEffects

PlayFireEffects Is the root function that handles all of the effects associated with a weapon. This function creates the 1st person effects. It should only be called on a locally controlled player.

PlayReloadAnim[edit]

simulated function PlayReloadAnim (optional float ReloadOverrideTime)


PlayWeaponEquip[edit]

simulated function PlayWeaponEquip ()

Overrides: UTWeapon.PlayWeaponEquip

Show the weapon begin equipped

PlayWeaponPutDown[edit]

simulated function PlayWeaponPutDown ()

Overrides: UTWeapon.PlayWeaponPutDown

Show the weapon being put away

ProjectileFire[edit]

simulated function Projectile ProjectileFire ()

Overrides: UTWeapon.ProjectileFire

Fires a projectile. Spawns the projectile, but also increment the flash count for remote client effects. Network: Local Player and Server

PutDownWeapon[edit]

simulated function PutDownWeapon ()

Overrides: Weapon.PutDownWeapon

This function is called to put a weapon down

RecommendRangedAttack[edit]

function bool RecommendRangedAttack ()

Overrides: Weapon.RecommendRangedAttack


RelativeStrengthVersus[edit]

function float RelativeStrengthVersus (Pawn P, float Dist)

Overrides: Weapon.RelativeStrengthVersus


RocketDestroyed[edit]

function RocketDestroyed (UTProj_AvrilRocketBase Rocket)


SetRocketTarget[edit]

function SetRocketTarget ()


SuggestAttackStyle[edit]

function float SuggestAttackStyle ()

Overrides: Weapon.SuggestAttackStyle


SuggestDefenseStyle[edit]

function float SuggestDefenseStyle ()

Overrides: Weapon.SuggestDefenseStyle


TryPutDown[edit]

simulated function bool TryPutDown ()

Overrides: UTWeapon.TryPutDown

We override TryPutDown so that we can store the deferred amount of time.

UpdateTargetingLaser[edit]

simulated function UpdateTargetingLaser ()

updates the location for the targeting laser and notifies any spider mines or AVRiL rockets in the vacinity

WeaponCalcCamera[edit]

simulated function WeaponCalcCamera (float fDeltaTime, out Object.Vector out_CamLoc, out Object.Rotator out_CamRot)

Overrides: Weapon.WeaponCalcCamera

WeaponCalcCamera allows a weapon to adjust the pawn's controller's camera. Should be subclassed

WeaponEmpty[edit]

simulated function WeaponEmpty ()

Overrides: UTWeapon.WeaponEmpty

Called when the weapon runs out of ammo during firing

States[edit]

Active[edit]

Active.ShouldLagRot[edit]

simulated function bool ShouldLagRot ()

Overrides: UTWeapon.Active.ShouldLagRot

(Description copied from UTWeapon.ShouldLagRot)


Returns:

whether the weapon's rotation is allowed to lag behind the holder's rotation

Inactive[edit]

state Inactive This state is the default state. It needs to make sure Zooming is reset when entering/leaving

Inherits from: UTWeapon.Inactive

Modifiers: auto, simulated

Inactive.BeginState[edit]

simulated event BeginState (name PreviousStateName)

Overrides: UTWeapon.Inactive.BeginState

Clear out the PendingFires

Inactive.EndState[edit]

simulated event EndState (name NextStateName)

Overrides: UTWeapon.Inactive.EndState

Called immediately before going out of the current state, while within the GotoState() call that caused the state change, and before BeginState() is called within the new state.

WeaponEquipping[edit]

State WeaponEquipping The Weapon is in this state while transitioning from Inactive to Active state. Typically, the weapon will remain in this state while its selection animation is being played. While in this state, the weapon cannot be fired.

Inherits from: UTWeapon.WeaponEquipping

Modifiers: simulated

WeaponEquipping.TryPutDown[edit]

simulated function bool TryPutDown ()

Overrides: UTWeapon.WeaponEquipping.TryPutDown

When attempting to put the weapon down, look to see if our MinReloadPct has been met. If so just put it down

WeaponFiring[edit]

Inherits from: UTWeapon.WeaponFiring

Modifiers: simulated

WeaponFiring.EndState[edit]

simulated event EndState (name NextStateName)

Overrides: UTWeapon.WeaponFiring.EndState

Called immediately before going out of the current state, while within the GotoState() call that caused the state change, and before BeginState() is called within the new state.

WeaponFiring.CanThrow[edit]

simulated function bool CanThrow ()

Overrides: CanThrow (global)

Returns true if this item can be thrown out.

WeaponFiring.RefireCheckTimer[edit]

simulated function RefireCheckTimer ()

Overrides: Weapon.WeaponFiring.RefireCheckTimer

Make sure that aborted weapon switch didn't set deferred reload