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 00062 00063 00064 00065 00066 00067 00068 00069 00070 00071 00072 00073 00074 00075 00076 00077 00078 00079 00080 00081 00082 00083 00084 00085 00086 00087 00088 00089 00090 00091 00092 |
class Combo extends Info; #exec OBJ LOAD FILE=GameSounds.uax var localized string ExecMessage; var float AdrenalineCost; var float Duration; var Sound ActivateSound; var Material Icon; var class<xEmitter> ActivationEffectClass; var sound ComboAnnouncement; // OBSOLETE var name ComboAnnouncementName; var int keys[4]; var class<SpeciesType> species; // CK_Up = 1; // CK_Down = 2; // CK_Left = 4; // CK_Right = 8; function PostBeginPlay() { local xPawn P; P = xPawn(Owner); if (P == None) { Destroy(); return; } if (ActivateSound != None) PlaySound(ActivateSound, SLOT_None, 2*TransientSoundVolume); if (ActivationEffectClass != None) Spawn(ActivationEffectClass, P,, P.Location, P.Rotation); // it's responsible for killing itself StartEffect(P); } // called when Adrenaline has been drained empty function AdrenalineEmpty() { Destroy(); } function Destroyed() { local xPawn P; P = xPawn(Owner); if (P != None) { StopEffect(P); if (P.CurrentCombo == self) P.CurrentCombo = None; } } function StartEffect(xPawn P); function StopEffect(xPawn P); simulated function Tick(float DeltaTime) { local Pawn P; P = Pawn(Owner); if ( (P == None) || (P.Controller == None) ) { Destroy(); return; } if ( (P.Controller.PlayerReplicationInfo != None) && (P.Controller.PlayerReplicationInfo.HasFlag != None) ) DeltaTime *= 2; P.Controller.Adrenaline -= AdrenalineCost*DeltaTime/Duration; if (P.Controller.Adrenaline <= 0.0) { P.Controller.Adrenaline = 0.0; Destroy(); } } defaultproperties { AdrenalineCost=100.000000 Duration=30.000000 ActivateSound=Sound'GameSounds.Combo.ComboActivated' ActivationEffectClass=Class'XEffects.ComboActivation' } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |