The three virtues of a programmer: Laziness, Impatience, and Hubris. – Larry Wall

UE3:Object (UT3)

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
UT3 Object

Contents

Package: 
Core
Direct subclasses:
SpeedTree, OnlineStats, InterpTrackHelper, CameraMode, MaterialExpression, PhysicalMaterial, InterpCurveEdSetup, AnimNodeEditInfo, ThumbnailManager, MaterialEditorInstanceConstant, CurveEdPresetCurve, CameraModifier, SkeletalMesh, MaterialEditorOptions, QHDefaults, Canvas, ForceFeedbackManager, Surface, SequenceObjectHelper, UTMapMusicInfo, ParticleLODLevel, DebugManager, CurveEdOptions, MorphTargetSet, ActorFactory, Actor, AdditionalMapLists, AnimNode, AnimNotify, AnimSequence, AnimSet, AnimationCompressionAlgorithm, BasicWebAdminAuth, BookMark, BrowserManager, BrushBuilder, CameraAnim, CameraAnimInst, CascadeOptions, CheatManager, ClipPadEntry, CodecMovie, Commandlet, Component, CurveEdPresetBase, CustomPropertyItemBindings, DamageType, DataStoreCache, DecalLifetime, EdCoordSystem, FaceFXAnimSet, FaceFXAsset, FontImportOptions, Font, ForceFeedbackWaveform, GameTypes, GameViewportClient, GenericBrowserType, GeomModifier, WebAdminMenu, InterpEdOptions, InterpFilter, InterpGroupInst, InterpGroup, InterpTrackInst, InterpTrack, KMeshProps, KismetBindings, LensFlareEditorOptions, LensFlare, LevelStreaming, LightFunction, LightingChannelsObject, LocalMessage, MapInfo, MaterialEditorInstanceTimeVarying, MorphNodeBase, MorphTarget, MorphWeightSequence, MusicTrackDataStructures, ObjectReferencer, OnlineGameInterfaceImpl, OnlineProfileSettings, OnlineSubsystem, ParticleEmitter, TerrainEditOptions, ParticleModule, ParticleSystem, PhATSimOptions, PhysicalMaterialPropertyBase, PhysicsAssetInstance, PhysicsAsset, Player, PostProcessChain, PostProcessEffect, Prefab, PrimitiveComponentFactory, QHCurrent, RB_BodyInstance, RB_ConstraintInstance, RB_ConstraintSetup, ReachSpec, SaveGameSummary, SavedMove, Scene, SequenceObject, SessionHandler, Session, SettingsRenderer, Settings, WebAdminUtils, ShadowMap2D, SkelControlBase, SkeletalMeshSocket, SoundCue, SoundNodeHelper, SoundNode, SpeechRecognition, Subsystem, TerrainLayerSetup, TerrainMaterial, ThumbnailLabelRenderer, ThumbnailRenderer, UIRoot, UISceneManager, UTCharFamilyAssetStore, UTCustomLinkSetup, UTCustomChar_Data, UTFamilyInfo, UTGameModifierCard, UTMissionInfo, UTOfficialContent, UTPawnSoundGroup, UTTypes, UnrealEdKeyBindings, UnrealEdOptions, WebAdminMessages, WebApplication, WebRequest, WebResponse, Interface, SettingsProfile, UTMapList, StaticMesh, Field, Model, ShadowMap1D
Known custom subclasses:
UT_MDB (UT3), UT_MDB_ObjectList (UT3)
This class in other games:
RTNP, U1, UT, U2, U2XMP, UE2Runtime, UT2003, UT2004, UDK

The base class all objects. Because all other classes directly or indirectly inherit from the Object class, all constants, enums, structs, functions and operators defined here could be called "global" constants, enums, etc.

Constants[edit]

MaxInt[edit]

Value: 0x7fffffff

