75603 {
75604
75605
75606
75607
75608
75609
75610
75611
75612
75613
75614
75615
75616
75617
75618
75619
75620
75621
75622
75623
75624
75625
75626
75627
75628
75629
75630
75631
75632
75633
75634
75635
75636
75637
75638
75639
75640
75641
75642
75643
75644
75645
75646
75647
75648
75649
75650
75651
75652
75653
75654
75655
75656
75657
75658
75659
75660
75661
75662
75663
75664
75665
75666
75667
75668
75669
75670
75671
75672
75673
75674
75675
75676
75677
75678
75679
75680
75683 {
75685 }
75687 {
75689 }
75693 {
75695 }
75697 {
75699 }
75702 {
75704 }
75714 {
75715 for (int i = 0; i < 200; i++)
75716 {
75718 {
75726 spriteBatch.Draw(
TextureAssets.
Cloud[
cloud[i].type].Value,
new Vector2(
cloud[i].position.X + (
float)
TextureAssets.
Cloud[
cloud[i].type].Width() * 0.5f,
num2 + (float)
TextureAssets.
Cloud[
cloud[i].type].Height() * 0.5f), (Rectangle?)
new Rectangle(0, 0,
TextureAssets.
Cloud[
cloud[i].type].Width(),
TextureAssets.
Cloud[
cloud[i].type].Height()), color *
num21,
cloud[i].rotation,
new Vector2((
float)
TextureAssets.
Cloud[
cloud[i].type].Width() * 0.5f, (
float)
TextureAssets.
Cloud[
cloud[i].type].Height() * 0.5f),
cloud[i].scale,
cloud[i].spriteDir, 0
f);
75727 }
75728 }
75729 }
75731 {
75733 }
75735 {
75737 }
75744 {
75746 }
75750 {
75752 {
75754 {
75757 {
75759 }
75760 }
75761 else
75762 {
75765 {
75767 }
75768 }
75770 {
75775 {
75777 }
75781 {
75783 }
75785 {
75787 }
75789 {
75791 }
75795 {
75797 }
75804 {
75805 spriteBatch.Draw(
TextureAssets.
Background[
cloudBG[0]].Value,
new Vector2((
float)
bgStartX +
num6 * (float)
j, (
float)
bgTopY), (Rectangle?)
new Rectangle(0, 0,
backgroundWidth[
cloudBG[0]],
backgroundHeight[
cloudBG[0]]),
ColorOfSurfaceBackgroundsModified *
num21, 0
f,
default(Vector2),
bgScale, (SpriteEffects)0, 0
f);
75806 }
75809 {
75811 }
75816 {
75818 }
75820 {
75822 }
75824 {
75826 }
75830 {
75832 }
75838 {
75839 spriteBatch.Draw(
TextureAssets.
Background[
cloudBG[1]].Value,
new Vector2((
float)
bgStartX +
num6 * (float)
k, (
float)
bgTopY), (Rectangle?)
new Rectangle(0, 0,
backgroundWidth[
cloudBG[1]],
backgroundHeight[
cloudBG[1]]),
ColorOfSurfaceBackgroundsModified *
num21, 0
f,
default(Vector2),
bgScale, (SpriteEffects)0, 0
f);
75840 }
75841 }
75843 }
75846 {
75847 for (
int l = 0;
l < 200;
l++)
75848 {
75850 {
75853 {
75855 }
75859 {
75861 }
75863 {
75865 }
75867 {
75869 }
75870 spriteBatch.Draw(
TextureAssets.
Cloud[
cloud[
l].type].Value,
new Vector2(
cloud[
l].position.X + (
float)
TextureAssets.
Cloud[
cloud[
l].type].Width() * 0.5f,
num7 + (float)
TextureAssets.
Cloud[
cloud[
l].type].Height() * 0.5f +
cTop + 200
f), (Rectangle?)
new Rectangle(0, 0,
TextureAssets.
Cloud[
cloud[
l].type].Width(),
TextureAssets.
Cloud[
cloud[
l].type].Height()),
color2 *
num21,
cloud[
l].rotation,
new Vector2((
float)
TextureAssets.
Cloud[
cloud[
l].type].Width() * 0.5f, (
float)
TextureAssets.
Cloud[
cloud[
l].type].Height() * 0.5f),
cloud[
l].scale,
cloud[
l].spriteDir, 0
f);
75871 }
75872 }
75873 }
75875 {
75885 {
75888 }
75893 {
75895 }
75896 else if (
num9 < 0
f)
75897 {
75899 }
75904 if ((
double)screenPosition.Y <
worldSurface * 16.0 + 16.0)
75905 {
75909 {
75910 spriteBatch.Draw(
TextureAssets.
Background[18].Value,
new Vector2((
float)(
bgStartX +
bgWidthScaled *
m), (
float)
bgTopY), (Rectangle?)
new Rectangle(0, 0,
backgroundWidth[18],
backgroundHeight[18]),
color3, 0
f,
default(Vector2),
bgScale, (SpriteEffects)0, 0
f);
75911 spriteBatch.Draw(
TextureAssets.
Background[19].Value,
new Vector2((
float)(
bgStartX +
bgWidthScaled *
m + 1900), (
float)(
bgTopY + 100)), (Rectangle?)
new Rectangle(0, 0,
backgroundWidth[19],
backgroundHeight[19]),
color3, 0
f,
default(Vector2),
bgScale * 0.9
f, (SpriteEffects)0, 0
f);
75912 }
75913 }
75914 }
75916 {
75923 {
75925 }
75930 {
75932 }
75934 }
75936 {
75938 }
75940 if ((
double)screenPosition.Y <
worldSurface * 16.0 + 16.0)
75941 {
75942 for (
int n = 0;
n < 200;
n++)
75943 {
75945 {
75948 {
75950 }
75954 {
75956 }
75958 {
75960 }
75962 {
75964 }
75965 spriteBatch.Draw(
TextureAssets.
Cloud[
cloud[
n].type].Value,
new Vector2(
cloud[
n].position.X + (
float)
TextureAssets.
Cloud[
cloud[
n].type].Width() * 0.5f,
num11 + (float)
TextureAssets.
Cloud[
cloud[
n].type].Height() * 0.5f +
cTop), (Rectangle?)
new Rectangle(0, 0,
TextureAssets.
Cloud[
cloud[
n].type].Width(),
TextureAssets.
Cloud[
cloud[
n].type].Height()),
color4 *
num21,
cloud[
n].rotation,
new Vector2((
float)
TextureAssets.
Cloud[
cloud[
n].type].Width() * 0.5f, (
float)
TextureAssets.
Cloud[
cloud[
n].type].Height() * 0.5f),
cloud[
n].scale,
cloud[
n].spriteDir, 0
f);
75966 }
75967 }
75968 }
75969 }
75971 {
75973 }
75975 {
75977 {
75979 {
75982 {
75985 }
75987 {
75990 }
75992 {
75995 }
75997 {
76000 }
76002 {
76006 }
76008 {
76012 }
76014 {
76018 }
76020 {
76022 }
76024 {
76027 }
76029 {
76033 }
76035 {
76039 }
76041 {
76045 }
76047 {
76051 }
76053 {
76055 }
76056 }
76057 }
76058 }
76060 {
76062 }
76065 {
76074 {
76079 }
76080 }
76082 {
76084 }
76085 }
static Asset< Texture2D >[] Background
static Asset< Texture2D >[] Cloud
static SkyManager Instance
void DrawSurfaceBG_BackMountainsStep1(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack)
static SceneMetrics SceneMetrics
static float windSpeedCurrent
void DrawSurfaceBG_Corrupt(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)
void DrawSurfaceBG_Crimson(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)
static float cloudBGAlpha
static Color ColorOfSurfaceBackgroundsBase
static Color ColorOfTheSkies
void LoadBackground(int i)
static float DrawSurfaceBG_GetFogPower()
static Color ColorOfSurfaceBackgroundsModified
static SpriteBatch spriteBatch
static double worldSurface
The y-coordinate of the top of the dirt layer, in tile coordinates. Corresponds to 0' on the Depth Me...
static double desiredWorldEventsUpdateRate
static Vector2 screenPosition
The position of the top left corner of the screen in world coordinates. Modify in M:Terraria....
void DrawSurfaceBG_Desert(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)
static int[] backgroundWidth
void SetBackgroundOffsets(int backgroundID, double backgroundTopMagicNumber, int pushBGTopHack)
static bool BackgroundEnabled
void DrawSurfaceBG_Snow(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)
static int[] treeMntBGSet1
static float[] bgAlphaFrontLayer
void DrawSurfaceBG_GoodEvilDesert(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack)
static int[] backgroundHeight
void DrawSurfaceBG_BackMountainsStep2(int pushBGTopHack)
static float cloudBGActive
void DrawSurfaceBG_Jungle(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)
void DrawSurfaceBG_Hallow(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)
void DrawSurfaceBG_DrawChangeOverlay(int backgroundAreaId)
void DrawSurfaceBG_Mushroom(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)
static bool mapFullscreen
void DrawSurfaceBG_Forest(double backgroundTopMagicNumber, float bgGlobalScaleMultiplier, int pushBGTopHack, int[] bgTexIndexes)