infinite map
This commit is contained in:
parent
7213318838
commit
461a9139c2
1 changed files with 101 additions and 69 deletions
|
|
@ -1,3 +1,9 @@
|
|||
using TanksServer.GameLogic;
|
||||
|
||||
namespace TanksServer.Models;
|
||||
|
||||
internal readonly record struct FloatPosition(double X, double Y);
|
||||
internal readonly struct FloatPosition(double x, double y)
|
||||
{
|
||||
public double X { get; } = (x + MapService.PixelsPerRow) % MapService.PixelsPerRow;
|
||||
public double Y { get; } = (y + MapService.PixelsPerColumn) % MapService.PixelsPerColumn;
|
||||
}
|
||||
Reference in a new issue