2using System.Collections.Generic;
58 RenderParam renderParam = base.GetRenderParam(mat, dir, point, bridgeHeight);
62 Row row = ((
id == 5) ? base.sources.blocks[mat.defBlock] :
this);
63 renderParam.tile = row.
_tiles[0];
72 public static readonly IReadOnlyDictionary<string, int>
RowMapping =
new Dictionary<string, int>
83 [
"_idRenderData"] = 9,
107 public static readonly IReadOnlyDictionary<string, string>
TypeMapping =
new Dictionary<string, string>
110 [
"alias"] =
"string",
111 [
"name_JP"] =
"string",
114 [
"reqHarvest"] =
"string[]",
116 [
"idThing"] =
"string",
117 [
"_tileType"] =
"string",
118 [
"_idRenderData"] =
"string",
121 [
"snowTile"] =
"int",
122 [
"colorMod"] =
"int",
123 [
"colorType"] =
"string",
126 [
"recipeKey"] =
"string[]",
127 [
"factory"] =
"string[]",
128 [
"components"] =
"string[]",
129 [
"defMat"] =
"string",
130 [
"category"] =
"string",
132 [
"autoFloor"] =
"string",
133 [
"concrete"] =
"bool",
134 [
"transparent"] =
"bool",
135 [
"transition"] =
"int[]",
136 [
"tag"] =
"string[]",
137 [
"soundFoot"] =
"string",
138 [
"detail_JP"] =
"string",
139 [
"detail"] =
"string"
142 public Dictionary<int, Row>
_rows =
new Dictionary<int, Row>();
247 foreach (
Row row
in rows)
255 foreach (
Row row
in rows)
263 foreach (
Row row
in rows)
272 foreach (
Row row
in rows)
281 rows.Sort((
Row r) => r.
id);
288 Cell.blockSource =
this;
289 Cell.blockList = rows;
291 foreach (
Row row2
in rows)
295 if (row ==
null && !row2.
autoFloor.IsEmpty())
297 Debug.LogWarning(
$"#source block {row2.id}/{row2.alias} has invalid floor alias '{row2.autoFloor}'");
299 row2.sourceAutoFloor = row ?? floors[40];
static int GetColorInt(ref Color matColor, int p)
override RenderParam GetRenderParam(SourceMaterial.Row mat, int dir, Point point=null, int bridgeHeight=-1)
override RenderData defaultRenderData
SourceFloor.Row sourceAutoFloor
override int GetTile(SourceMaterial.Row mat, int dir=0)
override void ValidatePref()
override IReadOnlyDictionary< string, string > GetTypeMapping()
override void BackupPref()
override void RestorePref()
override void OnAfterImportData()
override void SetRow(Row r)
static RenderData FallbackRenderData
override Row CreateRowByMapping(IReadOnlyDictionary< string, int > mapping)
TileLookup< Row > _lookup
Dictionary< int, Row > _rows
static readonly IReadOnlyDictionary< string, int > RowMapping
static readonly IReadOnlyDictionary< string, string > TypeMapping
override IReadOnlyDictionary< string, int > GetRowMapping()
static string[] GetStringArray(int id)
static string GetString(int id)
static bool GetBool(int id)
static int GetInt(int id)
static int[] GetIntArray(int id)
static TileTypeHalfBlock HalfBlock