Maximum possible int value in UnrealScript. The minimum possible int value is 0x80000000 or ~MaxInt. (That's a tilde, the bitwise complement operator.)

Pi[edit]

Value: 3.1415926535897932

The closest approximation of Pi that fits into UnrealScript's float type.

RadToDeg[edit]

Value: 57.295779513082321600 (180 / Pi)

The conversion factor from radians to degrees.

DegToRad[edit]

Value: 0.017453292519943296 (Pi / 180)

The conversion factor from degrees to radians.

INDEX_NONE[edit]

Value: -1

This value is returned by search operations, such as the Find operation on dynamic arrays or the InStr function, if no match was found.

Properties[edit]

Property group 'Object'[edit]

Name[edit]

Type: name

Modifiers: native, const, editconst


ObjectArchetype[edit]

Type: Object

Modifiers: native, const, editconst


Internal variables[edit]

Class[edit]

Type: Class

Modifiers: native, const


HashNext[edit]

Type: pointer

Modifiers: native, private, const


HashOuterNext[edit]

Type: pointer

Modifiers: native, private, const


Linker[edit]

Type: Object

Modifiers: native, private, const, noexport


LinkerIndex[edit]

Type: pointer

Modifiers: native, private, const, noexport


NetIndex[edit]

Type: int

Modifiers: native, private, const, noexport


ObjectFlags[edit]

Type: qword

Modifiers: native, private, const

This needs to be 8-byte aligned!

ObjectInternalInteger[edit]

Type: int

Modifiers: native, private, const, noexport


Outer[edit]

Type: Object

Modifiers: native, const


StateFrame[edit]

Type: pointer

Modifiers: native, private, const


VfTableObject[edit]

Type: pointer

Modifiers: native, private, const, noexport


Enums[edit]

EAxis[edit]

AXIS_NONE 
= 0
AXIS_X 
= 1
AXIS_Y 
= 2
AXIS_BLANK 
= 3. Need this because AXIS enum is used as bitfield in C++...
AXIS_Z 
4

EInputEvent[edit]

IE_Pressed 
IE_Released 
IE_Repeat 
IE_DoubleClick 
IE_Axis 

EInterpCurveMode[edit]

CIM_Linear 
CIM_CurveAuto 
CIM_Constant 
CIM_CurveUser 
CIM_CurveBreak 

EInterpMethodType[edit]

IMT_UseFixedTangentEval 
IMT_UseBrokenTangentEval 

ETickingGroup[edit]

Determines which ticking group an Actor/Component belongs to

TG_PreAsyncWork 
Any item that needs to be updated before asynchronous work is done
TG_DuringAsyncWork 
Any item that can be run in parallel of our async work
TG_PostAsyncWork 
Any item that needs the async work to be done before being updated

Structs[edit]

See Object structs.

Functions[edit]

Static native functions[edit]

See Object static native functions.

Other static functions[edit]

ClampRotAxis[edit]

static final simulated function ClampRotAxis (int ViewAxis, out int out_DeltaViewAxis, int MaxLimit, int MinLimit)

Clamp a rotation Axis. The ViewAxis rotation component must be normalized (within the [-32768,+32767] range). This function will set out_DeltaViewAxis to the delta needed to bring ViewAxis within the [MinLimit,MaxLimit] range.

Parameters:

  • ViewAxis - Rotation Axis to clamp
  • out_DeltaViewAxis - Delta Rotation Axis to be added to ViewAxis rotation (from ProcessViewRotation). Set to be the Delta to bring ViewAxis within the [MinLimit,MaxLimit] range.
  • MaxLimit - Maximum for Clamp. ViewAxis will not exceed this.
  • MinLimit - Minimum for Clamp. ViewAxis will not go below this.

ColorToLinearColor[edit]

static final function LinearColor ColorToLinearColor (Color OldColor)

converts a color to a LinearColor

Parameters:

  • OldColor - the color to convert

Returns:

the matching LinearColor

FindDeltaAngle[edit]

static final simulated function float FindDeltaAngle (float A1, float A2)

Gets the difference in world space angles in [-PI,PI] range

Parameters:

  • A1 - First angle
  • A2 - Second angle

FInterpEaseIn[edit]

static final function float FInterpEaseIn (float A, float B, float Alpha, float Exp)

Interpolates with ease-in (smoothly approaches B).

Parameters:

  • A - Value to interpolate from.
  • B - Value to interpolate to.
  • Alpha - Interpolant.
  • Exp - Exponent. Higher values result in more rapid deceleration.

Returns:

Interpolated value.

FInterpEaseOut[edit]

static final function float FInterpEaseOut (float A, float B, float Alpha, float Exp)

Interpolates with ease-out (smoothly departs A).

Parameters:

  • A - Value to interpolate from.
  • B - Value to interpolate to.
  • Alpha - Interpolant.
  • Exp - Exponent. Higher values result in more rapid acceleration.

Returns:

Interpolated value.

FPctByRange[edit]

static final simulated function float FPctByRange (float Value, float InMin, float InMax)

Returns the relative percentage position Value is in the range [Min,Max]. Examples: - GetRangeValueByPct( 2, 4, 2 ) == 0 - GetRangeValueByPct( 2, 4, 4 ) == 1 - GetRangeValueByPct( 2, 4, 3 ) == 0.5

Parameters:

  • Min - Min limit
  • Max - Max limit
  • Value - Value between Range.

Returns:

relative percentage position Value is in the range [Min,Max].

GetAngularDegreesFromRadians[edit]

static final simulated function GetAngularDegreesFromRadians (out Vector2D OutFOV)


GetHeadingAngle[edit]

static final simulated function float GetHeadingAngle (Vector Dir)

Returns world space angle (in radians) of given vector

Parameters:

  • Dir - Vector to be converted into heading angle

GetRangePctByValue[edit]

static final simulated function float GetRangePctByValue (Vector2D Range, float Value)

Returns the relative percentage position Value is in the Range. Examples: - GetRangeValueByPct( Range, Range.X ) == 0 - GetRangeValueByPct( Range, Range.Y ) == 1 - GetRangeValueByPct( Range, (Range.X+Range.Y)/2 ) == 0.5

Parameters:

  • Range - Range of values. [Range.X,Range.Y]
  • Value - Value between Range.

Returns:

relative percentage position Value is in the Range.

GetRangeValueByPct[edit]

static final simulated function float GetRangeValueByPct (Vector2D Range, float Pct)

Returns the value in the Range, relative to Pct. Examples: - GetRangeValueByPct( Range, 0.f ) == Range.X - GetRangeValueByPct( Range, 1.f ) == Range.Y - GetRangeValueByPct( Range, 0.5 ) == (Range.X+Range.Y)/2

Parameters:

  • Range - Range of values. [Range.X,Range.Y]
  • Pct - Relative position in range in percentage. [0,1]

Returns:

the value in the Range, relative to Pct.

JoinArray[edit]

static final function JoinArray (array<stringStringArray, out string out_Result, optional string delim, optional bool bIgnoreBlanks)

Create a single string from an array of strings, using the delimiter specified, optionally ignoring blank members

Parameters:

  • StringArray - the array of strings to join into the single string
  • out_Result - out] will contain a single string containing all elements of the array, separated by the delimiter specified
  • Delim - the delimiter to insert where array elements are concatenated
  • bIgnoreBlanks - TRUE to skip elements which contain emtpy strings

