Fix subtraction
This commit is contained in:
@@ -43,7 +43,6 @@ export default function factionInteraction(globalData: IGlobalData) {
|
|||||||
|
|
||||||
});
|
});
|
||||||
});*/
|
});*/
|
||||||
|
|
||||||
mp.events.add("showFactionInteractionLSPD", (userFactionId, isDuty, userFactionName, isFactionLeader) => {
|
mp.events.add("showFactionInteractionLSPD", (userFactionId, isDuty, userFactionName, isFactionLeader) => {
|
||||||
//LSPD
|
//LSPD
|
||||||
let ticketTaskMenuLSPD;
|
let ticketTaskMenuLSPD;
|
||||||
@@ -527,10 +526,10 @@ export default function factionInteraction(globalData: IGlobalData) {
|
|||||||
var currentDate = new Date();
|
var currentDate = new Date();
|
||||||
|
|
||||||
if (deadRespawned == false) {
|
if (deadRespawned == false) {
|
||||||
timeLeft = Math.round(Math.abs(deathTime - 30 - Math.floor(currentDate.getTime() / 1000)));
|
timeLeft = Math.round(Math.abs(Math.floor(currentDate.getTime() / 1000) - deathTime - 30));
|
||||||
if (timeLeft < 1) mp.events.call("cutMedicEarnings");
|
if (timeLeft < 1) mp.events.call("cutMedicEarnings");
|
||||||
} else {
|
} else {
|
||||||
timeLeft = Math.round(Math.abs(deathTime - 60 - Math.floor(currentDate.getTime() / 1000)));
|
timeLeft = Math.round(Math.abs(Math.floor(currentDate.getTime() / 1000) - deathTime - 60));
|
||||||
if (timeLeft < 1) mp.events.call("destroyMedicTaskCheckpoint");
|
if (timeLeft < 1) mp.events.call("destroyMedicTaskCheckpoint");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user