1
0
mirror of https://github.com/shiroikitsu8/Bayshore_6r_legacy.git synced 2024-12-03 03:27:21 +01:00

Revert "fix something"

This reverts commit eea78eded3.
This commit is contained in:
ghkkk090 2022-07-30 18:43:12 +07:00
parent eea78eded3
commit 324edaff4a

View File

@ -405,12 +405,6 @@ export default class GameModule extends Module {
case wm.wm.protobuf.GameMode.MODE_VS_BATTLE: case wm.wm.protobuf.GameMode.MODE_VS_BATTLE:
{ {
let saveEx: any = {}; let saveEx: any = {};
let starSubtraction = body.vsResult!.vsStarCount! - car!.vsStarCount!;
let TriMedSubtraction = body.vsResult!.vsTripleStarMedals! - car!.vsTripleStarMedals!;
let DouMedSubtraction = body.vsResult!.vsDoubleStarMedals! - car!.vsDoubleStarMedals!;
let SinMedSubtraction = body.vsResult!.vsSingleStarMedals! - car!.vsSingleStarMedals!;
let PlaMedSubtraction = body.vsResult!.vsPlainMedals! - car!.vsPlainMedals!;
if(starSubtraction < 4 && TriMedSubtraction < 2 && DouMedSubtraction < 2 && SinMedSubtraction < 2 && PlaMedSubtraction < 2){
if(body.vsResult?.vsPlayCount !== null && body.vsResult?.vsPlayCount !== undefined){ if(body.vsResult?.vsPlayCount !== null && body.vsResult?.vsPlayCount !== undefined){
saveEx.vsPlayCount = body.vsResult?.vsPlayCount!; saveEx.vsPlayCount = body.vsResult?.vsPlayCount!;
} }
@ -472,7 +466,6 @@ export default class GameModule extends Module {
}, },
data: saveEx data: saveEx
}); });
}
break; break;
} }
} }
@ -508,14 +501,6 @@ export default class GameModule extends Module {
} }
} }
let odoSubtraction = body.odometer! - car!.odometer!;
let odometers = 0;
if(odoSubtraction <= 50){
odometers = body.odometer!
}
else{
odometers = car!.odometer!
}
// Update car // Update car
await prisma.car.update({ await prisma.car.update({
where: { where: {
@ -524,7 +509,7 @@ export default class GameModule extends Module {
data: { data: {
aura: body.car!.aura!, aura: body.car!.aura!,
auraMotif: body.car!.auraMotif!, auraMotif: body.car!.auraMotif!,
odometer: odometers, odometer: body.odometer,
playCount: body.playCount, playCount: body.playCount,
level: body.car!.level!, level: body.car!.level!,
title: body.car!.title!, title: body.car!.title!,