Gangwar Fix #7
This commit is contained in:
@@ -557,6 +557,18 @@
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
mp.events.add('CLIENT:Turf_Conquered', (jsonId, jsonStatus, jsonOwner) => {
|
||||||
|
var id = JSON.parse(jsonId);
|
||||||
|
var status = JSON.parse(jsonStatus);
|
||||||
|
var owner = JSON.parse(jsonOwner);
|
||||||
|
|
||||||
|
gangturfs.forEach(function (turf) {
|
||||||
|
if (turf.id == id) {
|
||||||
|
turf.updateArea(status, owner);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
mp.events.add('CLIENT:setAttackBlip', (bool, id) => {
|
mp.events.add('CLIENT:setAttackBlip', (bool, id) => {
|
||||||
gangturfs.forEach(function (turf) {
|
gangturfs.forEach(function (turf) {
|
||||||
if (turf.id == id) {
|
if (turf.id == id) {
|
||||||
|
|||||||
@@ -283,6 +283,9 @@ namespace ReallifeGamemode.Server.Gangwar
|
|||||||
c.ResetData("GotInsideOfTurf");
|
c.ResetData("GotInsideOfTurf");
|
||||||
}
|
}
|
||||||
this.playerInGangwar = null;
|
this.playerInGangwar = null;
|
||||||
|
this.status = "conquered";
|
||||||
|
|
||||||
|
NAPI.ClientEvent.TriggerClientEventForAll("CLIENT:Turf_Conquered", JsonConvert.SerializeObject(this.TurfID), JsonConvert.SerializeObject(this.status), JsonConvert.SerializeObject(this.Owner));
|
||||||
Gangwar.loadTurfs();
|
Gangwar.loadTurfs();
|
||||||
Gangwar.loadTurfs_ToAllPlayers();
|
Gangwar.loadTurfs_ToAllPlayers();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user