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 |
/** * Copyright 1998-2008 Epic Games, Inc. All Rights Reserved. */ class UTSeqAct_AddNamedBot extends SequenceAction; /** name of bot to spawn */ var() string BotName; /** If true, force the bot to a given team */ var() bool bForceTeam; /** The Team to add this bot to. For DM leave at 0, otherwise Red=0, Blue=1 */ var() int TeamIndex; /** NavigationPoint to spawn the bot at */ var() NavigationPoint StartSpot; /** reference to bot controller so Kismet can work with it further */ var UTBot SpawnedBot; event Activated() { local UTGame Game; Game = UTGame(GetWorldInfo().Game); if (Game != None) { Game.ScriptedStartSpot = StartSpot; if (Game.SinglePlayerMissionID != INDEX_NONE) { if (Game.NumDivertedOpponents > 0 && bForceTeam && TeamIndex != 0) { Game.NumDivertedOpponents--; } else { SpawnedBot = Game.SinglePlayerAddBot(BotName, bForceTeam, TeamIndex); } } else { SpawnedBot = Game.AddBot(BotName, bForceTeam, TeamIndex); } if (SpawnedBot != None && SpawnedBot.Pawn == None) { Game.RestartPlayer(SpawnedBot); } Game.ScriptedStartSpot = None; } } defaultproperties { VariableLinks(0)=(LinkDesc="Bot",PropertyName="SpawnedBot",bWriteable=True) VariableLinks(1)=(ExpectedType=Class'Engine.SeqVar_Object',LinkDesc="Spawn Point",PropertyName="StartSpot",MinVars=1,MaxVars=1) ObjClassVersion=2 ObjName="Add Named Bot" ObjCategory="AI" Name="Default__UTSeqAct_AddNamedBot" ObjectArchetype=SequenceAction'Engine.Default__SequenceAction' } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |