21 colors.TopLeftColor =
Color.
Lerp(colors.TopLeftColor, lerpColor, percent);
22 colors.TopRightColor =
Color.
Lerp(colors.TopRightColor, lerpColor, percent);
23 colors.BottomLeftColor =
Color.
Lerp(colors.BottomLeftColor, lerpColor, percent);
24 colors.BottomRightColor =
Color.
Lerp(colors.BottomRightColor, lerpColor, percent);
56 int num = (int)(120f * (1f - gfxQuality) + 40f * gfxQuality);
57 int num2 = (int)((
float)num * 0.4f);
58 int num3 = (int)((
float)num * 0.35f);
59 int num4 = (int)((
float)num * 0.3f);
65 int num5 = (int)((screenPosition.
X - vector.
X) / 16f - 1f);
66 int num6 = (int)((screenPosition.
X + (
float)screenWidth + vector.
X) / 16f) + 2;
67 int num7 = (int)((screenPosition.
Y - vector.
Y) / 16f - 1f);
68 int num8 = (int)((screenPosition.
Y + (
float)screenHeight + vector.
Y) / 16f) + 5;
69 int num9 = offScreenRange / 16;
70 int num10 = offScreenRange / 16;
75 if (num6 + num9 > maxTilesX - 4)
77 num6 = maxTilesX - num9 - 4;
83 if (num8 + num10 > maxTilesY - 4)
85 num8 = maxTilesY - num10 - 4;
91 for (
int i = num7 - num10 + screenOverdrawOffset.
Y; i < num8 + num10 - screenOverdrawOffset.
Y; i++)
93 for (
int j = num5 - num9 + screenOverdrawOffset.
X; j < num6 + num9 - screenOverdrawOffset.
X; j++)
101 ushort wall = tile.
wall;
115 if (color.
R == 0 && color.
G == 0 && color.
B == 0 && i < underworldLayer)
122 ushort wall2 = tile.
wall;
123 if ((uint)(wall2 - 242) <= 1u)
127 value.Y = tile.
wallFrameY() + 180 * (num12 / num11);
132 if (tile.
wall == 346)
134 vertices.TopRightColor = (vertices.TopLeftColor = (vertices.BottomRightColor = (vertices.BottomLeftColor =
new Color((
byte)
Main.
DiscoR, (
byte)
Main.
DiscoG, (
byte)
Main.
DiscoB))));
136 else if (tile.
wall == 44)
138 vertices.TopRightColor = (vertices.TopLeftColor = (vertices.BottomRightColor = (vertices.BottomLeftColor =
new Color((
byte)
Main.
DiscoR, (
byte)
Main.
DiscoG, (
byte)
Main.
DiscoB))));
144 if ((uint)(wall2 - 341) <= 4u)
153 tileBatch.
Draw(tileDrawTexture,
new Vector2(j * 16 - (
int)screenPosition.
X - 8, i * 16 - (
int)screenPosition.
Y - 8) + vector, value, vertices,
Vector2.
Zero, 1f,
SpriteEffects.None);
157 Color color2 = color;
158 if (wall == 44 || wall == 346)
162 if ((uint)(wall - 341) <= 4u)
167 spriteBatch.
Draw(tileDrawTexture2,
new Vector2(j * 16 - (
int)screenPosition.
X - 8, i * 16 - (
int)screenPosition.
Y - 8) + vector, value, color2, 0f,
Vector2.
Zero, 1f,
SpriteEffects.None, 0f);
169 if (color.
R > num2 || color.
G > num3 || color.
B > num4)
177 spriteBatch.
Draw(
TextureAssets.
WallOutline.Value,
new Vector2(j * 16 - (
int)screenPosition.
X, i * 16 - (
int)screenPosition.
Y) + vector,
new Rectangle(0, 0, 2, 16), color, 0f,
Vector2.
Zero, 1f,
SpriteEffects.None, 0f);
181 spriteBatch.
Draw(
TextureAssets.
WallOutline.Value,
new Vector2(j * 16 - (
int)screenPosition.
X + 14, i * 16 - (
int)screenPosition.
Y) + vector,
new Rectangle(14, 0, 2, 16), color, 0f,
Vector2.
Zero, 1f,
SpriteEffects.None, 0f);
185 spriteBatch.
Draw(
TextureAssets.
WallOutline.Value,
new Vector2(j * 16 - (
int)screenPosition.
X, i * 16 - (
int)screenPosition.
Y) + vector,
new Rectangle(0, 0, 16, 2), color, 0f,
Vector2.
Zero, 1f,
SpriteEffects.None, 0f);
189 spriteBatch.
Draw(
TextureAssets.
WallOutline.Value,
new Vector2(j * 16 - (
int)screenPosition.
X, i * 16 - (
int)screenPosition.
Y + 14) + vector,
new Rectangle(0, 14, 16, 2), color, 0f,
Vector2.
Zero, 1f,
SpriteEffects.None, 0f);
238 if (frameY == 18 || frameY == 108)
240 if (frameX >= 18 && frameX <= 54)
244 if (frameX >= 108 && frameX <= 144)
250 else if (frameY == 18)
252 if (frameX >= 18 && frameX <= 54)
256 if (frameX >= 108 && frameX <= 144)
261 else if (frameY >= 90 && frameY <= 196)
267 if (frameX >= 144 && frameX <= 232)