add initial implementation of LDtk importer with data models and scene builder
This commit is contained in:
30
addons/csharp_ldtk_importer/Models/LdtkData.cs
Normal file
30
addons/csharp_ldtk_importer/Models/LdtkData.cs
Normal file
@@ -0,0 +1,30 @@
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace CSharpLdtkImporter.Models;
|
||||
|
||||
public class LdtkData
|
||||
{
|
||||
[JsonPropertyName("levels")]
|
||||
public LdtkLevel[] Levels { get; set; }
|
||||
|
||||
[JsonPropertyName("defs")]
|
||||
public LdtkDefinitions Defs { get; set; }
|
||||
}
|
||||
|
||||
public class LdtkDefinitions
|
||||
{
|
||||
[JsonPropertyName("tilesets")]
|
||||
public LdtkTilesetDef[] Tilesets { get; set; }
|
||||
}
|
||||
|
||||
public class LdtkTilesetDef
|
||||
{
|
||||
[JsonPropertyName("uid")]
|
||||
public int Uid { get; set; }
|
||||
|
||||
[JsonPropertyName("relPath")]
|
||||
public string RelPath { get; set; }
|
||||
|
||||
[JsonPropertyName("tileGridSize")]
|
||||
public int TileGridSize { get; set; }
|
||||
}
|
Reference in New Issue
Block a user