I don't need to test my programs. I have an error-correcting modem.

UE2:NIU2 (U2XMP)

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
U2XMP Object >> Actor >> Info >> Mutator >> U2Mutator >> NIU2
Package: 
U2

NIU2.uc Created By: Mike Fox Created On: 2/5/00 $Author: Sbrown $ $Date: 8/15/02 21:24 $ $Revision: 5 $

Constants[edit]

MaxWeaponClasses[edit]

Value: 64


MaxKeptClasses[edit]

Value: 32


LOTSATIME[edit]

Value: 99999.0


Properties[edit]

Property group 'NIU2'[edit]

bCycleWeapons[edit]

Type: bool

Modifiers: config

(true): false ==> players get all weapons in weapons list with auto-incrementing ammo

Default value: True

bRandomWeapons[edit]

Type: bool

Modifiers: config

(true): true ==> weapons selected randomly, false ==> weapons cycled sequentially

bUseAllWeapons[edit]

Type: bool

Modifiers: config

(true): true ==> if bWeaponsRandom is true, all weapons used once per cycle

Default value: True

DefaultPickupString[edit]

Type: string


Default value: "U2.HumanHealthPickup"

HealthIncrementAmount[edit]

Type: int

Modifiers: config

(0): rate at which health of players is incremented

HealthIncrementSoundStr[edit]

Type: string

Modifiers: config

(None): sound to play when incrementing player's health

KeptClassStrings[edit]

Type: string

Array size: MaxKeptClasses

Modifiers: config

list of classes to leave alone

Default value, index 0: "U2.PowerSuit"

Default value, index 1: "U2.PowerSuitPickup"

Default value, index 2: "U2.HumanEnergyPickup"

MaxHealth[edit]

Type: int

Modifiers: config

(100): max that health can be auto-incremented to

Default value: 100

StartHealth[edit]

Type: int

Modifiers: config

(100): health that pawns start out with

Default value: 100

TimeBetweenAmmoIncrements[edit]

Type: float

Modifiers: config

(0.0): >0.0 ==> auto-increment ammo at this rate

Default value: 1.0

TimeBetweenHealthIncrements[edit]

Type: float

Modifiers: config

(5): secs between health updates if HealthIncrementRate >= 1

Default value: 5.0

TimeBetweenWeaponSwitchesMax[edit]

Type: float

Modifiers: config

(45): max secs between weapon switches

Default value: 30.0

TimeBetweenWeaponSwitchesMin[edit]

Type: float

Modifiers: config

(45): min secs between weapon switches

Default value: 30.0

WarningSoundRepeats[edit]

Type: int

Modifiers: config

(3): # times to repeat WarningSound

Default value: 3

WarningSoundStr[edit]

Type: string

Modifiers: config

(U2CTF.CTFTaken): sound to use for "about to switch" warning

Default value: "U2CTF.CTFTaken"

WeaponInfo[edit]

Type: WeaponInfoRawT

Array size: MaxWeaponClasses

Modifiers: config

list of weapons to use with ammo info

Default value, index 0:

Member Value
AmmoPerSecond 1.0
InitialAmmo 50
MaxAmmo 100
WeaponClassString "U2Weapons.weaponInvAssaultRifle"

Default value, index 1:

Member Value
AmmoPerSecond 1.0
InitialAmmo 50
MaxAmmo 200
WeaponClassString "U2Weapons.weaponInvEnergyRifle"

Default value, index 10:

Member Value
AmmoPerSecond 0.2
bEnabled True
InitialAmmo 20
MaxAmmo 50
WeaponClassString "U2Weapons.weaponInvSniperRifle"

Default value, index 11:

Member Value
AmmoPerSecond 0.2
InitialAmmo 5
MaxAmmo 5
WeaponClassString "U2Weapons.weaponInvTakkra"

Default value, index 12:

Member Value
AmmoPerSecond 1.0
bEnabled True
InitialAmmo 50
MaxAmmo 200
WeaponClassString "U2Weapons.weaponInvFlameThrower"

Default value, index 13:

Member Value
AmmoPerSecond 0.2
bEnabled True
InitialAmmo 10
MaxAmmo 50
WeaponClassString "U2Weapons.weaponInvGrenadeLauncher"

Default value, index 14:

Member Value
AmmoPerSecond 0.2
bEnabled True
InitialAmmo 10
MaxAmmo 100
WeaponClassString "U2Weapons.weaponInvLaserRifle"

Default value, index 15:

Member Value
AmmoPerSecond 0.5
InitialAmmo 25
MaxAmmo 100
WeaponClassString "U2Weapons.weaponInvLeechGun"

Default value, index 16:

Member Value
AmmoPerSecond 0.5
bEnabled True
InitialAmmo 25
MaxAmmo 50
WeaponClassString "U2Weapons.weaponInvPistol"

