Test: gangwar kill mstg

This commit is contained in:
Fabian
2021-04-29 19:24:36 +02:00
parent 3bf0f82abb
commit 6537e0551c
5 changed files with 19 additions and 31 deletions

View File

@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
@@ -31,6 +31,8 @@ namespace ReallifeGamemode.Server.Gangwar
public Player[] playerInGangwar { get; set; }
public int timerCount;
private const int GANGWAR_TOTAL_TIME = 900;
public Turf(int TurfID, string TurfName, int color, string Owner, int value, int maxValue, bool surplus)
{
this.TurfID = TurfID;
@@ -142,7 +144,7 @@ namespace ReallifeGamemode.Server.Gangwar
continue;
}
gangwarPlayer.TriggerEvent("GangwarScore", this.Attacker, this.Owner, this.Att_Score, this.Def_Score, 900 - timerCount);
gangwarPlayer.TriggerEvent("GangwarScore", this.Attacker, this.Owner, this.Att_Score, this.Def_Score, GANGWAR_TOTAL_TIME - timerCount);
}
/*if (this.Att_Score >= 200)
{
@@ -153,7 +155,7 @@ namespace ReallifeGamemode.Server.Gangwar
this.takeOver(this.Owner);
}*/
timerCount += 1;
if (timerCount >= 900) //change to 900 (seconds) before release for testing reasons change to whatever you like
if (timerCount >= GANGWAR_TOTAL_TIME)
{
if (this.Att_Score > this.Def_Score)
{
@@ -312,6 +314,7 @@ namespace ReallifeGamemode.Server.Gangwar
c.TriggerEvent("CLIENT:setAttackBlip", false, TurfID);
c.ResetData("inGangWar");
c.ResetData("GotInsideOfTurf");
c.TriggerEvent("resetKillcounter");
}
this.playerInGangwar = null;
this.status = "conquered";