forked from MrOkiDoki/BattleBit-Community-Server-API
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCSGO.cs
More file actions
40 lines (34 loc) · 966 Bytes
/
CSGO.cs
File metadata and controls
40 lines (34 loc) · 966 Bytes
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using BattleBitAPI.Common;
namespace CommunityServerAPI;
public class Csgo : GameMode
{
public Csgo(MyGameServer r) : base(r)
{
Name = "CSGO";
}
public override void Init()
{
R.ServerSettings.PlayerCollision = true;
R.ServerSettings.FriendlyFireEnabled = true;
if (R.Gamemode != "Rush")
{
// dunno
}
}
//Buy system maybe
public override OnPlayerKillArguments<MyPlayer> OnAPlayerDownedAnotherPlayer(OnPlayerKillArguments<MyPlayer> args)
{
var victim = args.Victim;
var killer = args.Killer;
victim.Modifications.CanDeploy = false;
victim.Modifications.CanSpectate = false;
victim.Kill();
return base.OnAPlayerDownedAnotherPlayer(args);
}
public override void Reset()
{
R.ServerSettings.PlayerCollision = false;
R.ServerSettings.FriendlyFireEnabled = false;
base.Reset();
}
}