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

◆ HellRoom()

static void Terraria.WorldGen.HellRoom ( int i,
int j,
int width,
int height,
byte type = 76,
byte wall = 13 )
inlinestatic

Definition at line 24918 of file WorldGen.cs.

24919 {
24920 if (j > Main.maxTilesY - 40)
24921 {
24922 return;
24923 }
24924 for (int k = i - width / 2; k <= i + width / 2; k++)
24925 {
24926 for (int l = j - height; l <= j; l++)
24927 {
24928 try
24929 {
24930 Main.tile[k, l].active(active: true);
24931 Main.tile[k, l].type = type;
24932 Main.tile[k, l].liquid = 0;
24933 Main.tile[k, l].lava(lava: false);
24934 }
24935 catch
24936 {
24937 }
24938 }
24939 }
24940 for (int m = i - width / 2 + 1; m <= i + width / 2 - 1; m++)
24941 {
24942 for (int n = j - height + 1; n <= j - 1; n++)
24943 {
24944 try
24945 {
24946 Main.tile[m, n].active(active: false);
24947 Main.tile[m, n].wall = wall;
24948 Main.tile[m, n].liquid = 0;
24949 Main.tile[m, n].lava(lava: false);
24950 }
24951 catch
24952 {
24953 }
24954 }
24955 }
24956 }

References Terraria.Main.maxTilesY, Terraria.Main.tile, and System.type.