06- Making a Pushable Objective

For this example, I will go into detail on how to setup a Pushable Objective for your maps. It will have the following functionality.

  • Attackers can push it by standing behind it
  • Defenders can halt it's progress if they outnumber the attackers
  • The wheels will turn and sound will play as it moves
  • A HUD marker with a progress bar above the Pushable
  • Objective Will complete when it has reached it's destination

 

--

 

Actor Setup

You will need:

AOCHUDMarker

AOCObjective_Generic

AOCTriggerVolume with EFAC_Mason

AOCTriggerVolume with EFAC_Agatha

Skeletal Mesh Actor: SkeletalMesh'CHV_petard.Meshes.petard_skel' with a Physics Asset: PhysicsAsset'CHV_petard.Meshes.petard_Physics'

 

Through the Actor Properties (F4) both of the AOCTriggerVolumes and the HUD Marker to the Skeletal Mesh (Bomb Cart.)

You can lock the window for attaching by clicking the Lock Actors Pad Lock

http://udn.epicgames.com/Three/AttachingActors.html

Initial Kismet

Same as all previous example. You are just disabling Objective Items on Level Load, and enabling them on Level Reset. They Key Action is the Toggle highlighted in orange. On Level Reset, it opens the Gate allowing for the Pushable to be used.

Push Volume Logic

With the Gate now open, the first step in moving the Pushable is similar to the Capture Point section. After touching the AOCTriggerVolume set to Agatha (The Pushers), a Delay will trigger, acting as a "Tick" that checks the volumes every second. There are two Count AOCPawn Actions being used to check the contents of the AOCTriggerVolumes. A Comparison (Compare Int) is being run every second, check to see if the Pushable Should be moved.

 

If A(Agatha) is less than or equal to B(Mason), the Pushable will not move, as it's Play Rate has been set to (0). If A(Agatha) is greater than B(Mason), the Play Rate is set to (1) and the Play Input of the Matinee is activated. This check continues until the Matinee completes, at which point the Objective is ended.

 

Matinee Setup

I am not going to detail Matinee step by step, as that merits a guide on it's own. 

http://udn.epicgames.com/Three/MatineeUserGuide.html

 

Pete Bottmley has a more in depth Matinee tutorial on World of Level Design.                                                                       

http://www.worldofleveldesign.com/categories/wold-members-tutorials/petebottomley/udk-moving-doors.php

I will briefly go through the process of setting up the Skeletal Mesh Pushable below.

 

With the Skeletal Mesh Actor selected, enter Kismet and hold the "M" Key + Click to create a Matinee.

 

Double Click the Matinee Actor. This will open up a new interface. Right click, Add New Empty Group. I named mine Pushable_Move. Under it's properties add AnimSet'ANIM_Petard.ANIM_Petard' in the Group Anim Set.

.

 

Right click the group to add a Movement Track and an Anim Control Track.                                                            

 

In the movement track, you can add keyframes by hitting Enter. Simply move the Pushable where you want it to go, adding keyframes and rotating as needed.

 

The Anim Control Track simply plays the animation of the wheels spinning. Add the anim Move the same way as a key frame on the movement track. Just hit enter anywhere along the timeline.

You can then right click on the Anim bar to set it to looping, as a wheel should. The end result of all of this should look like below:

There are many other things you could do with Matinee, such as sound effects, events that block the Pushable, speeding it up/slowing it down on hills. This is just covering the very basics.

HUD Progress

I have attached the Kismet for this particular function, as it is a bit abstract. Essentially, it is pulling from the HUD Marker and the Matinee current position to create a progress bar. This text can be copy and pasted right into Kismet.

HudProgressBar.txt

 

The HUD Marker it is referencing should look like this in the Actor Properties. f Max Value Progress is the length of your Matinee.

Objective Completion

Nearly identical to all the other examples. Matinee completes, completing the objective with a Complete Objective Event. This then turns off the HUD Marker with a Toggle, and ends the game.

 

Â