1
0
mirror of synced 2024-12-04 19:17:58 +01:00

Merge pull request #63 from shiroikitsu8/master

fix wrong value
This commit is contained in:
Luna 2023-02-21 12:04:06 +00:00 committed by GitHub
commit afb79ae638
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -147,7 +147,7 @@ export async function getOpponentsTarget(carId: number, registeredargetAvailable
} }
// Randomize it 5 times // Randomize it 5 times
while(randomArray.length < 5) while(randomArray.length < maxNumber)
{ {
// Pick random car Id // Pick random car Id
random = Math.floor(Math.random() * opponentTargetCount + 0.9); random = Math.floor(Math.random() * opponentTargetCount + 0.9);