MakeColor[edit]

static final function Color MakeColor (byte R, byte G, byte B, optional byte A)

Create a Color from independant RGBA components

MakeLinearColor[edit]

static final function LinearColor MakeLinearColor (float R, float G, float B, float A)

Create a LinearColor from independant RGBA components.

PointInBox[edit]

static final function bool PointInBox (Vector Point, Vector Location, Vector Extent)

Determines if point is inside given box

Parameters:

  • Point - Point to check
  • Location - Center of box
  • Extent - Size of box

Returns:

bool - TRUE if point is inside box, FALSE otherwise

RandRange[edit]

static final simulated function float RandRange (float InMin, float InMax)

Return a random number within the given range.

RSize[edit]

static final function float RSize (Rotator R)

returns Rotator Size (vector definition applied to rotators)

Parameters:

  • Rotator - R

Returns:

mathematical vector length: Sqrt(Pitch^2 + Yaw^2 + Roll^2)

SClampRotAxis[edit]

static final simulated function bool SClampRotAxis (float DeltaTime, int ViewAxis, out int out_DeltaViewAxis, int MaxLimit, int MinLimit, float InterpolationSpeed)

Smooth clamp a rotator axis. This is mainly used to bring smoothly a rotator component within a certain range [MinLimit,MaxLimit]. For example to limit smoothly the player's ViewRotation Pitch or Yaw component.

