Core
Class Object

source: C:\XIII\Core\Classes\Object.uc
Direct Known Subclasses:Actor, AnimEditProps, Bitmap, Canvas, CheatManager, ForceFeedbackController, Interactions, LevelSummary, MatchMakingManager, Material, MeshEditProps, Palette, ParticleEmitter, Player, PlayerInput, ReachSpec, SequEditProps, TestObj, VideoPlayer, XboxLiveManager, GUI, GUIMultiListBoxLine, XIIIMenuData, WebApplication, WebRequest, WebResponse, XIIISaveMenuStack, XIIIArmes, XIIIDeco, TousLesPersos, Commandlet, Locale, Subsystem, Time, XIIIVehicule, BrushBuilder, MaterialFactory

class Object

//============================================================================= // Object: The base class all objects. // This is a built-in Unreal class and it shouldn't be modified. //=============================================================================
Variables
 int ObjectFlags
 int ObjectInternal[6]
 Object Outer


Function Summary
 float Abs(float A)
     
// Float functions.
 float Acos(float A)
 int Asc(string S)
 float Atan(float A)
 string Caps(string S)
 string Chr(int i)
 int Clamp(int V, int A, int B)
 bool ClassIsChildOf(class TestClass, class ParentClass)
     
// Objects.
 float Cos(float A)
 void DebugLog(string msg)
     
// log in script debug mode only
 void Disable(name ProbeFunc)
 Object DynamicLoadObject(string ObjectName, class ObjectClass, optional bool)
 void Enable(name ProbeFunc)
     
// Probe messages.
 float Exp(float A)
 float FClamp(float V, float A, float B)
 float FMax(float A, float B)
 float FMin(float A, float B)
 float FRand()
 Object FindObject(string ObjectName, class ObjectClass)
 void GetAxes(rotator A, out vector, out vector, out vector)
     
// Rotator operators and functions.
 name GetEnum(Object E, int i)
 string GetPropertyText(string PropName)
     
// Properties.
 name GetStateName()
 void GetUnAxes(rotator A, out vector, out vector, out vector)
 void GotoState(optional name, optional name)
     
// Goto state and label.
 int InStr(string S, string t)
 void Invert(out vector, out vector, out vector)
 bool IsA(name ClassName)
 bool IsInState(name TestState)
 string Left(string S, int i)
 int Len(string S)
     
// String functions.
 float Lerp(float Alpha, float A, float B)
 string Localize(string SectionName, string KeyName, string PackageName)
 void Log(string S, optional name)
     
// Logging.
 float Loge(float A)
 string Lowcaps(string S)
 int Max(int A, int B)
 string Mid(string S, int i, optional int)
 int Min(int A, int B)
 vector MirrorVectorByNormal(vector Vect, vector Normal)
 vector Normal(vector A)
 rotator Normalize(rotator Rot)
 rotator OrthoRotation(vector X, vector Y, vector Z)
 int Rand(int Max)
     
// Integer functions.
 float RandRange(float Min, float Max)
     
// Return a random number within the given range.
 void ResetConfig()
 string Right(string S, int i)
 rotator RotRand(optional bool)
 void SaveConfig()
     
// Configuration.
 void SetPropertyText(string PropName, string PropValue)
 float Sin(float A)
 float Smerp(float Alpha, float A, float B)
 float Sqrt(float A)
 float Square(float A)
 void StaticSaveConfig()
 float Tan(float A)
 vector VRand( )
 float VSize(vector A)
     
// Vector functions.
 void Warn(string S)



Source Code


