blob: 904dc81cdd26877cfbf0936265ef541c26482ddb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
using Sandbox;
using System.Linq;
namespace MurderGame;
public class EndPhase : BasePhase
{
public override string Title => "Game over";
public int TicksElapsed;
public override void Activate()
{
base.TimeLeft = 7;
}
public override void Tick()
{
++TicksElapsed;
if (base.TimeLeft != -1 && TicksElapsed % Game.TickRate == 0 && --base.TimeLeft == 0)
{
base.NextPhase = new WaitPhase() { CountIn = false };
base.IsFinished = true;
return;
}
}
}
|