Default value, index 17:

Member Value
AmmoPerSecond 0.2
bEnabled True
InitialAmmo 10
MaxAmmo 50
WeaponClassString "U2Weapons.weaponInvRocketLauncher"

Default value, index 18:

Member Value
AmmoPerSecond 0.2
InitialAmmo 25
MaxAmmo 50
WeaponClassString "U2Weapons.weaponInvShotgun"

Default value, index 19:

Member Value
AmmoPerSecond 0.2
InitialAmmo 10
MaxAmmo 50
WeaponClassString "U2Weapons.weaponInvSingularityCannon"

Internal variables[edit]

bDidTick[edit]

Type: bool

set after first tick occurs

bForceWeaponSpawn[edit]

Type: bool

set to force CheckReplacement to return true for weapons

ChooseWeaponWarningTime[edit]

Type: float

secs before weapon switch to warn clients

CurrentWeaponClass[edit]

Type: class<Weapon>

current weapon class

CurrentWeaponIndex[edit]

Type: int

index into FilteredWeaponInfo for current weapon

DefaultPickupClass[edit]

Type: class<Pickup>

default replacement for pickups when not keeping ammo

DefaultWeaponString[edit]

Type: string

fallback weapon in case of problems

Default value: "U2Weapons.WeaponInvRocketLauncher"

FilteredWeaponInfo[edit]

Type: WeaponInfoT

Array size: MaxWeaponClasses

filtered list of weapon classes to use and ammo info

HealthIncrementSound[edit]

Type: Sound


KeptClasses[edit]

Type: class<Actor>

Array size: MaxKeptClasses

list of classes to keep

NextAmmoIncrementTime[edit]

Type: float

when to increment ammo

NextChooseWeaponTime[edit]

Type: float

when to switch again

NextIncrementHealthTime[edit]

Type: float

when to do another pass through player health values

NumKeptClasses[edit]

Type: int

number of classes in KeptClassStrings list

NumUsedWeapons[edit]

Type: int

number of weapons used so far (used with bUseAllWeapons)

NumWarnings[edit]

Type: int

did "about to switch" warning

NumWeapons[edit]

Type: int

number of active weapons in internal list

WarningSound[edit]

Type: Sound

loaded warning sound

Structs[edit]

WeaponInfoRawT[edit]

string WeaponClassString 
weapon class string
int InitialAmmo 
initial ammo for weapon
int MaxAmmo 
max ammo for weapon
float AmmoPerSecond 
rate at which ammo added
bool bEnabled 
whether weapon is enabled

WeaponInfoT[edit]

class<Weapon> WeaponClass 
weapon class
int InitialAmmo 
initial ammo for weapon
int MaxAmmo 
max ammo for weapon
float AmmoPerSecond 
rate at which ammo added
float AmmoCount 
used internally to track ammo to add
bool bUsed 
weapon was used (used with bUseAllWeapons when picking weapon randomly)

Functions[edit]

Events[edit]

PreBeginPlay[edit]

event PreBeginPlay ()

Overrides: Mutator.PreBeginPlay


Tick[edit]

event Tick (float DeltaTime)

Overrides: Actor.Tick


Other instance functions[edit]

AddAmmo[edit]

function AddAmmo (Ammunition AInv, int Amount)


AddWeaponClass[edit]

function bool AddWeaponClass (string WeaponClassString, int Index)


AlwaysKeep[edit]

function bool AlwaysKeep (Actor Other)

Overrides: Mutator.AlwaysKeep


AssignSounds[edit]

function AssignSounds ()


CheckReplacement[edit]

function bool CheckReplacement (Actor Other, out byte bSuperRelevant)

Overrides: Mutator.CheckReplacement


ChooseWeapon[edit]

function ChooseWeapon ()


GiveWeaponTo[edit]

function GiveWeaponTo (Pawn P, class<WeaponWeaponClass)


IncrementAllInventoryAmmo[edit]

function IncrementAllInventoryAmmo ()


ModifyPlayer[edit]

function ModifyPlayer (Pawn Other)

Overrides: Mutator.ModifyPlayer


MyDefaultWeapon[edit]

function class<WeaponMyDefaultWeapon ()

Overrides: Mutator.MyDefaultWeapon


ResetUsedWeapons[edit]

function ResetUsedWeapons ()


SetInventory[edit]

function SetInventory (Pawn P)


SetWeaponAmmo[edit]

function SetWeaponAmmo (Weapon W, Pawn Other, int Amount, int Max)


ShouldKeep[edit]

function bool ShouldKeep (Actor Other)


TransformPickups[edit]

function TransformPickups ()


WeaponTimeDemoLog[edit]

function WeaponTimeDemoLog ()