| Home Page | Recent Changes | Preferences

EnhancedItems/EnhancedWeapon

UT :: Actor (UT) >> Inventory (UT) >> Weapon (UT) >> TournamentWeapon >> EnhancedWeapon (Package: EnhancedItems)

This class is part of the EnhancedItems package by Wormbo.

Don't use the DeathMessage variable. For projectile weapons use /EnhancedProjectiles and their death messages and for instant-hit weapons use the new hit strings.

Properties

Globalconfig Properties

bool bDropEffects
Whether the weapon should drop some visual effects to increase game performance.

Localized Properties

string DoubleName
Displayed name of the weapon when dual-wielded.
string MenuName
Name of this weapon displayed in the weapon priority menu. (only in the Advanced Weapon Priority menu and in the Arena Match config window)
string ProjectileName
This weapon's projectile name. (used in death messages)

The following properties are death messages and you can use these placeholders in them:

%k Killing player's name
%o Other (killed) player's name
%w Weapon used to make the kill (not the weapon held while making the kill!)
%p Name of the projectile used
string DirectHitString
Death message for kills via direct hits.
string HeadHitString
Death message for headshots (if the projectile can cause headshots, see next section).
string HeadSuicideFString
Suicide message for female models for self-headshots.
string HeadSuicideString
Suicide message for male models for self-headshots.
string SplashHitString
Death message for kills via splash damage.
string SuicideFString
Suicide message for female models for suicides via direct hit or splash damage.
string SuicideString
Suicide message for male models for suicides via direct hit or splash damage.

Other Properties

bool bCanHeadShoot
Whether this weapon behaves differently (different damage and/or death message) when it hits a player's head.
bool bConstantSplashDamage
Whether the weapon's explosion splash damage is the same in the whole splash area. Keep this set to False if the damage should fall off linearly with the distance to the impact location.
bool bCustomDrawSlave
The class whats to handle drawing the slave weapon (when dual-wielded) itself.
float Damage
Damage done by this instant-hit weapon.
float DamageRadius
Splash damage range of this instant-hit weapon.
class<Actor (UT)> DeathMessageActorClass
When set to an EnhancedWeapon or /EnhancedProjectile class, that class' death messages are used instead of this one's.
name DoublePriorityName
The priority name this weapon uses in dual mode.
class<Decal> ExplosionDecal
A decal spawned at the hit location.
class<Effects (UT)> ExplosionEffectClass
This effect is spawned when the projectile explodes.
name HeadDamageType
Name of the damage type to use for headshots. Use 'Decapitated' to let UT display its "Headshot!" announcement for the killer.
float HeadShotDamageFactor
The damage done by a headshot is the weapon's Damage multiplied by HeadShotDamageFactor.
float HeadShotHeight
This defines the height, over which hits are counted as headshots. 0 means the center of the player's collision cylinder, 1 is the top, -1 is the bottom. The value used for UT's sniper rifle is 0.62, which also is the default value here.
class<LocalMessage (UT)> HeadShotMessage
Custom LocalMessage (UT) displayed to both the killer and the victim after a headshot. The LocalMessage class should react to the following switches:
  • Message is displayed to the killer
  • Message is displayed to the victim
  • Message is displayed to the player after a headshot suicide :D
Mods using the EnhancedItems package don't neccessarily need to make a difference here. E.g. both the EnhancedItems Ripper and the Rockets UT Mercury Missiles just use UT's headshot announcement and display it to killer and victim. (This includes Ripper self-headshots. ;))
name IdenticalTo
Used by the OtherIsA() and ClassIsA() functions in various EnhancedItems base classes to identify an actor or class as being similar to this one. For example, the ERelicDeathInventory class (the Relic of Death pickup of the Enhanced Relics mutator) has IdenticalTo=RelicDeathInventory. This will cause OtherIsA(aPickup, 'RelicDeathInventory') to rturn True not only for actual subclasses of RelicDeathInventory, but also for the ERelicDeathInventory and any other EnhancedItems-based classes that have IdenticalTo=RelicDeathInventory in their default properties.
float MaxRange
The maximum range of this instant-hit weapon.
Mesh MenuMesh
rotator MenuRotation
float MenuViewScale
float MomentumModifier
How the instigator's DamageScaling affects the momentum applied by this projectile's explosion.
= 0 no effect
> 0 Momentum becomes higher with a higher DamageScaling value.
< 0 Momentum is reduced with a higher DamageScaling value.</wiki>
float MomentumTransfer
Momentum to apply to directly hit actors.
float Range
Range of a melee weapon.
name SamePriorityLike
This weapon uses the specified weapon class' priority instead of its own.
name SplashDamageType
Damage type to use for splash damage.
float SplashMomentum
Momentum aplied by splash damage.
float SplashRangeModifier
How the splash range is affected by the instigator's damage scaling. This works the same way as MomentumModifier.
class<Projectile (UT)> SubMunitionClass
What type of projectiles should be spawned when this projectile explodes.
int SubMunitionCount
How many sub-projectiles should be spawned.

Internal

bool bDrawingWeapon
Whether the weapon is currently being drawn.
bool bIsSlave (replicated to owning client)
Whether this is the slave weapon in dual mode.
int DoubleSwitchPriority
The priority this weapon is assigned in dual mode.
EIDeathMessageMutator EIDMM
The EIDeathMessageMutator is spawned by EnhancedWeapons to make the EnhancedItems death messages work.
EnhancedWeapon SlaveWeapon (replicated to owning client)
A reference to the slave weapon in dual mode.
float SpeedScale (replicated to owning client)
Used to speed up weapons when under the effect of the Relic of Speed (of Enhanced Relics) or similar powerups.
EnhancedWeapon MasterWeapon (replicated to client if bIsSlave)
A reference to the master weapon in dual mode.

Methods

Inherited From Actor (UT)

PreBeginPlay( )
Finds or spawns the EIDeathMessageMutator.
RenderOverlays(Canvas (UT) Canvas)
Allow HUD mutators and weapon affectors to draw on the canvas right after the weapon has been rendered and before the HUD is drawn.
Note that any number of /PickupPlus? items and one TournamentPickup can affect a TournamentWeapon at the same time but only the /PickupPlus? items are allowed to draw on the canvas.

Inherited From Weapon (UT)

AltFire(float Value)
Fire(float Value)
Basic fire and altfire modes for instant-hit and projectile weapons with support for dual mode.
SetSwitchPriority(Pawn (UT) Other)
If this weapon is replacing another one it might use the same switching priority. Also, if this weapon can have a slave weapon (like Enforcer) it might use a different priority.
float SwitchPriority( )
Return the switch priority of the weapon (normally AutoSwitchPriority, but may be modified by environment (or by other factors for bots).

New Functions

name AdjustSplashDamageType(Actor (UT) Other)
Allowes you to use different damage types for different actors in the slpash area.
vector CalcZoomedFireOffset( )
Returns the fire offset when zoomed.
bool ClassIsA(class aClass, coerce string DesiredType)
Returns, whether a class is of a specific type or identical to that type. (see IdenticalTo property)
DirectHit(vector HitLocation, Actor (UT) Other, optional vector HitNormal, optional bool bSpecialHit)
Damages Other at HitLocation. bSpecialHit tells whether the headshot death mesages of the regular damage type should be used.
vector EstimatedHitNormal(out vector HitLocation, out Actor (UT) HitActor, optional vector CurLocation, optional vector Distance, optional bool bHitLevelOnly, optional vector Extend)
Tries to estimate a projectile's impact location, hit normal and hit actor.
ModifySubMunition(Projectile (UT) Other)
Allowes you to modify each sub-projectile spawned.
OldRenderOverlays(Canvas (UT) C)
Called by this class' RenderOverlays() or PreRenderOverlays() function of an /EnhancedMutator registered as HUD mutator or a /PickupPlus? registered as affector. It does the actual drawing of the weapon.
bool OtherIsA(Actor (UT) Other, name DesiredType)
Returns, whether an actor is of a specific type or identical to that type. (see IdenticalTo property)
RestoreKillType( )
Reverts the effect of SetKillType(). Call this exactly as often as SetKillType() after doing damage or directly killing players.
class<Actor (UT)> ReturnMessageActor( )
Returns the DeathMessageActorClass if that's a subclass of EnhancedWeapon or /EnhancedProjectile, otherwise returns this class.
SetKillType(bool bSplashHit, bool bHeadHit)
Prepares this class' death messages to be used when a player is killed. Call this function if you use neither DirectDamage() nor SplashDamage() to do damage or kill a player and revert its effect after you're done.
SpawnExplosionEffects(vector HitLocation, vector HitNormal)
Spawns an explosion effect.
SpawnSubMunition(vector HitLocation, vector HitNormal, int Amount)
Spawns the specified number of sub-projectiles flying into random directions. You can use HitNormal to somewhat restrict the randomness of the projectiles' directions.
SplashDamage(optional vector HitLocation, optional Actor (UT) Other, optional vector HitNormal, optional bool bSpecialHit)
Similar to the HurtRadius() function, but deals out a direct hit to Other instead of doing splash dmaage to it. bSpecialHit tells whether the headshot death mesages of the regular damage type should be used for the direct hit.

Category Class (UT)
Category Custom Class

The Unreal Engine Documentation Site

Wiki Community

Topic Categories

Image Uploads

Random Page

Recent Changes

Offline Wiki

Unreal Engine

Console Commands

Terminology

FAQs

Help Desk

Mapping Topics

Mapping Lessons

UnrealEd Interface

UnrealScript Topics

UnrealScript Lessons

Making Mods

Class Tree

Modeling Topics

Chongqing Page

Log In