Вы находитесь на странице: 1из 4

Creating enemies in UDK

Creating Enemies in UDK


This is a simple tutorial intended that will show you how to, spawn a bot from level Loaded, from a trigger, respawn a bot after death (infinite) and re-spawn a bot after death (a number of times)

Spawn a bot from level Loaded


Right click in level where you want bot to spawn, Choose add actor - add PathNode. Select the path node and enter Kismet.

Right Click anywhere- New Event - Level Loaded Right Click anywhere again - new action actor - actor factory right click on spawn point (actor factory) choose new object var using PathNode 0 connect Level Loaded to Spawn Actor on the actor factory properties (blue arrow) choose UTActorFactoryAI Click on drop down arrow beside Factory Tick Force Deathmatch AI Set Controller Class - None Set Pawn Class UTPawn Tick Give Default Inventory click the little Green Cross on Inventory List and select any weapon from the dropdown menu

The bot will now spawn when the level starts


Tutor - Padraig Cahill

Creating enemies in UDK

Spawn a bot from a trigger


place a trigger and a player start on your level select the trigger open kismet

add new event using trigger - touch add new action - actor factory connect trigger Touched to Spawn Actor go back to your level and select the player start back into in kismet right click on spawn point (actor factory) choose new object var using player start on the actor factory properties (blue arrow) choose UTActorFactoryAI Controller Class - None Pawn Class - UTPawn Tick Give Default Inventory Tick Force Deathmatch AI click the little Green Cross on Inventory List select any weapon from the dropdown menu

Once finished Build All and test your map, walk into the Trigger and a bot will spawn and shoot you
Tutor - Padraig Cahill

Creating enemies in UDK

Re-spawn a bot after death (infinite)


Using the kismet you already have from parts 1 and 2 open Kismet New Action - Event - Attach to Event New Event - Pawn - Death Right click on Spawned (Actor Factory) - Create New Object Variable connect them up like the picture below

The bot will now re-spawn on death.

Tutor - Padraig Cahill

Creating enemies in UDK

Re-spawn a bot after death (a number of times)


Starting from what you have from Part 3 open kismet New Condition - Counter - IntCounter on the IntCounter properties: set Value B to the number of times you want the bot to re-spawn connect them up like the picture below

Tutor - Padraig Cahill

Вам также может понравиться