Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //=============================================================================
- // WaveController.
- //=============================================================================
- class WaveController expands Actor;
- struct Waves
- {
- var() float WaveLength;
- var() name WaveTag;
- };
- var() Waves Wave[8];
- var() float StartTime;
- var() bool bHungarian;
- var int i;
- function BeginPlay()
- {
- i=0;
- SetTimer(StartTime, false);
- if(bHungarian)
- {
- BroadcastMessage(StartTime$ " msodperc mlva indul az els hullm");
- }
- else
- {
- BroadcastMessage(StartTime$ " seconds until the first wave starts");
- }
- }
- simulated function Timer()
- {
- local ScriptedPawn P;
- foreach Allactors(class'ScriptedPawn', P)
- {
- if(P.IsA('MPZombie'))
- {
- if(P.Tag==Wave[i].WaveTag)
- {
- if(bHungarian)
- {
- BroadcastMessage("Kvetkez hullm indul");
- }
- else
- {
- BroadcastMessage("Next wave starts now");
- }
- P.EnterWorld();
- i=i+1;
- }
- else
- {
- if(bHungarian)
- {
- BroadcastMessage("Nincs tbb hullm");
- }
- else
- {
- BroadcastMessage("No more waves");
- }
- }
- }
- }
- }
Add Comment
Please, Sign In to add comment