| Home Page | Recent Changes | Preferences

ComboTrigger

UT2003 :: Actor >> Triggers >> Trigger >> ComboTrigger (custom)

A custom trigger class that begins an adrenaline Combo on the player who touches it.

This class simply demonstrates:

  • Working with Triggers
  • How combos work (you'll get only the initial effect at your feet if you don't have enough adrenaline)

Source Code

//=============================================================================
// ComboTrigger.
//=============================================================================
class ComboTrigger extends Trigger
    placeable;

var Combo myCombo;

function Touch( actor Other )
{
    super.Touch(Other);

    if( IsRelevant( Other ) )
    {
        if( xPawn(Other) != None ) {
            xPawn(Other).Controller.Adrenaline = 1;

            xPawn(Other).DoCombo(class'ComboBerserk');
            myCombo = xPawn(Other).CurrentCombo;
            myCombo.AdrenalineCost = 0;
        }
    }
}

Related Topics

Discussion

SuperApe: I'm sure this page could use some more overview, linkage, etc. Is it part of the UnrealScript Lessons?

MythOpus: It's just a custom class...

SuperApe: I guess I'm wondering if it's worth including in UnrealScript Lessons. IOW, where are other good places to link from? I will link from Adrenaline, Trigger and Combo.


Category Custom Class

The Unreal Engine Documentation Site

Wiki Community

Topic Categories

Image Uploads

Random Page

Recent Changes

Offline Wiki

Unreal Engine

Console Commands

Terminology

FAQs

Help Desk

Mapping Topics

Mapping Lessons

UnrealEd Interface

UnrealScript Topics

UnrealScript Lessons

Making Mods

Class Tree

Modeling Topics

Chongqing Page

Log In