UE2:AnotherPawn: Difference between revisions
Created Custom Class Page |
mNo edit summary |
||
Line 1: | Line 1: | ||
__TOC__ | |||
{{classbox| [[Legacy:UT2004|UT2004]] :: [[Legacy:Actor|Actor]] >> [[Legacy:Pawn|Pawn]] >> [[Legacy:UnrealPawn|UnrealPawn]] >> [[Legacy:XPawn|xPawn]] >> AnotherPawn (Custom)}} | {{classbox| [[Legacy:UT2004|UT2004]] :: [[Legacy:Actor|Actor]] >> [[Legacy:Pawn|Pawn]] >> [[Legacy:UnrealPawn|UnrealPawn]] >> [[Legacy:XPawn|xPawn]] >> AnotherPawn (Custom)}} | ||
A generic pawn that can be spawned by a [[ | A generic pawn that can be spawned by a [[Open_Source/Pawn_Factory|PawnFactory]]. It holds a variable of the factory that created the pawn. | ||
==Properties== | ==Properties== | ||
===Main=== | ===Main=== | ||
; [[Open_Source/Pawn_Factory]] ParentFactory : The factory that created the pawn. | ; [[Open_Source/Pawn_Factory| Pawn Factory]] ParentFactory : The factory that created the pawn. | ||
==Functions== | ==Functions== | ||
Line 12: | Line 13: | ||
==Code== | ==Code== | ||
<uscript> | <uscript> | ||
// ============================================================================ | // ============================================================================ | ||
Line 56: | Line 55: | ||
{ | { | ||
} | } | ||
</uscript></div> | </uscript></div> | ||
Revision as of 14:53, 1 April 2008
A generic pawn that can be spawned by a PawnFactory. It holds a variable of the factory that created the pawn.
Properties
Main
- Pawn Factory ParentFactory
- The factory that created the pawn.
Functions
- Destroyed() (simulated)
Code
<uscript> // ============================================================================ // AnotherPawn // Copyright (c) 2006 by Andrew Fyfe <andrew@neptune-one.net> // This program is free software; you can redistribute and/or modify // it under the terms of the Lesser Open Unreal Mod License version 1.1. // // A generic pawn that can be spawned by a PawnFactory. // ============================================================================
class AnotherPawn extends xPawn abstract;
// ============================================================================
// Properties
// ============================================================================
var PawnFactory ParentFactory; // The factory that created the pawn.
// ============================================================================
// Destroyed
// ============================================================================
simulated function Destroyed() { // If we were made in a factory, tell them we're dead :( if ( ParentFactory != None ) ParentFactory.PawnDestroyed( self );
super.Destroyed(); }
// ============================================================================
// Defaults
// ============================================================================
DefaultProperties { }
</uscript>