Parameters:

  • fDeltaTime - Elapsed time since this function was last called, for interpolation.
  • ViewAxis - Rotator's Axis' current angle.
  • out_DeltaViewAxis - Delta Value of Axis to be added to ViewAxis (through PlayerController::ProcessViewRotation(). This value gets modified.
  • MaxLimit - Up angle limit.
  • MinLimit - Negative angle limit (value must be negative)
  • InterpolationSpeed - Interpolation Speed to bring ViewAxis within the [MinLimit,MaxLimit] range.

Split[edit]

static final function string Split (coerce string Text, coerce string SplitStr, optional bool bOmitSplitStr)

Splits Text on the first occurence of Split and returns the remaining part of Text.

UnwindHeading[edit]

static final simulated function float UnwindHeading (float a)


vect2d[edit]

static final function Vector2D vect2d (float InX, float InY)

Construct a vector2d variable

Native functions[edit]

ClearConfig[edit]

native(538) final function ClearConfig (optional string PropertyName)

Removes the values for all configurable properties in this object's class from the .ini file.

Parameters:

  • PropertyName - if specified, only this property's value will be removed.

Disable[edit]

native(118) final function Disable (name ProbeFunc)


DumpStateStack[edit]

native final function DumpStateStack ()

Logs the current state stack for debugging purposes.

Enable[edit]

native(117) final function Enable (name ProbeFunc)


GetStateName[edit]

native(284) final function name GetStateName ()

Returns the current state name, useful for determining current state similar to IsInState. Note: This *doesn't* work with inherited states, in that it will only compare at the lowest state level.

Returns:

Name of the current state

GotoState[edit]

native(113) final function GotoState (optional name NewState, optional name Label, optional bool bForceEvents, optional bool bKeepStack)

Transitions to the desired state and label if specified, generating the EndState event in the current state if applicable and BeginState in the new state, unless transitioning to the same state.

Parameters:

  • NewState - new state to transition to
  • Label - optional Label to jump to
  • bForceEvents - optionally force EndState/BeginState to be called even if transitioning to the same state.
  • bKeepStack - prevents state stack from being cleared

IsA[edit]

native(197) final function bool IsA (name ClassName)


IsChildState[edit]

native final function bool IsChildState (name TestState, name TestParentState)

Returns true if TestState derives from TestParentState.

IsInState[edit]

native(281) final function bool IsInState (name TestState, optional bool bTestStateStack)

Checks the current state and determines whether or not this object is actively in the specified state. Note: This does work with inherited states.

Parameters:

  • TestState - state to check for
  • bTestStateStack - check the state stack? (does *NOT* work with inherited states in the stack)

Returns:

True if currently in TestState

IsPendingKill[edit]

native final function bool IsPendingKill ()

Returns whether the object is pending kill and about to have references to it NULLed by the garbage collector.

Returns:

TRUE if object is pending kill, FALSE otherwise

PointDistToLine[edit]

native final function float PointDistToLine (Vector Point, Vector Line, Vector Origin, optional out Vector OutClosestPoint)

Calculates the distance of a given Point in world space to a given line, defined by the vector couple (Origin, Direction).

Parameters:

  • Point - point to check distance to Axis
  • Line - unit vector indicating the direction to check against
  • Origin - point of reference used to calculate distance
  • OutClosestPoint - optional point that represents the closest point projected onto Axis

Returns:

distance of Point from line defined by (Origin, Direction)

PopState[edit]

native final function PopState (optional bool bPopAll)

Pops the current pushed state, returning execution to the previous state at the same code point. Note: PopState() will have no effect if no state has been pushed onto the stack.

This will call PoppedState when entering the state that was just pushed on the state stack. It will not call EndState.

Parameters:

  • bPopAll - optionally pop all states on the stack to the originally executing one

See: event PausedState

PushState[edit]

native final function PushState (name NewState, optional name NewLabel)

Pushes the new state onto the state stack, setting it as the current state until a matching PopState() is called. Note that multiple states may be pushed on top of each other. You may not push the same state multiple times.

This will call PushedState when entering the state that was just pushed on the state stack. It will not call BeginState.

Parameters:

  • NewState - name of the state to push on the stack
  • NewLabel - optional name of the state label to jump to

See: event ContinuedState

SaveConfig[edit]

native(536) final function SaveConfig ()


TransformVectorByRotation[edit]

native final function Vector TransformVectorByRotation (Rotator SourceRotation, Vector SourceVector, optional bool bInverse)

Script hook to FRotationMatrix::TransformFVector().

Events[edit]

BeginState[edit]

event BeginState (name PreviousStateName)

Called immediately when entering a state, while within the GotoState() call that caused the state change (before any state code is executed).

ContinuedState[edit]

event ContinuedState ()

Called on the state that is no longer paused because of a PopState().

EndState[edit]

event EndState (name NextStateName)

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.

PausedState[edit]

event PausedState ()

Called on the state that is being paused because of a PushState().

PoppedState[edit]

event PoppedState ()

Called immediately in the current state that is being popped off of the state stack, before the new state is activated.

PushedState[edit]

event PushedState ()

Called immediately in the new state that was pushed onto the state stack, before any state code is executed.

Other instance functions[edit]

ByteToFloat[edit]

simulated final function float ByteToFloat (byte inputByte, optional bool bSigned)

Converts a 0-255 byte to a float value, to a range of 0.f to 1.f.

Parameters:

  • inputByte - byte to convert
  • bSigned - optional, spit out -1.f to 1.f instead

Returns:

newly converted value

FloatToByte[edit]

simulated final function byte FloatToByte (float inputFloat, optional bool bSigned)

Converts a float value to a 0-255 byte, assuming a range of 0.f to 1.f.

Parameters:

  • inputFloat - float to convert
  • bSigned - optional, assume a range of -1.f to 1.f

Returns:

byte value 0-255

GetPackageName[edit]

final function name GetPackageName ()

Returns:

the name of the package this object resides in

GetSpecialValue[edit]

function string GetSpecialValue (name PropertyName)

these accessors allow classes to implement an interface to setting certain property values without creating a dependancy on that class, similarly to how IsA() allows checking for a class without creating a dependancy on it

PointDistToPlane[edit]

simulated final function float PointDistToPlane (Vector Point, Rotator Orientation, Vector Origin, optional out Vector out_ClosestPoint)

Calculates the distance of a given point to the given plane. (defined by a combination of vector and rotator) Rotator.AxisX = U, Rotator.AxisY = Normal, Rotator.AxisZ = V

Parameters:

  • Point - Point to check distance to Orientation
  • Orientation - Rotator indicating the direction to check against
  • Origin - Point of reference used to calculate distance
  • out_ClosestPoint - Optional point that represents the closest point projected onto Plane defined by the couple (Origin, Orientation)

Returns:

distance of Point to plane

SetSpecialValue[edit]

function SetSpecialValue (name PropertyName, string NewValue)


Operators[edit]

See Object operators.