Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |
00001 00002 00003 00004 00005 00006 00007 00008 00009 00010 00011 00012 00013 00014 00015 00016 00017 00018 00019 00020 00021 00022 00023 00024 00025 00026 00027 00028 00029 00030 00031 00032 00033 00034 00035 00036 00037 00038 00039 00040 00041 00042 00043 00044 00045 00046 00047 00048 00049 00050 00051 00052 00053 00054 00055 00056 00057 00058 00059 00060 00061 |
/** * * Copyright 1998-2008 Epic Games, Inc. All Rights Reserved. */ class UTSeqAct_ChangeOrbBase extends SequenceAction; /** the PowerCore belonging to the team whose orb's base should be changed */ var() UTOnslaughtPowerCore FlagOwnerCore; /** the new base to set it to */ var() UTOnslaughtFlagBase NewBase; event Activated() { local UTOnslaughtGame Game; local UTOnslaughtFlag Flag; if (FlagOwnerCore == None) { ScriptLog("Error: Flag Owner's PowerCore not specified"); } else if (NewBase == None) { ScriptLog("Error: No valid base was connected to the action"); } else if (NewBase.GetTeamNum() != FlagOwnerCore.DefenderTeamIndex) { ScriptLog("Error: Can't move to new base" @ NewBase @ "because it is on a different team than the orb being moved"); } else if (FlagOwnerCore.DefenderTeamIndex < ArrayCount(Game.Teams)) { Game = UTOnslaughtGame(FlagOwnerCore.WorldInfo.Game); Flag = UTOnslaughtFlag(Game.Teams[FlagOwnerCore.DefenderTeamIndex].TeamFlag); if (Flag != None) { UTOnslaughtFlagBase(Flag.HomeBase).myFlag = None; Flag.HomeBase = NewBase; NewBase.myFlag = Flag; if (Flag.bHome) { Flag.SetLocation(NewBase.Location + (Flag.HomeBaseOffset >> NewBase.Rotation)); Flag.SetRotation(NewBase.Rotation); NewBase.ObjectiveChanged(); } Flag.bForceNetUpdate = TRUE; } } } defaultproperties { bCallHandler=False VariableLinks(0)=(LinkDesc="Flag Owner's PowerCore",PropertyName="FlagOwnerCore",MaxVars=1) VariableLinks(1)=(ExpectedType=Class'Engine.SeqVar_Object',LinkDesc="New Base",PropertyName="NewBase",MinVars=1,MaxVars=1) ObjName="Change Orb Base" ObjCategory="Objective" Name="Default__UTSeqAct_ChangeOrbBase" ObjectArchetype=SequenceAction'Engine.Default__SequenceAction' } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |