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

◆ UnlockDoor()

static void Terraria.WorldGen.UnlockDoor ( int i,
int j )
inlinestatic

Definition at line 32317 of file WorldGen.cs.

32318 {
32319 int num = j;
32320 if (Main.tile[i, num] == null)
32321 {
32322 return;
32323 }
32324 while (Main.tile[i, num].frameY != 594)
32325 {
32326 num--;
32327 if (Main.tile[i, num].frameY < 594 || num <= 0)
32328 {
32329 return;
32330 }
32331 }
32332 SoundEngine.PlaySound(22, i * 16, num * 16 + 16);
32333 for (int k = num; k <= num + 2; k++)
32334 {
32335 if (Main.tile[i, k] == null)
32336 {
32337 Main.tile[i, k] = new Tile();
32338 }
32339 Main.tile[i, k].frameY += 54;
32340 for (int l = 0; l < 4; l++)
32341 {
32342 Dust.NewDust(new Vector2(i * 16, k * 16), 16, 16, 11);
32343 }
32344 }
32346 }
static void PlaySound(int type, Vector2 position, int style=1)

References Terraria.Dust.NewDust(), Terraria.GameContent.Achievements.AchievementsHelper.NotifyProgressionEvent(), Terraria.Audio.SoundEngine.PlaySound(), Terraria.DataStructures.Tile, and Terraria.Main.tile.

Referenced by Terraria.MessageBuffer.GetData(), and Terraria.Player.TileInteractionsUse().