poe2-bot/src/Nexus.Core/WalkabilitySnapshot.cs
2026-03-06 14:37:05 -05:00

15 lines
356 B
C#

namespace Nexus.Core;
public record WalkabilitySnapshot
{
public int Width { get; init; }
public int Height { get; init; }
public byte[] Data { get; init; } = [];
public bool IsWalkable(int x, int y)
{
if (x < 0 || x >= Width || y < 0 || y >= Height)
return false;
return Data[y * Width + x] != 0;
}
}