@page "/admin/tilemaps/tiles/edit" @model TileMaps.TileEditModel @using DataServer.Data.Entities @{ ViewData["Title"] = Model.Tile.Id == 0 ? "New Tile Definition" : $"Edit Tile Definition: {Model.Tile.Name ?? $"Frame {Model.Tile.FrameIndex}"}"; var sheet = Model.Sheet; var frameIndex = Model.Tile.FrameIndex; var cols = sheet.Columns; var col = cols > 0 ? frameIndex % cols : 0; var row = cols > 0 ? frameIndex / cols : 0; var imageUrl = sheet.CdnPath; if (!string.IsNullOrEmpty(imageUrl)) { if (!imageUrl.StartsWith("http")) { var baseUrl = Model.CdnBaseUrl.TrimEnd('/'); if (!baseUrl.EndsWith("/downloads")) { baseUrl += "/downloads"; } imageUrl = $"{baseUrl}/{imageUrl.TrimStart('/')}"; } } }
← Back to TileMap Sheet

@ViewData["Title"]

@if (!string.IsNullOrEmpty(Model.Message)) {
@Model.Message
}
@Html.AntiForgeryToken()

Tile Preview

Sheet: @sheet.Name
Frame: @frameIndex

Tile Properties

Buckets

Assign this tile to one or more buckets.

3x3 Neighbor Mask Helper

Click neighbors to mark floor (1) or empty/wall (0). Bit order is N then clockwise (N, NE, E, SE, S, SW, W, NW).

Tile
8-bit: 00000000 (0)
4-bit (N,E,S,W): 0000 (0)
Suggested Bucket: None
@foreach (var b in Model.AllBuckets) { } @if (!Model.AllBuckets.Any()) {
No buckets defined yet.
}
Cancel
@section Scripts { }