player can shoot bullet (crashes game when leaving map)
This commit is contained in:
parent
dd6b0fffc1
commit
b10ccf2da8
12 changed files with 231 additions and 99 deletions
10
TanksServer/Models/Bullet.cs
Normal file
10
TanksServer/Models/Bullet.cs
Normal file
|
@ -0,0 +1,10 @@
|
|||
namespace TanksServer.Models;
|
||||
|
||||
internal sealed class Bullet(Player tankOwner, FloatPosition position, double rotation)
|
||||
{
|
||||
public Player TankOwner { get; } = tankOwner;
|
||||
|
||||
public FloatPosition Position { get; set; } = position;
|
||||
|
||||
public double Rotation { get; set; } = rotation;
|
||||
}
|
|
@ -16,4 +16,6 @@ internal sealed class Tank(Player player, FloatPosition spawnPosition)
|
|||
}
|
||||
|
||||
public FloatPosition Position { get; set; } = spawnPosition;
|
||||
|
||||
public DateTime NextShotAfter { get; set; }
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue