302 public int[]
floatVs =
new int[10] { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
308 public float[]
floatYs =
new float[10] { 0f, 1f, 2f, 3f, 4f, 5f, 6f, 7f, 8f, 9f };
340 protected RaycastHit2D[]
rays =
new RaycastHit2D[1];
524 for (
int i = 0; i < 256; i++)
566 subtleHighlightArea = EMono.scene.actionMode.AreaHihlight != 0 && (EMono.scene.actionMode.AreaHihlight == AreaHighlightMode.Build || EMono.scene.actionMode.AreaHihlight !=
AreaHighlightMode.Edit);
584 fogBounds = (EMono._map.config.forceHideOutbounds && (!EMono.debug.godBuild || !
buildMode)) || (EMono.core.config.game.dontRenderOutsideMap && !
buildMode);
612 Fov.nonGradientMod = profile.
global.fovModNonGradient;
620 for (
int i = 0; i <
floatYs.Length; i++)
699 noRoofMode = EMono.game.config.noRoof || screen.focusOption !=
null;
720 currentRoom.data.visited =
true;
724 room.data.visited =
true;
757 Vector3Int vector3Int =
screen.
grid.WorldToCell(mposWorld);
759 mz = vector3Int.x - 1;
764 TestPoint.x =
mx + num3;
765 TestPoint.z =
mz - num3;
769 Physics2D.SyncTransforms();
770 if (Physics2D.RaycastNonAlloc(mposWorld, Vector2.zero,
rays) > 0)
776 TestPoint.x =
mx + num3 - 1;
777 TestPoint.z =
mz - num3;
781 Physics2D.SyncTransforms();
782 if (Physics2D.RaycastNonAlloc(mposWorld, Vector2.zero,
rays) > 0)
788 TestPoint.x =
mx + num3;
789 TestPoint.z =
mz - num3 + 1;
793 Physics2D.SyncTransforms();
794 if (Physics2D.RaycastNonAlloc(mposWorld, Vector2.zero,
rays) > 0)
802 bool flag2 = EMono._zone.UseFog && !
EMono.
scene.
bg.wall;
807 cx = screen.scrollX - screen.scrollY +
x - (
z + 1) / 2;
808 cz = screen.scrollY + screen.scrollX +
x +
z / 2;
813 param.z = 1000f + param.x * screen.tileWeight.x + param.y * screen.tileWeight.z + (float)
z *
edgeBlockFix.z;
868 int valueOrDefault = (this.room?.
lot?.
idBGM).GetValueOrDefault();
869 if (valueOrDefault == 0)
875 BGMData data =
EMono.
Sound.plLot.list[0].data;
876 if ((
object)data !=
null && data.id == valueOrDefault)
888 SoundManager.bgmVolumeMod = ((!LayerDrama.maxBGMVolume && !EMono._map.IsIndoor && this.room !=
null && !this.room.data.atrium && this.room.
HasRoof) ? (-0.6f) : 0f);
921 this.room = this.cell.
room;
941 floorDir = this.cell.sourceObj.snowTile - 1;
961 light = (this.cell.pcSync ? this.cell.light : (this.cell.light / 3 * 2));
995 liquidLv = (param.liquidLv = ((!flag && !
isUnderwater) ? (((this.cell.
liquidLv +
this.cell._bridge != 0) ?
this.cell.sourceBridge.tileType.LiquidLV :
sourceFloor.tileType.LiquidLV) * 10) : 0));
1005 if (effect !=
null && effect.
IsFire)
1015 if (this.room !=
null)
1017 this.room.lot.sync =
true;
1028 if ((this.room !=
null && this.room.
lot ==
currentLot) || flag2)
1047 param.color = (
blockLight = (int)(
blockLight * 50f) * 262144 + ((this.cell.lightR >= 64) ? 63 : this.cell.
lightR) * 4096 + ((this.cell.lightG >= 64) ? 63 : this.cell.
lightG) * 64 + ((this.cell.lightB >= 64) ? 63 : this.cell.
lightB));
1065 bool num = this.room !=
null && sourceBlock.tileType.CastShadowSelf && !this.cell.
hasDoor;
1066 bool flag3 = this.room !=
null &&
showRoof && this.room.lot.idRoofStyle != 0 && !this.room.data.atrium && !
sourceBlock.tileType.Invisible;
1067 if (flag3 && this.cell.
hasDoor &&
this.cell.IsLotEdge)
1071 if (num || !
isSeen || flag3)
1085 param.y += 0.01f *
floatY;
1093 param.x += anime2.
v.x;
1094 param.y += anime2.
v.y;
1095 param.z += anime2.
v.z;
1112 param.dir = this.cell._roofBlockDir % 4;
1122 param.tile = row.
_tiles[param.dir % row.
_tiles.Length];
1130 if (dir == 0 || dir == 2)
1147 if (dir == 1 || dir == 2)
1170 param.halfBlockColor = ((_sourceBlock.sourceAutoFloor.colorMod == 0) ? 104025 :
GetColorInt(ref row2.
matColor,
_sourceBlock.sourceAutoFloor.colorMod));
1176 param.tile = row.
_tiles[param.dir % row.
_tiles.Length];
1181 int shadow2 = shadowPref.
shadow;
1186 param.tile = row.
_tiles[param.dir % row.
_tiles.Length];
1206 param.matColor = 104025f;
1209 param.y = (float)(
cz -
cx) * screen.tileAlign.y + (float)(
int)this.cell.bridgeHeight * _heightMod.y +
ugFixBridgeBottom.x;
1210 param.z = 1000f + param.x * screen.tileWeight.x + param.y * screen.tileWeight.z + (float)(
int)this.cell.bridgeHeight *
_heightMod.z;
1232 float num2 = (float)(
int)this.cell.TopHeight *
_heightMod.y;
1237 param.z += ugFix.z +
slopeFixZ * (float)i;
1279 if (this.cell.
effect !=
null)
1287 param.mat = defaultMaterial;
1295 if (sourceEffect2.
anime.Length != 0)
1297 if (sourceEffect2.
anime.Length > 2)
1299 float num3 = Time.realtimeSinceStartup * 1000f / (float)sourceEffect2.
anime[1] % (
float)sourceEffect2.
anime[2];
1300 if (!(num3 >= (
float)sourceEffect2.
anime[0]))
1307 float num4 = Time.realtimeSinceStartup * 1000f / (float)sourceEffect2.
anime[1] % (
float)sourceEffect2.
anime[0];
1322 if (this.cell.
critter !=
null)
1325 int snowTile = critter.
tile;
1355 param.x += anime4.
v.x;
1356 param.y += anime4.
v.y;
1357 param.z += anime4.
v.z;
1360 if (this.cell.
obj != 0 && !
this.cell.sourceObj.renderData.SkipOnMap)
1366 param.mat = this.cell.
matObj;
1372 param.y += 0.01f *
floatY;
1375 liquidLv = TileType.FloorWaterShallow.LiquidLV * 10;
1422 param.tile = sourceObj.
_tiles[this.cell.blockDir % sourceObj.
_tiles.Length];
1426 param.tile = sourceObj.
_tiles[this.cell.objDir % sourceObj.
_tiles.Length];
1430 param.tile += ((param.tile > 0f) ? 1 : (-1)) * 3000000;
1434 param.y += sourceObj.
pref.
y;
1435 param.z += sourceObj.
pref.
z;
1494 param.matColor = 104025f;
1521 param.tile = defBlock.
_tiles[this.cell.blockDir % defBlock.
_tiles.Length];
1522 if (defBlock.
id != 1)
1528 param.matColor = 104025f;
1534 param.z += ugFix.z +
slopeFixZ * (float)j;
1548 if (!isWater && (this.cell.
Front.
sourceFloor.tileType.IsWater ||
this.cell.Right.sourceFloor.tileType.IsWater) && this.cell.sourceBlock.tileType.RenderWaterBlock && !flag)
1561 num7 = row3.
_tiles[this.cell.blockDir % row3.
_tiles.Length];
1563 if (((this.cell.
Front.
shore / 12) & 1) == 0 && this.cell.
Front.
sourceFloor.tileType.IsWater &&
this.cell.Front.height <=
height &&
this.cell.Front.sourceBlock.tileType.RenderWaterBlock)
1565 param.y = (float)(
cz -
cx) * screen.tileAlign.y - (this.cell.Front.sourceFloor.tileType.IsDeepWater ? 0.6f : 0.4f) + (
float)(int)this.cell.
Front.
height *
_heightMod.y;
1567 param.
tile = num7 + ((!
this.cell.Front.sourceFloor.tileType.IsDeepWater) ? 3000000 : 0);
1570 if (((this.cell.
Right.
shore / 12) & 8) == 0 && this.cell.
Right.
sourceFloor.tileType.IsWater &&
this.cell.Right.height <=
height &&
this.cell.Right.sourceBlock.tileType.RenderWaterBlock)
1572 param.y = (float)(
cz -
cx) * screen.tileAlign.y - (this.cell.Right.sourceFloor.tileType.IsDeepWater ? 0.6f : 0.4f) + (
float)(int)this.cell.
Right.
height *
_heightMod.y;
1574 param.
tile = num7 + ((!
this.cell.Right.sourceFloor.tileType.IsDeepWater) ? 3000000 : 0);
1582 param.matColor = 104025f;
1606 param.tile = defBlock2.
_tiles[this.cell.blockDir % defBlock2.
_tiles.Length];
1607 if (defBlock2.
id != 1)
1613 param.matColor = 104025f;
1618 param.z += ugFix.z +
slopeFixZ * (float)k;
1635 floorLight2 = (int)(
floorLight2 * 50f) * 262144 + ((this.cell.lightR >= 64) ? 63 : this.cell.
lightR) * 4096 + ((this.cell.lightG >= 64) ? 63 : this.cell.
lightG) * 64 + ((this.cell.lightB >= 64) ? 63 : this.cell.
lightB);
1644 if (isWater && flag)
1646 param.y -= 0.01f *
floatY;
1675 if (!this.cell.
Right.
IsSnowTile &&
this.cell.Right.topHeight ==
this.cell.topHeight)
1679 if (!this.cell.
Front.
IsSnowTile &&
this.cell.Front.topHeight ==
this.cell.topHeight)
1685 param.tile = 448 + num8 + 12;
1697 param.tile = 448 + this.cell.shadow + 8 + (this.cell.HasFence ? 4 : 0);
1721 if (
back.sourceBlock.transition[0] != -1 &&
back.isSeen && !
back.hasDoor)
1738 if (
back.sourceBlock.transition[0] != -1 &&
back.isSeen && !
back.hasDoor)
1756 if (this.cell.
autotile != 0 &&
sourceFloor.autotile != 0 && (!
hasBridge ||
this.cell.bridgeHeight -
this.cell.height > 3) && !
this.cell.skipRender && num8 == 0)
1776 int num10 = this.cell.shore / num9;
1777 int num11 = this.cell.shore % num9;
1779 if (this.cell.
shore != 0)
1781 Cell cell = ((((uint)num10 & (
true ? 1u : 0u)) != 0) ? this.cell.Back : ((((uint)num10 & 2u) != 0) ? this.cell.
Right : ((((uint)num10 & 4u) != 0) ? this.cell.Front : this.cell.
Left)));
1784 cell = ((((uint)num10 & 8u) != 0) ? this.cell.
Left : ((((uint)num10 & 4u) != 0) ? this.cell.Front : ((((uint)num10 & 2u) != 0) ? this.cell.
Right :
this.cell.
Back)));
1810 param.tile = (24 + num11 / 2) * 32 + num11 % 2 * 16 + num10;
1814 if (this.cell.
Back.
isShoreSand && ((uint)(
this.cell.Back.shore / num9) & 8u) != 0 && this.cell.Left.isShoreSand && ((uint)(this.cell.
Left.
shore / num9) & (
true ? 1u : 0u)) != 0)
1821 if (this.cell.
Back.
isShoreSand && ((uint)(
this.cell.Back.shore / num9) & 2u) != 0 &&
this.cell.Right.isShoreSand && ((uint)(
this.cell.Right.shore / num9) & (
true ? 1u : 0u)) != 0)
1828 if (this.cell.
Front.
isShoreSand && ((uint)(
this.cell.Front.shore / num9) & 2u) != 0 &&
this.cell.Right.isShoreSand && ((uint)(
this.cell.Right.shore / num9) & 4u) != 0)
1835 if (this.cell.
Front.
isShoreSand && ((uint)(
this.cell.Front.shore / num9) & 8u) != 0 &&
this.cell.Left.isShoreSand && ((uint)(
this.cell.Left.shore / num9) & 4u) != 0)
1842 if (this.cell.
_bridge != 0 &&
this.cell.isBridgeEdge &&
this.cell.bridgePillar !=
byte.MaxValue)
1861 if (((uint)num10 & (
true ? 1u : 0u)) != 0)
1863 if (((uint)num10 & 8u) != 0)
1865 if ((num10 & 2) == 0 && (num10 & 4) == 0)
1871 if (((uint)num10 & 2u) != 0)
1873 if ((num10 & 8) == 0 && (num10 & 4) == 0)
1880 if (((uint)num10 & 4u) != 0)
1882 if (((uint)num10 & 8u) != 0)
1884 if ((num10 & 2) == 0 && (num10 & 1) == 0)
1890 if (((uint)num10 & 2u) != 0)
1892 if ((num10 & 8) == 0 && (num10 & 1) == 0)
1901 if (!this.cell.
Front.
sourceFloor.tileType.IsWater && !
this.cell.Front.isDeck)
1905 if (!this.cell.
Right.
sourceFloor.tileType.IsWater && !
this.cell.Right.isDeck)
1913 if (!this.cell.
Back.
sourceFloor.tileType.IsWater && !
this.cell.Back.isDeck)
1919 if (((uint)(this.cell.
shore / num9) & (
true ? 1u : 0u)) != 0)
1951 if (!this.cell.
Left.
sourceFloor.tileType.IsWater && !
this.cell.Left.isDeck)
1957 if (((uint)(this.cell.
shore / num9) & 8u) != 0)
1992 param.y += 0.01f *
floatY;
2011 param.y = (float)(
cz -
cx) * screen.tileAlign.y + (float)(
int)this.cell.bridgeHeight *
_heightMod.y;
2012 param.z = 1000f + param.x * screen.tileWeight.x + param.y * screen.tileWeight.z + (float)(
int)this.cell.bridgeHeight *
_heightMod.z;
2015 param.y += 0.01f *
floatY;
2040 if (this.cell.
shadow != 0)
2044 param.tile = 448 + this.cell.shadow + 8 + (this.cell.HasFence ? 4 : 0);
2065 if (this.cell.
isBridgeEdge &&
this.cell.bridgeHeight -
this.cell.height >= 3 &&
this.cell.bridgePillar !=
byte.MaxValue && !
noSlopMode)
2082 param.tile = row4.
_tiles[0] + ((num13 == 2) ? 32 : 0);
2089 param.tile = row4.
_tiles[0] + 32;
2094 for (
int l = 0; l < num13; l++)
2114 if (this.cell.
_block != 0 && !
this.cell.hasDoor)
2144 this.room = this.room ?? this.cell.Front.room ?? this.cell.Right.room ?? this.cell.
FrontRight.
room;
2157 else if (this.tileType.
IsFullBlock &&
this.room !=
this.cell.FrontRight.room && (
this.cell.FrontRight.room ==
currentRoom || (
this.room?.lot !=
currentLot &&
this.cell.FrontRight.room?.lot ==
currentLot)))
2164 this.room = this.room ?? this.cell.Front.room ?? this.cell.Right.room ?? this.cell.
FrontRight.
room;
2188 if (this.room !=
null)
2201 int num15 = ((this.room.data.maxHeight == 0) ? 2 : this.room.
data.
maxHeight);
2202 roomHeight = EMono.setting.render.roomHeightMod * (float)((this.room.
lot.
height < num15) ? this.room.lot.height : num15) + 0.01f * (
float)this.room.
lot.
heightFix;
2221 if (this.cell.
Back.
IsRoomEdge &&
this.cell.Right.IsRoomEdge &&
this.cell.Back.room ==
null &&
this.cell.Right.room ==
null &&
this.cell.Right.Front.room?.lot ==
this.room?.lot)
2226 else if (this.cell.
Back.
room !=
null &&
this.cell.Back.room.
lot == (
this.cell.Front.room ??
this.cell.Right.room)?.lot)
2237 this.room = this.room ?? this.cell.Front.room ?? this.cell.Right.room ?? this.cell.
FrontRight.
room;
2273 param.color = (int)(50f *
blockLight) * 262144;
2274 param.matColor = 104025f;
2316 if (this.cell.
Things.Count > 0)
2338 if (!invisible &&
room !=
null)
2362 room = this.cell.Right.room ?? this.cell.
room;
2367 if (!invisible &&
room !=
null)
2403 bool flag8 = blockDir == 1 ||
_lowblock || flag7;
2404 bool flag9 = blockDir == 0 ||
_lowblock || flag7;
2411 if (!this.cell.
IsRoomEdge || (
this.cell.Front.room !=
this.cell.room &&
this.cell.FrontRight.room !=
this.cell.room))
2425 if (!this.cell.
IsRoomEdge || (
this.cell.Right.room !=
this.cell.room &&
this.cell.FrontRight.room !=
this.cell.room))
2436 if (blockDir == 0 || blockDir == 2)
2439 Room room2 = this.cell.Front.room ?? this.cell.
room;
2440 if (room2 !=
null && this.tileType.
IsWall)
2442 if (room2.
lot.
idDeco != 0 && !
this.cell.hasDoor)
2462 if (blockDir == 2 &&
left.sourceBlock.tileType.IsWallOrFence && !
this.cell.crossWall)
2465 param.mat =
left.matBlock;
2500 param.tile =
_sourceBlock._tiles[0] + ((flag8 && flag9 && this.tileType.UseLowBlock && !flag7) ? 32 : 0) + (this.tileType.IsFence ? 32 : 64);
2510 if (!flag8 && !
showRoof && this.cell.
Left.
HasWallOrFence &&
this.cell.Left.blockDir != 0 && !
this.cell.Left.isToggleWallPillar)
2513 param.tile =
_sourceBlock._tiles[0] + ((flag8 && this.tileType.UseLowBlock && !flag7) ? 32 : 0) + (this.tileType.IsFence ? 32 : 64);
2530 param.tile =
_sourceBlock._tiles[0] + ((flag8 && this.tileType.UseLowBlock && !flag7) ? 32 : 0) + (this.tileType.IsFence ? 32 : 64);
2545 if (blockDir == 1 || blockDir == 2)
2550 Room room3 = this.cell.Right.room ?? this.cell.
room;
2551 if (room3 !=
null && this.tileType.
IsWall)
2553 if (room3.
lot.
idDeco != 0 && !
this.cell.hasDoor)
2572 if (blockDir == 2 && this.cell.
room ==
null &&
this.cell.Right.room !=
null)
2586 int num19 = ((room4.data.maxHeight == 0) ? 2 : room4.
data.
maxHeight);
2587 roomHeight = EMono.setting.render.roomHeightMod * (float)((room4.
lot.
height < num19) ? room4.lot.height : num19) + 0.01f * (
float)room4.
lot.
heightFix;
2591 if (blockDir == 2 && back2.
sourceBlock.tileType.IsWallOrFence && !
this.cell.crossWall)
2630 param.tile =
_sourceBlock._tiles[0] + ((flag9 && this.tileType.UseLowBlock && !flag7) ? 32 : 0) + (this.tileType.IsFence ? 32 : 64);
2652 param.halfBlockColor = ((_sourceBlock.sourceAutoFloor.colorMod == 0) ? 104025 :
GetColorInt(ref
matBlock.matColor,
_sourceBlock.sourceAutoFloor.colorMod));
2660 int num20 = this.cell.objDir + ((this.cell.objDir >= 7) ? this.cell.
objDir : 0) + 1;
2671 int shadow4 = shadowPref2.
shadow;
2692 if (this.cell.
room !=
null || !
this.cell.IsRoomEdge || !
showRoof)
2696 if (this.cell.
_block == 0 || !
this.cell.sourceBlock.tileType.RepeatBlock)
2699 if (obj ==
null || !obj.
HasRoof)
2707 if (!
showRoof || !
roof || this.cell.
room ==
null ||
this.cell.Front.room ==
null ||
this.cell.Right.room ==
null)
2722 freePos.x = (freePos.y = (freePos.z = 0f));
2726 param.x += rampFix.x;
2727 param.y += rampFix.y;
2728 param.z += rampFix.z;
2729 freePos.x += rampFix.x;
2730 freePos.y += rampFix.y;
2731 freePos.z += rampFix.z;
2733 param.y += (flag ? 0f : ((this.cell._bridge != 0) ? this.cell.
sourceBridge.tileType.FloorHeight :
sourceFloor.tileType.FloorHeight));
2741 liquidLv = TileType.FloorWaterShallow.LiquidLV * 10;
2751 bool flag10 =
false;
2753 bool flag11 =
false;
2769 if (!isInstalled && t.
category.tileDummy != 0)
2773 float num27 = ((tileType.UseMountHeight && isInstalled) ? 0f : ((pref.
height < 0f) ? 0f : ((pref.height == 0f) ? 0.1f : pref.
height)));
2776 thingPos.y -= num22;
2778 shadow = thingPos.y < 0.16f && num25 < 0.16f;
2788 _actorPos.z = param.z + num26;
2789 if (this.room !=
null)
2799 _actorPos.x =
orgX + num23;
2804 if (thing?.
id != t.
id)
2811 thingPos.y -= num22;
2814 _actorPos.z -= 0.2f;
2817 _actorPos.y -= num22;
2819 _actorPos.z += renderSetting.thingZ + (float)m * -0.01f +
zSetting.mod1 *
thingPos.y;
2829 freePos.x += rampFix2.x;
2830 freePos.y += rampFix2.y;
2831 freePos.z += rampFix2.z;
2834 num25 += rampFix2.y;
2836 liquidLv -= (int)(rampFix2.y * 150f);
2851 _actorPos.x += pref.x * (float)((!t.
flipX) ? 1 : (-1));
2852 _actorPos.z += pref.
z;
2853 thingPos.z += pref.
z;
2862 thingPos.y += num27;
2863 _actorPos.x += pref.x * (float)((!t.
flipX) ? 1 : (-1));
2864 _actorPos.z += pref.
z;
2867 thingPos.z += pref.
z;
2877 thingPos.y += num27;
2878 _actorPos.x += pref.x * (float)((!t.
flipX) ? 1 : (-1));
2879 _actorPos.z += pref.
z;
2880 thingPos.z += pref.
z;
2885 float num28 = ((this.cell._bridge != 0) ?
sourceBridge.tileType.FloorHeight :
sourceFloor.tileType.FloorHeight);
2888 _actorPos.y += 0.01f *
floatY - num28;
2891 liquidLv = TileType.FloorWaterShallow.LiquidLV * 10;
2929 Room room5 = ((t.dir == 0) ? this.cell.
Back.
room :
this.cell.Left.room);
2952 _actorPos.x += t.
fx;
2953 _actorPos.y += t.
fy;
2973 _actorPos.z += -0.5f;
3014 param.tile += ((param.tile < 0f) ? (-64) : 64);
3023 _actorPos.y = EMono.pc.renderer.position.y - pref.
height;
3024 _actorPos.z = EMono.pc.renderer.position.z + 0.02f;
3035 num23 += pref.stackX * (float)((!t.
flipX) ? 1 : (-1));
3053 param.shadowFix = 0f - num25;
3054 param.color += 1310720f;
3071 if (restrainer !=
null)
3074 if (getRestrainPos !=
default(Vector3))
3078 float num30 = getRestrainPos.y + defCharaHeight - ((chara.Pref.height == 0f) ? defCharaHeight : chara.
source.pref.height);
3079 _actorPos.x = position.x + getRestrainPos.x * (float)((restrainer.
owner.
dir % 2 == 0) ? 1 : (-1));
3080 _actorPos.y = position.y + num30;
3081 _actorPos.z = position.z + getRestrainPos.z;
3086 param.shadowFix = 0f;
3095 float num31 = chara.renderer.data.size.y * 0.3f;
3100 float num32 = thingPos.y + num31;
3101 float num33 = (float)n * -0.01f;
3108 _actorPos.z += renderSetting.laydownZ + num33;
3109 param.liquidLv = ((thingPos.y == 0f &&
liquidLv > 0) ? 90 : 0);
3110 thingPos.y += num31 * 0.8f;
3120 float num34 = ((this.cell._bridge != 0) ?
sourceBridge.tileType.FloorHeight :
sourceFloor.tileType.FloorHeight);
3121 float num35 =
floatYs[chara.uid % 10] + 10f + (float)(chara.
uid % 30);
3122 orgY += 0.01f * num35 - num34;
3123 _actorPos.y += 0.01f * num35 - num34;
3124 param.shadowFix -= 0.01f * num35 - num34;
3133 float num36 = ((this.cell._bridge != 0) ?
sourceBridge.tileType.FloorHeight :
sourceFloor.tileType.FloorHeight);
3135 _actorPos.y += 0.01f *
floatY - num36;
3136 int num37 = TileType.FloorWaterShallow.LiquidLV * 10;
3137 num37 -= (int)(
floatY * 0.5f);
3138 param.liquidLv = num37;
3142 param.liquidLv -= 20;
3192 Vector3 zero = Vector3.zero;
3211 zero.x += rampFix.x;
3212 zero.y += rampFix.y;
3213 zero.z += rampFix.z;
3221 zero.x += pref.x * (float)((!tg.
flipX) ? 1 : (-1));
3254 float num4 = (tileType.UseMountHeight ? 0f : ((pref2.height == 0f) ? 0.1f : pref2.
height));
3262 zero.x += rampFix2.x;
3263 zero.y += rampFix2.y;
3264 zero.z += rampFix2.z;
3273 zero.x += pref2.stackX * (float)((!thing.
flipX) ? 1 : (-1));
3278 num4 += altitudeFix.y * (float)thing.
altitude;
3285 zero.z += renderSetting.thingZ + num + (float)i * -0.01f +
zSetting.mod1 * zero.y;
3327 int num2 = (int)(num * 50f) * 262144;
3349 num = lot.z - roofStyle.
h;
3350 num2 = lot.x - roofStyle.
w;
3351 num3 = lot.mz + 1 + roofStyle.
h;
3352 num4 = lot.mx + 1 + roofStyle.
w;
3364 num = lot.x - roofStyle.
w;
3365 num2 = lot.z - roofStyle.
h;
3366 num3 = lot.mx + 1 + roofStyle.
w;
3367 num4 = lot.mz + 1 + roofStyle.
h;
3380 num5 = ((lot.height > 1) ? 1 : 0);
3391 int num6 = num4 + (reverse ? roofStyle.w : roofStyle.
h) * 2 - num2;
3397 num7 = EMono.sources.blocks.rows.Count - 1;
3401 num8 = EMono.sources.floors.rows.Count - 1;
3406 num9 = EMono.sources.blocks.rows.Count - 1;
3409 int num10 = num6 / 2 - roofStyle.
flatW;
3410 int num11 = num6 / 2 + roofStyle.flatW + ((num6 % 2 != 0) ? 1 : 0);
3413 int num13 = ((num5 != 0) ? (-1) : 0);
3415 Vector3 vector = (lot.fullblock ? roofStyle.posFixBlock : roofStyle.
posFix);
3416 switch (roofStyle.
type)
3419 flag = num6 % 2 == 1 && roofStyle.flatW == 0;
3423 num10 = roofStyle.
flatW;
3424 num11 = num6 - roofStyle.
flatW;
3442 for (
cz = num2;
cz < num4;
cz++)
3444 for (
cx = num;
cx < num3;
cx++)
3472 int num17 = num16 - num15;
3485 num14 = ((cell.Left.room !=
null && cell.Left.room.lot == lot) ? ((
cell.
Right.
room !=
null &&
cell.
Right.
room.
lot == lot) ? 1 : ((cell.HasFullBlock && cell.Right.HasFullBlock && cell.Right.room !=
null) ? 1 : 2)) : (
cell.
Left.
HasFullBlock ? 1 : 0));
3505 num14 = ((cell.Front.room !=
null && cell.Front.room.lot == lot) ? ((
cell.
Back.
room !=
null &&
cell.
Back.
room.
lot == lot) ? 1 : (cell.Back.HasFullBlock ? 1 : 2)) : ((cell.HasFullBlock && cell.Front.HasFullBlock && cell.Front.room !=
null) ? 1 : 0));
3526 float num18 = (float)num17 *
screen.
tileAlign.y + (
float)lot.mh * _heightMod.y + lot.realHeight + roofFix.y + vector.y;
3533 param.x = (float)(
cx +
cz) * screen.tileAlign.x + roofFix.x + (float)num13 *
roofFix2.x + vector.x * (
float)(reverse ? 1 : (-1));
3534 param.y = num18 + (float)num13 *
roofFix2.y;
3537 param.snow = idRoofTile == 0 && flag3;
3538 param.shadowFix = 0f;
3560 if (idRoofTile != 0)
3563 int num20 = (reverse ? 1 : 0) + ((!flag) ? 2 : 0);
3578 param.matColor = 104025f;
3581 param.z += roofStyle.
snowZ;
3593 param.matColor = 104025f;
3595 param.x += roofStyle.
snowFix.x;
3596 param.y += roofStyle.
snowFix.y;
3597 param.z += roofStyle.snowZ + roofStyle.
snowFix.z;
3603 if (idRoofTile != 0)
3605 int num21 = ((!reverse) ? ((num14 != 0) ? 2 : 0) : ((num14 != 0) ? 1 : 3));
3608 param.shadowFix = num21 + 1;
3615 param.matColor = 104025f;
3616 param.z += roofStyle.
snowZ;
3622 param.tile += (lot.altRoof ? 8 : 0);
3625 param.shadowFix = 0f;
3650 for (
int i = 0; i < num13; i++)
3652 param.x = (float)(
cx +
cz) * screen.tileAlign.x + roofFix.x + (float)i *
roofFix2.x + vector.x * (
float)(reverse ? 1 : (-1));
3653 param.y = num18 + (float)i *
roofFix2.y;
3679 num13 += num14
switch
3695 return p * 262144 + (int)(matColor.r * 50f) * 4096 + (int)(matColor.g * 50f) * 64 + (int)(matColor.b * 50f);
3701 if (
room ==
null && dirWall != -1)
3703 if (dirWall == 0 && _cell.
Front.
room !=
null)
3706 _cell = _cell.
Front;
3711 _cell = _cell.
Right;
3719 float num2 = 1000f +
param.
x *
screen.
tileWeight.x + (
float)lot.mh * _heightMod.z + lot.realHeight * roofFix3.z + roofFix.z + roofStyle.
posFix.z;
3725 _param.x = (float)(_cx + _cz) * screen.tileAlign.x + roofFix.x + (float)h *
roofFix2.x;
3729 if (!ignoreAltitudeY ||
room !=
null)
if(item3.idFile==idFirstFile &&item3.id==idFirstTopic)
static AM_Inspect Inspect
virtual bool IsRoofEditMode(Card c=null)
static AM_ViewMap ViewMap
virtual BaseTileMap.CardIconMode cardIconMode
virtual bool ShowMaskedThings
static AM_FlagCell FlagCell
virtual byte GetTile(int index)
List< Action > actionsLateUpdate
BaseTileSelector tileSelector
virtual void RefreshWeather()
const int BlocklightToken
int GetRoofLight(Lot lot)
RenderData rendererInnerBlock
SourceFloor.Row sourceBridge
InnerMode defaultInnerMode
ScreenHighlight screenHighlight
SourceMaterial.Row matBridge
RenderData rendererFogRoomSolid
RenderData rendererWaterBlock
Vector3 waterEdgeFixShoreSand
int GetApproximateBlocklight(Cell cell)
Vector3 waterEdgeFixShore
static int GetColorInt(ref Color matColor, int p)
SceneLightProfile lightSetting
void OnActivate(BaseGameScreen _screen)
MeshPass passAutoTileWater
new BaseGameScreen screen
WallClipMode wallClipMode
float floorShadowStrength
RenderData rendererFloorMarker
GameSetting.RenderSetting renderSetting
Vector3 ugFixBridgeBottom
SourceMaterial.Row matBlock
RenderDataEffect rendererEffect
SourceBlock.Row _sourceBlock
RenderData renderFootmark
Vector3[] waterEdgeBlockFix
RenderData rendererBlockMarker
Vector3[] ambientShadowFix
RenderData rendererFogRoomBlockSolid
SourceMaterial.Row matFloor
RenderData rendererWallDeco
SourceBlock.Row sourceBlock
Vector3 waterEdgeBridgeFix
RenderData rendererFogRoomWallSolid
RenderData rendererFogFloorSolid
void SetRoofHeight(MeshPassParam _param, Cell _cell, int _cx, int _cz, int h=0, int altitude=0, int dirWall=-1, bool ignoreAltitudeY=false)
static bool forceShowHang
RenderDataObjDummy rendererObjDummy
BaseTileSelector selector
Vector3 heightModRoofBlock
NoiseLayer layerGroundLights
RenderData rendererFogBlockSolid
GameSetting.RenderSetting.ZSetting zSetting
SourceFloor.Row sourceFloor
Vector3 GetThingPosition(Card tg, Point p)
override void Draw(RenderParam p)
virtual void SetFirst(bool first, Vector3 pos)
TraitShackle GetRestrainer()
virtual CardRow sourceCard
SourceCategory.Row category
TaskDesignation designation
SourceCellEffect.Row source
static List< SourceBlock.Row > blockList
SourceBlock.Row sourceBlock
SourceMaterial.Row matBlock
SourceFloor.Row sourceFloor
SourceMaterial.Row matObj
SourceMaterial.Row matBridge
SourceFloor.Row sourceBridge
SourceMaterial.Row matFloor
SourceCellEffect.Row sourceEffect
static List< SourceMaterial.Row > matList
override bool IsAliveInCurrentZone
override bool IsDeadOrSleeping
override CardRow sourceCard
override void SetRenderParam(RenderParam p)
static GameSetting setting
static ColorProfile Colors
static SoundManager Sound
static SourceManager sources
static SourceFloor.Row sourceSnow
static SourceFloor.Row sourceSnow2
static SourceFloor.Row sourceIce
virtual void OnRenderTileMap(RenderParam p)
static Card alwaysVisible
static SourceMaterial.Row sourceSnow
static SourceMaterial.Row sourceGold
static HashSet< int > sunMap
void Add(Point point, float tile=0f, float color=0f)
void AddShadow(MeshPassParam p, ref Vector3 fix)
List< MeshBatch > batches
CinemaConfig cinemaConfig
ref Vector3 Position(int height)
Point Set(int _x, int _z)
Point Clamp(bool useBounds=false)
static void InitBytes(int a)
new void Draw(RenderParam p, int tile=0)
void Draw(RenderParam p, int tile)
void DrawRepeat(RenderParam p, int count, float size, bool skipFirst=false)
int ConvertTile(int tile)
void SetRenderParam(RenderParam p, SourceMaterial.Row mat, int dir)
SourceMaterial.Row DefaultMaterial
AnimationCurve baseBrightnessCurve
float dynamicBrightnessSpeed
AnimationCurve shadowCurveFloor
AnimationCurve dynamicBrightnessCurve2
float dynamicBrightnessLightBonus
AnimationCurve lightLimit
AnimationCurve fogBrightness
AnimationCurve dynamicBrightnessCurve
AnimationCurve shadowCurve
AnimationCurve nightRatioCurve
AnimationCurve lightModCurve
SceneGlobalProfile global
List< ISyncScreen > syncList
GameSetting.RenderSetting.MapBGSetting bg
void DrawWall(Point point, int color, bool useMarkerPass=false, float offsetZ=0f)
static ShadowData Instance
virtual bool IsSnowCovered
virtual void Draw(int x, int z, RenderParam p)
override void SetRenderParam(RenderParam p)
override CardRow sourceCard
override float FloorHeight
virtual bool IsUseBlockDir
virtual void GetMountHeight(ref Vector3 v, Point p, int d, Card target=null)
static TileTypeIllumination Illumination
static TileTypeWaterShallow FloorWaterShallow
virtual bool AlwaysShowShadow
virtual bool ForceRpeatBlock
virtual bool IsSkipLowBlock
virtual bool UseMountHeight
virtual BlockRenderMode blockRenderMode
Vector3 GetRampFix(int dir, SourcePref pref=null)
virtual Vector3 GetRestrainPos
virtual bool IgnoreLastStackHeight
virtual bool AlwaysHideOnLowWall
virtual TileType tileType
virtual bool IsChangeFloorHeight
virtual bool AlwaysLowblock
virtual bool IsUnderwater