Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ UpdateAmbientFloorCloud()

void Terraria.Gore.UpdateAmbientFloorCloud ( )
inlineprivate

Definition at line 110 of file Gore.cs.

111 {
113 if (timeLeft <= 0)
114 {
115 active = false;
116 return;
117 }
118 bool flag = false;
119 Point point = (position + new Vector2(15f, 0f)).ToTileCoordinates();
120 Tile tile = Main.tile[point.X, point.Y];
121 Tile tile2 = Main.tile[point.X, point.Y + 1];
122 Tile tile3 = Main.tile[point.X, point.Y + 2];
123 if (tile == null || tile2 == null || tile3 == null)
124 {
125 active = false;
126 return;
127 }
128 if (WorldGen.SolidTile(tile) || (!WorldGen.SolidTile(tile2) && !WorldGen.SolidTile(tile3)))
129 {
130 flag = true;
131 }
132 if (timeLeft <= 30)
133 {
134 flag = true;
135 }
136 velocity.X = 0.4f * Main.WindForVisuals;
137 if (!flag)
138 {
139 if (alpha > 220)
140 {
141 alpha--;
142 }
143 }
144 else
145 {
146 alpha++;
147 if (alpha >= 255)
148 {
149 active = false;
150 return;
151 }
152 }
154 }
Vector2 velocity
Definition Gore.cs:19
Vector2 position
Definition Gore.cs:17
int type
Definition Gore.cs:27
bool active
Definition Gore.cs:31
int alpha
Definition Gore.cs:25
int timeLeft
Definition Gore.cs:35
static int[] DisappearSpeed
Definition GoreID.cs:11

References Terraria.Gore.active, Terraria.Gore.alpha, Terraria.ID.GoreID.Sets.DisappearSpeed, Terraria.Gore.position, Terraria.WorldGen.SolidTile(), Terraria.Main.tile, Terraria.Gore.timeLeft, Terraria.Gore.type, Terraria.Gore.velocity, Terraria.Main.WindForVisuals, Microsoft.Xna.Framework.Point.X, and Microsoft.Xna.Framework.Point.Y.

Referenced by Terraria.Gore.Update().