00001	//=============================================================================
00002	// Object: The base class all objects.
00003	// This is a built-in Unreal class and it shouldn't be modified.
00004	//=============================================================================
00005	class Object
00006		native
00007		noexport;
00008	
00009	//=============================================================================
00010	// UObject variables.
00011	
00012	// Internal variables.
00013	var native private const int ObjectInternal[6];
00014	var native const object Outer;
00015	var native const int ObjectFlags;
00016	var(Object) native const editconst name Name;
00017	var(Object) native const editconst class Class;
00018	
00019	//=============================================================================
00020	// Unreal base structures.
00021	
00022	// Object flags.
00023	const RF_Transactional	= 0x00000001; // Supports editor undo/redo.
00024	const RF_Public         = 0x00000004; // Can be referenced by external package files.
00025	const RF_Transient      = 0x00004000; // Can't be saved or loaded.
00026	const RF_NotForClient	= 0x00100000; // Don't load for game client.
00027	const RF_NotForServer	= 0x00200000; // Don't load for game server.
00028	const RF_NotForEdit		= 0x00400000; // Don't load for editor.
00029	
00030	// A globally unique identifier.
00031	struct Guid
00032	{
00033		var int A, B, C, D;
00034	};
00035	
00036	// A point or direction vector in 3d space.
00037	struct Vector
00038	{
00039		var() config float X, Y, Z;
00040	};
00041	
00042	// A plane definition in 3d space.
00043	struct Plane extends Vector
00044	{
00045		var() config float W;
00046	};
00047	
00048	// An orthogonal rotation in 3d space.
00049	struct Rotator
00050	{
00051		var() config int Pitch, Yaw, Roll;
00052	};
00053	
00054	// An arbitrary coordinate system in 3d space.
00055	struct Coords
00056	{
00057		var() config vector Origin, XAxis, YAxis, ZAxis;
00058	};
00059	
00060	// Used to generate random values between Min and Max
00061	struct Range
00062	{
00063		var() config float Min;
00064		var() config float Max;
00065	};
00066	
00067	// Vector of Ranges
00068	struct RangeVector
00069	{
00070		var() config range X;
00071		var() config range Y;
00072		var() config range Z;
00073	};
00074	
00075	// A scale and sheering.
00076	struct Scale
00077	{
00078		var() config vector Scale;
00079		var() config float SheerRate;
00080		var() config enum ESheerAxis
00081		{
00082			SHEER_None,
00083			SHEER_XY,
00084			SHEER_XZ,
00085			SHEER_YX,
00086			SHEER_YZ,
00087			SHEER_ZX,
00088			SHEER_ZY,
00089		} SheerAxis;
00090	};
00091	
00092	// Camera orientations for Matinee
00093	enum ECamOrientation
00094	{
00095		CAMORIENT_None,
00096		CAMORIENT_LookAtActor,
00097		CAMORIENT_FacePath,
00098		CAMORIENT_Interpolate,
00099	};
00100	
00101	// A color.
00102	struct Color
00103	{
00104		var() config byte B, G, R, A;
00105	};
00106	
00107	// A bounding box.
00108	struct Box
00109	{
00110		var vector Min, Max;
00111		var byte IsValid;
00112	};
00113	
00114	// A bounding box sphere together.
00115	struct BoundingVolume extends Box
00116	{
00117		var plane Sphere;
00118	};
00119	
00120	// a 4x4 matrix
00121	struct Matrix
00122	{
00123		var() Plane XPlane;
00124		var() Plane YPlane;
00125		var() Plane ZPlane;
00126		var() Plane WPlane;
00127	};
00128	
00129	//=============================================================================
00130	// Constants.
00131	
00132	const MaxInt = 0x7fffffff;
00133	const Pi     = 3.1415926535897932;
00134	
00135	//=============================================================================
00136	// Basic native operators and functions.
00137	
00138	// Bool operators.
00139	native(129) static final preoperator  bool  !  ( bool A );
00140	native(242) static final operator(24) bool  == ( bool A, bool B );
00141	native(243) static final operator(26) bool  != ( bool A, bool B );
00142	native(130) static final operator(30) bool  && ( bool A, skip bool B );
00143	native(131) static final operator(30) bool  ^^ ( bool A, bool B );
00144	native(132) static final operator(32) bool  || ( bool A, skip bool B );
00145	
00146	// Byte operators.
00147	native(133) static final operator(34) byte *= ( out byte A, byte B );
00148	native(134) static final operator(34) byte /= ( out byte A, byte B );
00149	native(135) static final operator(34) byte += ( out byte A, byte B );
00150	native(136) static final operator(34) byte -= ( out byte A, byte B );
00151	native(137) static final preoperator  byte ++ ( out byte A );
00152	native(138) static final preoperator  byte -- ( out byte A );
00153	native(139) static final postoperator byte ++ ( out byte A );
00154	native(140) static final postoperator byte -- ( out byte A );
00155	
00156	// Integer operators.
00157	native(141) static final preoperator  int  ~  ( int A );
00158	native(143) static final preoperator  int  -  ( int A );
00159	native(144) static final operator(16) int  *  ( int A, int B );
00160	native(145) static final operator(16) int  /  ( int A, int B );
00161	native(146) static final operator(20) int  +  ( int A, int B );
00162	native(147) static final operator(20) int  -  ( int A, int B );
00163	native(148) static final operator(22) int  << ( int A, int B );
00164	native(149) static final operator(22) int  >> ( int A, int B );
00165	native(196) static final operator(22) int  >>>( int A, int B );
00166	native(150) static final operator(24) bool <  ( int A, int B );
00167	native(151) static final operator(24) bool >  ( int A, int B );
00168	native(152) static final operator(24) bool <= ( int A, int B );
00169	native(153) static final operator(24) bool >= ( int A, int B );
00170	native(154) static final operator(24) bool == ( int A, int B );
00171	native(155) static final operator(26) bool != ( int A, int B );
00172	native(156) static final operator(28) int  &  ( int A, int B );
00173	native(157) static final operator(28) int  ^  ( int A, int B );
00174	native(158) static final operator(28) int  |  ( int A, int B );
00175	native(159) static final operator(34) int  *= ( out int A, float B );
00176	native(160) static final operator(34) int  /= ( out int A, float B );
00177	native(161) static final operator(34) int  += ( out int A, int B );
00178	native(162) static final operator(34) int  -= ( out int A, int B );
00179	native(163) static final preoperator  int  ++ ( out int A );
00180	native(164) static final preoperator  int  -- ( out int A );
00181	native(165) static final postoperator int  ++ ( out int A );
00182	native(166) static final postoperator int  -- ( out int A );
00183	
00184	// Integer functions.
00185	native(167) static final Function     int  Rand  ( int Max );
00186	native(249) static final function     int  Min   ( int A, int B );
00187	native(250) static final function     int  Max   ( int A, int B );
00188	native(251) static final function     int  Clamp ( int V, int A, int B );
00189	
00190	// Float operators.
00191	native(169) static final preoperator  float -  ( float A );
00192	native(170) static final operator(12) float ** ( float A, float B );
00193	native(171) static final operator(16) float *  ( float A, float B );
00194	native(172) static final operator(16) float /  ( float A, float B );
00195	native(173) static final operator(18) float %  ( float A, float B );
00196	native(174) static final operator(20) float +  ( float A, float B );
00197	native(175) static final operator(20) float -  ( float A, float B );
00198	native(176) static final operator(24) bool  <  ( float A, float B );
00199	native(177) static final operator(24) bool  >  ( float A, float B );
00200	native(178) static final operator(24) bool  <= ( float A, float B );
00201	native(179) static final operator(24) bool  >= ( float A, float B );
00202	native(180) static final operator(24) bool  == ( float A, float B );
00203	native(210) static final operator(24) bool  ~= ( float A, float B );
00204	native(181) static final operator(26) bool  != ( float A, float B );
00205	native(182) static final operator(34) float *= ( out float A, float B );
00206	native(183) static final operator(34) float /= ( out float A, float B );
00207	native(184) static final operator(34) float += ( out float A, float B );
00208	native(185) static final operator(34) float -= ( out float A, float B );
00209	
00210	// Float functions.
00211	native(186) static final function     float Abs   ( float A );
00212	native(187) static final function     float Sin   ( float A );
00213	native(188) static final function     float Cos   ( float A );
00214	native(812) static final function     float Acos  ( float A );
00215	native(189) static final function     float Tan   ( float A );
00216	native(190) static final function     float Atan  ( float A );
00217	native(191) static final function     float Exp   ( float A );
00218	native(192) static final function     float Loge  ( float A );
00219	native(193) static final function     float Sqrt  ( float A );
00220	native(194) static final function     float Square( float A );
00221	native(195) static final function     float FRand ();
00222	native(244) static final function     float FMin  ( float A, float B );
00223	native(245) static final function     float FMax  ( float A, float B );
00224	native(246) static final function     float FClamp( float V, float A, float B );
00225	native(247) static final function     float Lerp  ( float Alpha, float A, float B );
00226	native(248) static final function     float Smerp ( float Alpha, float A, float B );
00227	
00228	// Vector operators.
00229	native(211) static final preoperator  vector -     ( vector A );
00230	native(212) static final operator(16) vector *     ( vector A, float B );
00231	native(213) static final operator(16) vector *     ( float A, vector B );
00232	native(296) static final operator(16) vector *     ( vector A, vector B );
00233	native(214) static final operator(16) vector /     ( vector A, float B );
00234	native(215) static final operator(20) vector +     ( vector A, vector B );
00235	native(216) static final operator(20) vector -     ( vector A, vector B );
00236	native(275) static final operator(22) vector <<    ( vector A, rotator B );
00237	native(276) static final operator(22) vector >>    ( vector A, rotator B );
00238	native(217) static final operator(24) bool   ==    ( vector A, vector B );
00239	native(218) static final operator(26) bool   !=    ( vector A, vector B );
00240	native(219) static final operator(16) float  Dot   ( vector A, vector B );
00241	native(220) static final operator(16) vector Cross ( vector A, vector B );
00242	native(221) static final operator(34) vector *=    ( out vector A, float B );
00243	native(297) static final operator(34) vector *=    ( out vector A, vector B );
00244	native(222) static final operator(34) vector /=    ( out vector A, float B );
00245	native(223) static final operator(34) vector +=    ( out vector A, vector B );
00246	native(224) static final operator(34) vector -=    ( out vector A, vector B );
00247	
00248	// Vector functions.
00249	native(225) static final function float  VSize  ( vector A );
00250	native(226) static final function vector Normal ( vector A );
00251	native(227) static final function        Invert ( out vector X, out vector Y, out vector Z );
00252	native(252) static final function vector VRand  ( );
00253	native(300) static final function vector MirrorVectorByNormal( vector Vect, vector Normal );
00254	
00255	// Rotator operators and functions.
00256	native(142) static final operator(24) bool ==     ( rotator A, rotator B );
00257	native(203) static final operator(26) bool !=     ( rotator A, rotator B );
00258	native(287) static final operator(16) rotator *   ( rotator A, float    B );
00259	native(288) static final operator(16) rotator *   ( float    A, rotator B );
00260	native(289) static final operator(16) rotator /   ( rotator A, float    B );
00261	native(290) static final operator(34) rotator *=  ( out rotator A, float B  );
00262	native(291) static final operator(34) rotator /=  ( out rotator A, float B  );
00263	native(316) static final operator(20) rotator +   ( rotator A, rotator B );
00264	native(317) static final operator(20) rotator -   ( rotator A, rotator B );
00265	native(318) static final operator(34) rotator +=  ( out rotator A, rotator B );
00266	native(319) static final operator(34) rotator -=  ( out rotator A, rotator B );
00267	native(229) static final function GetAxes         ( rotator A, out vector X, out vector Y, out vector Z );
00268	native(230) static final function GetUnAxes       ( rotator A, out vector X, out vector Y, out vector Z );
00269	native(320) static final function rotator RotRand ( optional bool bRoll );
00270	native(197) static final function rotator OrthoRotation( vector X, vector Y, vector Z );
00271	native(198) static final function rotator Normalize( rotator Rot );
00272	
00273	// String operators.
00274	native(112) static final operator(40) string $  ( coerce string A, coerce string B );
00275	native(168) static final operator(40) string @  ( coerce string A, coerce string B );
00276	native(115) static final operator(24) bool   <  ( string A, string B );
00277	native(116) static final operator(24) bool   >  ( string A, string B );
00278	native(120) static final operator(24) bool   <= ( string A, string B );
00279	native(121) static final operator(24) bool   >= ( string A, string B );
00280	native(122) static final operator(24) bool   == ( string A, string B );
00281	native(123) static final operator(26) bool   != ( string A, string B );
00282	native(124) static final operator(24) bool   ~= ( string A, string B );
00283	
00284	// String functions.
00285	native(125) static final function int    Len    ( coerce string S );
00286	native(126) static final function int    InStr  ( coerce string S, coerce string t );
00287	native(127) static final function string Mid    ( coerce string S, int i, optional int j );
00288	native(128) static final function string Left   ( coerce string S, int i );
00289	native(234) static final function string Right  ( coerce string S, int i );
00290	native(235) static final function string Caps   ( coerce string S );
00291	native      static final function string Lowcaps( coerce string S );
00292	native(236) static final function string Chr    ( int i );
00293	native(237) static final function int    Asc    ( string S );
00294	
00295	// Object operators.
00296	native(114) static final operator(24) bool == ( Object A, Object B );
00297	native(119) static final operator(26) bool != ( Object A, Object B );
00298	
00299	// Name operators.
00300	native(254) static final operator(24) bool == ( name A, name B );
00301	native(255) static final operator(26) bool != ( name A, name B );
00302	
00303	//=============================================================================
00304	// General functions.
00305	
00306	// Logging.
00307	native(231) static final function Log( coerce string S, optional name Tag );
00308	native(232) static final function Warn( coerce string S );
00309	native(199) static final function string Localize( string SectionName, string KeyName, string PackageName );
00310	
00311	// Goto state and label.
00312	native(113) static final function GotoState( optional name NewState, optional name Label );
00313	native(281) static final function bool IsInState( name TestState );
00314	native(284) static final function name GetStateName();
00315	
00316	// Objects.
00317	native(258) static final function bool ClassIsChildOf( class TestClass, class ParentClass );
00318	native(303) static final function bool IsA( name ClassName );
00319	
00320	// Probe messages.
00321	native(117) static final function Enable( name ProbeFunc );
00322	native(118) static final function Disable( name ProbeFunc );
00323	
00324	// Properties.
00325	native(200) static final function string GetPropertyText( string PropName );
00326	native(201) static final function SetPropertyText( string PropName, string PropValue );
00327	native(204) static final function name GetEnum( object E, int i );
00328	native(205) static final function object DynamicLoadObject( string ObjectName, class ObjectClass, optional bool MayFail );
00329	native(206) static final function object FindObject( string ObjectName, class ObjectClass );
00330	
00331	// Configuration.
00332	native(536) static final function SaveConfig();
00333	native(202) static final function StaticSaveConfig();
00334	native(203) static final function ResetConfig();
00335	
00336	// Return a random number within the given range.
00337	final function float RandRange( float Min, float Max )
00338	{
00339	    return Min + (Max - Min) * FRand();
00340	}
00341	
00342	//=============================================================================
00343	// Engine notification functions.
00344	
00345	//
00346	// Called immediately when entering a state, while within
00347	// the GotoState call that caused the state change.
00348	//
00349	event BeginState();
00350	
00351	//
00352	// Called immediately before going out of the current state,
00353	// while within the GotoState call that caused the state change.
00354	//
00355	event EndState();
00356	
00357	// log in script debug mode only
00358	debugonly function DebugLog(string msg)
00359	{
00360		Log(msg);
00361	}
00362	
00363	defaultproperties
00364	{
00365	}

End Source Code