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

Merge pull request #37 from ghkkk090/master

fix ghost stamp getting reset after play
This commit is contained in:
Luna 2022-08-28 13:55:40 +01:00 committed by GitHub
commit 3b3e5be2bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 8 deletions

View File

@ -60,8 +60,6 @@ model Car {
carId Int @id @default(autoincrement())
name String
manufacturer Int
regionId Int @default(0)
country String @default("JPN")
model Int
visualModel Int
customColor Int @default(0)
@ -88,6 +86,8 @@ model Car {
rivalMarker Int @default(0)
lastPlayedAt Int @default(0)
aura Int @default(0)
regionId Int @default(0)
country String @default("JPN")
// This is more data about the car
tuningPoints Int @default(0)

View File

@ -17,9 +17,10 @@ export async function sendStamp(body: wm.protobuf.SaveGameResultRequest)
if(rgResult)
{
// Stamp must bigger than 0
if(rgResult.rgStamp === 0)
let rgStamp = rgResult.rgStamp;
if(rgStamp === 0)
{
rgResult.rgStamp = 1;
rgStamp = 1;
}
// Get the area
@ -58,7 +59,7 @@ export async function sendStamp(body: wm.protobuf.SaveGameResultRequest)
let dataChallenger: any = {
carId: rgResult.opponents![i].carId,
challengerCarId: body.carId,
stamp: rgResult.rgStamp,
stamp: rgStamp,
result: rgResult.opponents![i].result,
area: area,
lastPlayedAt: date
@ -110,9 +111,10 @@ export async function shuttleReturnStamp(body: wm.protobuf.SaveGameResultRequest
if(rgResult)
{
// Stamp must bigger than 0
if(rgResult.rgStamp === 0)
let rgStamp = rgResult.rgStamp;
if(rgStamp === 0)
{
rgResult.rgStamp = 1;
rgStamp = 1;
}
// Get the area
@ -190,7 +192,7 @@ export async function shuttleReturnStamp(body: wm.protobuf.SaveGameResultRequest
let dataChallenger: any = {
carId: rgResult.opponents![i].carId,
challengerCarId: body.carId,
stamp: rgResult.rgStamp,
stamp: rgStamp,
result: rgResult.opponents![i].result,
area: area,
lastPlayedAt: date