14802 {
14803
14804
14805
14806
14807
14808
14809
14810
14811
14812
14813
14814
14815
14816
14817
14818
14819
14820
14821
14822
14823
14824
14825
14826
14827
14828
14829
14830
14831
14832
14833
14834
14835
14836
14837
14838
14839
14840
14841
14842
14843
14844
14845
14846
14847
14848
14849
14850
14851
14852
14853
14854
14855
14856
14857
14858
14859
14860
14861
14862
14863
14864
14865
14866
14867
14868
14869
14870
14871
14872
14873
14874
14875
14876
14877
14878
14879
14880
14881
14882
14883
14884
14885
14886
14887
14888
14889
14890
14891
14892
14893
14894
14895
14896
14897
14898
14899
14900
14901 Point point =
base.Center.ToTileCoordinates();
14903 if (Main.SceneMetrics.DungeonTileCount >= 250 && (
double)
base.Center.Y > Main.worldSurface * 16.0)
14904 {
14905 int num = (int)
base.Center.X / 16;
14907 if (Main.tile[
num,
num12] !=
null && Main.wallDungeon[Main.tile[
num,
num12].wall])
14908 {
14910 }
14911 }
14916 {
14918 }
14921 {
14923 }
14925 {
14927 {
14929 }
14930 }
14931 else
14932 {
14934 }
14936 {
14938 }
14939 else
14940 {
14942 }
14944 {
14946 }
14947 else
14948 {
14950 }
14952 {
14954 }
14955 else
14956 {
14958 }
14960 {
14962 }
14963 else
14964 {
14966 }
14967 bool flag = (double)(Main.screenPosition.Y / 16
f) > Main.worldSurface + 50.0 && Main.screenPosition.Y / 16
f < (float)(Main.maxTilesY - 330 - 100);
14969 ZoneCorrupt = Main.SceneMetrics.EnoughTilesForCorruption;
14970 ZoneCrimson = Main.SceneMetrics.EnoughTilesForCrimson;
14971 ZoneHallow = Main.SceneMetrics.EnoughTilesForHallow;
14972 ZoneJungle = Main.SceneMetrics.EnoughTilesForJungle && position.Y / 16
f < (float)Main.UnderworldLayer;
14973 ZoneSnow = Main.SceneMetrics.EnoughTilesForSnow;
14974 ZoneDesert = Main.SceneMetrics.EnoughTilesForDesert;
14975 ZoneGlowshroom = Main.SceneMetrics.EnoughTilesForGlowingMushroom;
14976 ZoneMeteor = Main.SceneMetrics.EnoughTilesForMeteor;
14983 {
14986 }
14988 ZoneRockLayerHeight = point.Y <= Main.UnderworldLayer && (double)point.Y > Main.rockLayer;
14989 ZoneDirtLayerHeight = (double)point.Y <= Main.rockLayer && (
double)point.Y > Main.worldSurface;
14990 ZoneOverworldHeight = (double)point.Y <= Main.worldSurface && (
double)point.Y > Main.worldSurface * 0.3499999940395355;
14991 ZoneSkyHeight = (double)point.Y <= Main.worldSurface * 0.3499999940395355;
14993 ZoneRain = Main.raining && (double)point.Y <= Main.worldSurface;
14994 if (Main.remixWorld)
14995 {
14997 }
14998 else
14999 {
15001 }
15010 Vector2
vector = Vector2.Zero;
15011 Vector2
vector2 = Vector2.Zero;
15012 Vector2
vector3 = Vector2.Zero;
15013 Vector2
vector4 = Vector2.Zero;
15015 for (int i = 0; i < 200; i++)
15016 {
15017 if (!Main.npc[i].active)
15018 {
15019 continue;
15020 }
15021 if (Main.npc[i].type == 493)
15022 {
15023 if (
Distance(Main.npc[i].Center) <= 4000
f)
15024 {
15026 vector4 = Main.npc[i].Center;
15027 }
15028 }
15029 else if (Main.npc[i].type == 507)
15030 {
15031 if (
Distance(Main.npc[i].Center) <= 4000
f)
15032 {
15034 vector3 = Main.npc[i].Center;
15035 }
15036 }
15037 else if (Main.npc[i].type == 422)
15038 {
15039 if (
Distance(Main.npc[i].Center) <= 4000
f)
15040 {
15042 vector2 = Main.npc[i].Center;
15043 }
15044 }
15045 else if (Main.npc[i].type == 517)
15046 {
15047 if (
Distance(Main.npc[i].Center) <= 4000
f)
15048 {
15050 vector = Main.npc[i].Center;
15051 }
15052 }
15053 else if (Main.npc[i].type == 549 &&
Distance(Main.npc[i].Center) <= 4000
f)
15054 {
15056 vector = Main.npc[i].Center;
15057 }
15058 }
15061 float num19 = Main.shimmerAlpha;
15063 {
15067 {
15070 {
15072 }
15073 }
15075 {
15076 Main.shimmerDarken =
MathHelper.Clamp(Main.shimmerDarken + 0.025f, 0
f, 1
f);
15077 Main.shimmerBrightenDelay = 4
f;
15078 }
15079 }
15081 {
15082 Main.shimmerDarken =
MathHelper.Clamp(Main.shimmerDarken - 0.05f, 0
f, 1
f);
15083 if (Main.shimmerDarken == 0
f && Main.shimmerBrightenDelay > 0
f)
15084 {
15085 Main.shimmerBrightenDelay -= 1
f;
15086 }
15087 if (Main.shimmerBrightenDelay == 0
f)
15088 {
15090 }
15092 {
15094 }
15095 }
15096 Main.shimmerAlpha =
num19;
15097 if (Main.getGoodWorld)
15098 {
15099 bool flag5 =
false;
15100 int num20 =
NPC.FindFirstNPC(245);
15101 if (
num20 >= 0 && Vector2.Distance(
base.Center, Main.npc[
num20].Center) < 2000
f)
15102 {
15104 }
15106 {
15109 }
15111 {
15114 }
15116 {
15119 }
15120 }
15122 {
15124 {
15127 {
15129 }
15130 }
15131 else
15132 {
15135 {
15137 }
15138 }
15139 }
15141 {
15143 {
15146 {
15148 }
15149 }
15150 else
15151 {
15154 {
15156 }
15157 }
15158 }
15160 if (Main.remixWorld)
15161 {
15163 }
15164 bool flag7 = point.Y > Main.maxTilesY - 320;
15175 if (Main.GraveyardVisualIntensity > 0
f)
15176 {
15178 {
15179 Filters.
Scene.Activate(
"Graveyard",
default(Vector2));
15180 }
15181 else
15182 {
15184 float progress =
MathHelper.Lerp(0
f, 0.75
f, Main.GraveyardVisualIntensity);
15185 Filters.
Scene[
"Graveyard"].GetShader().UseProgress(progress);
15187 }
15188 }
15190 {
15192 }
15194 {
15196 }
15198 {
15200 }
15201 if (!
Filters.
Scene[
"WaterDistortion"].IsActive() && Main.WaveQuality > 0)
15202 {
15203 Filters.
Scene.Activate(
"WaterDistortion",
default(Vector2));
15204 }
15205 else if (
Filters.
Scene[
"WaterDistortion"].IsActive() && Main.WaveQuality == 0)
15206 {
15208 }
15210 {
15211 float num21 = (float)Main.maxTilesX * 0.5f -
Math.Abs((
float)point.X - (float)Main.maxTilesX * 0.5f);
15213 float num3 =
Math.Abs(Main.windSpeedCurrent);
15219 float num6 = 1
f -
MathHelper.Clamp(3
f * ((
float)((
double)point.Y - Main.worldSurface) / (
float)(Main.rockLayer - Main.worldSurface)), 0
f, 1
f);
15221 float num7 = 0.9f -
MathHelper.Clamp((
float)(Main.maxTilesY - point.Y - 200) / 300
f, 0
f, 1
f) * 0.9f;
15226 }
15228 {
15229 float val = (float)(point.Y - (Main.maxTilesY - 320)) / 120
f;
15232 }
15236 {
15240 }
15242 {
15243 Vector3
vector5 = ((Color)(
ref Main.tileColor)).ToVector3();
15244 float num8 = (vector5.X + vector5.Y +
vector5.Z) / 3
f;
15248 {
15250 }
15251 else
15252 {
15254 }
15255 }
15257 {
15258 try
15259 {
15261 {
15262 float cloudAlpha = Main.cloudAlpha;
15263 if (Main.remixWorld)
15264 {
15265 Main.cloudAlpha = 0.4f;
15266 }
15267 bool value =
NPC.IsADeerclopsNearScreen();
15276 if (Main.remixWorld)
15277 {
15278 Main.cloudAlpha = cloudAlpha;
15279 }
15280 }
15281 }
15282 catch
15283 {
15285 }
15286 }
15288 {
15289 try
15290 {
15292 {
15296 {
15298 }
15300 {
15302 }
15305 }
15307 {
15309 }
15310 else
15311 {
15313 }
15318 {
15320 {
15323 }
15326 {
15329 }
15331 }
15332 else
15333 {
15335 {
15336 activeSound3.Volume = 0
f;
15337 }
15338 else
15339 {
15341 }
15343 {
15344 activeSound4.Volume = 0
f;
15345 }
15346 else
15347 {
15349 }
15350 }
15351 }
15352 catch
15353 {
15355 }
15356 }
15359 {
15360 Point
point2 =
base.Center.ToTileCoordinates();
15362 {
15365 {
15367 }
15369 {
15370 case 86:
15372 break;
15373 case 62:
15375 break;
15376 }
15377 }
15379 {
15381 }
15382 if (Main.specialSeedWorld)
15383 {
15385 }
15386 if (
position.Y / 16
f > (
float)Main.UnderworldLayer)
15387 {
15389 }
15391 {
15393 }
15395 {
15397 }
15398 }
15399 else
15400 {
15402 }
15404 }
static ? ActiveSound GetActiveSound(SlotId slotId)
static SlotId PlayTrackedSound(in SoundStyle style, Vector2? position=null)
float Distance(Vector2 Other)
Vector2 position
The position of this Entity in world coordinates.
static void HandleSpecialEvent(Player player, int eventID)
static FilterManager Scene
static OverlayManager Scene
static readonly SoundStyle BlizzardStrongLoop
static readonly SoundStyle BlizzardInsideBuildingLoop
static bool[] HardenedSand
This serves as the central class from which SceneEffect functions are supported and carried out.
float _deerclopsBlizzardSmoothedEffect
static float solidLightDecay
bool bloodMoonMonolithShader
bool ZonePurity
The zone property storing if the player is not in any particular biome. Updated in M:Terraria....
float _stormShaderObstruction
void UpdateGraveyard(bool now=false)
float _shaderObstructionInternalValue
bool ZoneUndergroundDesert
bool ZoneDirtLayerHeight
If true, then this player is underground (F:Terraria.Main.worldSurface) but above the Caverns layer (...
bool ZoneSkyHeight
If true, then this player is the top 35% of the world. NOTE: Vanilla uses a lot of different condit...
bool CanSeeShimmerEffects()
bool ZoneUnderworldHeight
If true, then this player is in the Underworld (P:Terraria.Main.UnderworldLayer).
int _funkytownAchievementCheckCooldown
static float airLightDecay
static bool disabledBlizzardSound
bool ZoneOverworldHeight
If true, then this player is above ground (F:Terraria.Main.worldSurface) but not in space (P:Terraria...
void ManageSpecialBiomeVisuals(string biomeName, bool inZone, Vector2 activationSource=default(Vector2))
bool ZoneRockLayerHeight
If true, then this player is in the Caverns layer (F:Terraria.Main.rockLayer) but not in the Underwor...
static float _blizzardSoundVolume
bool HasGardenGnomeNearby
static bool disabledBlizzardGraphic
bool InZonePurity()
Calculates whether or not the player is in the purity/forest biome.
static SlotId _strongBlizzardSound
static SlotId _insideBlizzardSound