better car crash
This commit is contained in:
parent
87d078a34d
commit
c5e4d1a6b9
1 changed files with 3 additions and 2 deletions
|
@ -142,7 +142,6 @@ function game() {
|
|||
playerId=Net.playerId;
|
||||
player=Net.clientPlayer;
|
||||
players=Net.getPlayersToAdd();
|
||||
players.push(new Player(0,-50,-50,"VOITURE",0,null));
|
||||
Renderer.AddPlayer(player)
|
||||
Renderer.SetPlayerId(player.id)
|
||||
|
||||
|
@ -153,6 +152,7 @@ function game() {
|
|||
players.forEach((p) => {
|
||||
Renderer.AddPlayer(p)
|
||||
});
|
||||
players.push(new Player(-1,-50,-50,"VOITURE",0,null));
|
||||
LB.ReloadAff(players, player);
|
||||
}
|
||||
}
|
||||
|
@ -172,8 +172,9 @@ function game() {
|
|||
c.Update();
|
||||
if(c.collide(player.x,player.y))
|
||||
{
|
||||
Net.died(player.id,0);
|
||||
Net.died(player.id,-1);
|
||||
player.x=-50;
|
||||
player.health=10;
|
||||
}
|
||||
});
|
||||
updateBullets(dt);
|
||||
|
|
Loading…
Reference in a new issue