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

◆ DrawCapture()

void Terraria.Main.DrawCapture ( Rectangle area,
CaptureSettings settings )
inline

Definition at line 72450 of file Main.cs.

72451 {
72452 //IL_00e2: Unknown result type (might be due to invalid IL or missing references)
72453 //IL_00e7: Unknown result type (might be due to invalid IL or missing references)
72454 //IL_0106: Unknown result type (might be due to invalid IL or missing references)
72455 //IL_0113: Unknown result type (might be due to invalid IL or missing references)
72456 //IL_0120: Unknown result type (might be due to invalid IL or missing references)
72457 //IL_012a: Unknown result type (might be due to invalid IL or missing references)
72458 //IL_0134: Unknown result type (might be due to invalid IL or missing references)
72459 //IL_0139: Unknown result type (might be due to invalid IL or missing references)
72460 //IL_017d: Unknown result type (might be due to invalid IL or missing references)
72461 //IL_0185: Unknown result type (might be due to invalid IL or missing references)
72462 //IL_018d: Unknown result type (might be due to invalid IL or missing references)
72463 //IL_019e: Unknown result type (might be due to invalid IL or missing references)
72464 //IL_026a: Unknown result type (might be due to invalid IL or missing references)
72465 //IL_026f: Unknown result type (might be due to invalid IL or missing references)
72466 //IL_0270: Unknown result type (might be due to invalid IL or missing references)
72467 //IL_0275: Unknown result type (might be due to invalid IL or missing references)
72468 //IL_02c6: Unknown result type (might be due to invalid IL or missing references)
72469 //IL_02e4: Unknown result type (might be due to invalid IL or missing references)
72470 //IL_030e: Unknown result type (might be due to invalid IL or missing references)
72471 //IL_033c: Unknown result type (might be due to invalid IL or missing references)
72472 //IL_03ad: Unknown result type (might be due to invalid IL or missing references)
72473 //IL_03a6: Unknown result type (might be due to invalid IL or missing references)
72474 //IL_03b2: Unknown result type (might be due to invalid IL or missing references)
72475 //IL_03be: Unknown result type (might be due to invalid IL or missing references)
72476 //IL_03e6: Unknown result type (might be due to invalid IL or missing references)
72477 //IL_0403: Unknown result type (might be due to invalid IL or missing references)
72478 //IL_042b: Unknown result type (might be due to invalid IL or missing references)
72479 //IL_043e: Unknown result type (might be due to invalid IL or missing references)
72480 //IL_0440: Unknown result type (might be due to invalid IL or missing references)
72481 //IL_0445: Unknown result type (might be due to invalid IL or missing references)
72482 //IL_044a: Unknown result type (might be due to invalid IL or missing references)
72483 //IL_04a0: Unknown result type (might be due to invalid IL or missing references)
72484 //IL_04c3: Unknown result type (might be due to invalid IL or missing references)
72485 //IL_04c8: Unknown result type (might be due to invalid IL or missing references)
72486 //IL_04d8: Unknown result type (might be due to invalid IL or missing references)
72487 //IL_04dd: Unknown result type (might be due to invalid IL or missing references)
72488 //IL_051f: Unknown result type (might be due to invalid IL or missing references)
72489 //IL_0524: Unknown result type (might be due to invalid IL or missing references)
72490 //IL_0526: Unknown result type (might be due to invalid IL or missing references)
72491 //IL_052b: Unknown result type (might be due to invalid IL or missing references)
72492 //IL_0534: Unknown result type (might be due to invalid IL or missing references)
72493 //IL_054c: Unknown result type (might be due to invalid IL or missing references)
72494 //IL_057a: Unknown result type (might be due to invalid IL or missing references)
72495 //IL_057f: Unknown result type (might be due to invalid IL or missing references)
72496 //IL_058d: Unknown result type (might be due to invalid IL or missing references)
72497 //IL_0592: Unknown result type (might be due to invalid IL or missing references)
72498 //IL_0594: Unknown result type (might be due to invalid IL or missing references)
72499 //IL_0599: Unknown result type (might be due to invalid IL or missing references)
72500 //IL_0a94: Unknown result type (might be due to invalid IL or missing references)
72501 //IL_0aa3: Unknown result type (might be due to invalid IL or missing references)
72502 //IL_0aad: Unknown result type (might be due to invalid IL or missing references)
72503 //IL_0ab7: Unknown result type (might be due to invalid IL or missing references)
72504 //IL_0ac1: Unknown result type (might be due to invalid IL or missing references)
72505 //IL_0ad9: Unknown result type (might be due to invalid IL or missing references)
72506 //IL_0aec: Unknown result type (might be due to invalid IL or missing references)
72507 //IL_06b1: Unknown result type (might be due to invalid IL or missing references)
72508 //IL_06b5: Unknown result type (might be due to invalid IL or missing references)
72509 //IL_06ba: Unknown result type (might be due to invalid IL or missing references)
72510 //IL_06bf: Unknown result type (might be due to invalid IL or missing references)
72511 //IL_06c4: Unknown result type (might be due to invalid IL or missing references)
72512 //IL_06d4: Unknown result type (might be due to invalid IL or missing references)
72513 //IL_06ea: Unknown result type (might be due to invalid IL or missing references)
72514 //IL_06fa: Unknown result type (might be due to invalid IL or missing references)
72515 //IL_06ff: Unknown result type (might be due to invalid IL or missing references)
72516 //IL_070c: Unknown result type (might be due to invalid IL or missing references)
72517 //IL_074b: Unknown result type (might be due to invalid IL or missing references)
72518 //IL_0750: Unknown result type (might be due to invalid IL or missing references)
72519 //IL_085d: Unknown result type (might be due to invalid IL or missing references)
72520 //IL_0867: Unknown result type (might be due to invalid IL or missing references)
72521 //IL_0876: Unknown result type (might be due to invalid IL or missing references)
72522 //IL_0881: Unknown result type (might be due to invalid IL or missing references)
72523 //IL_0897: Unknown result type (might be due to invalid IL or missing references)
72524 //IL_08c7: Unknown result type (might be due to invalid IL or missing references)
72525 //IL_08dc: Unknown result type (might be due to invalid IL or missing references)
72526 //IL_08e1: Unknown result type (might be due to invalid IL or missing references)
72527 //IL_076e: Unknown result type (might be due to invalid IL or missing references)
72528 //IL_078f: Unknown result type (might be due to invalid IL or missing references)
72529 //IL_0965: Unknown result type (might be due to invalid IL or missing references)
72530 //IL_0967: Unknown result type (might be due to invalid IL or missing references)
72531 //IL_07bc: Unknown result type (might be due to invalid IL or missing references)
72532 //IL_07ed: Unknown result type (might be due to invalid IL or missing references)
72533 //IL_09ae: Unknown result type (might be due to invalid IL or missing references)
72534 //IL_09b0: Unknown result type (might be due to invalid IL or missing references)
72535 //IL_0800: Unknown result type (might be due to invalid IL or missing references)
72536 //IL_0802: Unknown result type (might be due to invalid IL or missing references)
72537 //IL_0818: Unknown result type (might be due to invalid IL or missing references)
72538 //IL_081d: Unknown result type (might be due to invalid IL or missing references)
72539 //IL_0824: Unknown result type (might be due to invalid IL or missing references)
72540 //IL_0832: Unknown result type (might be due to invalid IL or missing references)
72541 //IL_0839: Unknown result type (might be due to invalid IL or missing references)
72542 //IL_084c: Unknown result type (might be due to invalid IL or missing references)
72543 //IL_0851: Unknown result type (might be due to invalid IL or missing references)
72544 //IL_09da: Unknown result type (might be due to invalid IL or missing references)
72545 //IL_09df: Unknown result type (might be due to invalid IL or missing references)
72546 //IL_0a10: Unknown result type (might be due to invalid IL or missing references)
72547 //IL_0a12: Unknown result type (might be due to invalid IL or missing references)
72548 //IL_1047: Unknown result type (might be due to invalid IL or missing references)
72549 //IL_1049: Unknown result type (might be due to invalid IL or missing references)
72550 //IL_0f99: Unknown result type (might be due to invalid IL or missing references)
72551 //IL_1016: Unknown result type (might be due to invalid IL or missing references)
72552 //IL_101c: Unknown result type (might be due to invalid IL or missing references)
72553 //IL_0fa3: Unknown result type (might be due to invalid IL or missing references)
72554 //IL_0fff: Unknown result type (might be due to invalid IL or missing references)
72555 //IL_1005: Unknown result type (might be due to invalid IL or missing references)
72556 //IL_0fde: Unknown result type (might be due to invalid IL or missing references)
72557 //IL_0fe3: Unknown result type (might be due to invalid IL or missing references)
72558 //IL_0fe8: Unknown result type (might be due to invalid IL or missing references)
72559 //IL_0fed: Unknown result type (might be due to invalid IL or missing references)
72560 float[] array = bgAlphaFrontLayer;
72561 bgAlphaFrontLayer = new float[array.Length];
72562 float[] array2 = bgAlphaFarBackLayer;
72563 bgAlphaFarBackLayer = new float[array2.Length];
72564 UpdateBGVisibility_BackLayer(settings.Biome.BackgroundIndex, 1f);
72565 UpdateBGVisibility_FrontLayer(settings.Biome.BackgroundIndex, 1f);
72566 float[] array3 = liquidAlpha.ToArray();
72567 int holyTileCount = SceneMetrics.HolyTileCount;
72568 SceneMetrics.HolyTileCount = ((settings.Biome.BackgroundIndex == 6) ? SceneMetrics.HallowTileMax : 0);
72569 int num = offScreenRange;
72570 offScreenRange = 0;
72572 GameViewMatrix = new SpriteViewMatrix(((Game)this).GraphicsDevice);
72573 Rasterizer = RasterizerState.CullCounterClockwise;
72574 bool captureEntities = settings.CaptureEntities;
72575 bool captureBackground = settings.CaptureBackground;
72576 CaptureBiome biome = settings.Biome;
72577 Vector2 vector = screenPosition;
72578 int num10 = screenWidth;
72579 int num11 = screenHeight;
72580 float num12 = cloudAlpha;
72581 bool captureMech = settings.CaptureMech;
72582 screenWidth = area.Width << 4;
72583 screenHeight = area.Height << 4;
72584 screenPosition = new Vector2((float)(area.X * 16), (float)(area.Y * 16));
72585 cloudAlpha = 0f;
72586 for (int i = 0; i <= 10; i++)
72587 {
72588 if (i != 1)
72589 {
72590 liquidAlpha[i] = ((i == biome.WaterStyle) ? 1f : 0f);
72591 }
72592 }
72593 int x = area.X;
72594 int y = area.Y;
72595 int num13 = area.X + screenWidth / 16;
72596 int num14 = area.Y + screenHeight / 16;
72597 float num15 = (biome.TileColor == CaptureBiome.TileColorStyle.Mushroom).ToInt();
72598 InfoToSetBackColor info = default(InfoToSetBackColor);
72599 info.isInGameMenuOrIsServer = gameMenu || netMode == 2;
72600 info.CorruptionBiomeInfluence = (biome.TileColor == CaptureBiome.TileColorStyle.Corrupt).ToInt();
72601 info.CrimsonBiomeInfluence = (biome.TileColor == CaptureBiome.TileColorStyle.Crimson).ToInt();
72602 info.JungleBiomeInfluence = (biome.TileColor == CaptureBiome.TileColorStyle.Jungle).ToInt();
72603 info.MushroomBiomeInfluence = num15;
72604 info.GraveyardInfluence = GraveyardVisualIntensity;
72605 info.BloodMoonActive = biome.WaterStyle == 9;
72606 info.LanternNightActive = LanternNight.LanternsUp;
72610 bool flag = mapEnabled;
72611 mapEnabled = false;
72612 Lighting.Initialize();
72613 renderCount = 99;
72614 for (int j = 0; j < 4; j++)
72615 {
72616 Lighting.LightTiles(x, num13, y, num14);
72617 }
72618 mapEnabled = flag;
72619 if (!((float)(settings.Area.X * 16) > vector.X - 16f) || !((float)(settings.Area.Y * 16) > vector.Y - 16f) || !((float)((settings.Area.X + settings.Area.Width) * 16) < vector.X + (float)num10 + 16f) || !((float)((settings.Area.Y + settings.Area.Height) * 16) < vector.Y + (float)num11 + 16f))
72620 {
72621 for (int k = 0; k < dust.Length; k++)
72622 {
72623 if (dust[k].active && dust[k].type == 76)
72624 {
72625 dust[k].active = false;
72626 }
72627 }
72628 }
72629 Vector2 vector2 = (Vector2)(drawToScreen ? Vector2.Zero : new Vector2((float)offScreenRange, (float)offScreenRange));
72630 int val = (int)((screenPosition.X - vector2.X) / 16f - 1f);
72631 int val2 = (int)((screenPosition.X + (float)screenWidth + vector2.X) / 16f) + 2;
72632 int val3 = (int)((screenPosition.Y - vector2.Y) / 16f - 1f);
72633 int val4 = (int)((screenPosition.Y + (float)screenHeight + vector2.Y) / 16f) + 5;
72635 val = Math.Max(val, 5) - 2;
72636 val3 = Math.Max(val3, 5);
72637 val2 = Math.Min(val2, maxTilesX - 5) + 2;
72638 val4 = Math.Min(val4, maxTilesY - 5) + 4;
72639 Rectangle drawArea = default(Rectangle);
72640 ((Rectangle)(ref drawArea))._002Ector(val, val3, val2 - val, val4 - val3);
72641 LiquidRenderer.Instance.PrepareDraw(drawArea);
72642 WorldGen.SectionTileFrameWithCheck(x, y, num13, num14);
72643 SceneArea sceneArea = default(SceneArea);
72645 {
72646 Matrix transform = Transform;
72647 int num16 = screenHeight;
72648 int num17 = screenWidth;
72649 Vector2 vector3 = screenPosition;
72650 bool flag2 = mapFullscreen;
72651 mapFullscreen = false;
72652 float num2 = scAdj;
72653 Vector2 vector4 = default(Vector2);
72654 ((Vector2)(ref vector4))._002Ector((float)num10, (float)num11);
72655 Vector2 vector5 = new Vector2((float)(settings.Area.Width * 16), (float)(settings.Area.Height * 16)) / vector4;
72656 vector5.X = Math.Max(1f, vector5.X);
72657 vector5.Y = Math.Max(1f, vector5.Y);
72658 Vector2[] array4 = (Vector2[])(object)new Vector2[numClouds];
72659 for (int l = 0; l < numClouds; l++)
72660 {
72661 array4[l] = cloud[l].position;
72662 Cloud obj = cloud[l];
72663 obj.position *= vector5;
72664 }
72665 if ((float)(settings.Area.Height * 16) >= 2000f || (float)(settings.Area.Width * 16) >= 2000f)
72666 {
72667 scAdj = 0f;
72668 float num3 = 2048f;
72669 float num4 = MathHelper.Clamp((float)settings.Area.Height * 16f / num3, 1f, 3f);
72670 screenWidth = settings.Area.Width * 16;
72671 screenHeight = Math.Min(2048, settings.Area.Height * 16);
72672 screenPosition.X = settings.Area.X * 16;
72673 screenPosition.Y = settings.Area.Y * 16;
72674 screenPosition.Y += Math.Max(0f, Math.Min(settings.Area.Height, (float)worldSurface) * 16f - num3 * num4);
72675 transform *= Matrix.CreateScale(num4);
72676 ((Matrix)(ref transform)).Translation = ((Matrix)(ref transform)).Translation + new Vector3((float)((settings.Area.X - area.X) * 16), (float)((settings.Area.Y - area.Y) * 16), 0f);
72677 ((Matrix)(ref transform)).Translation = ((Matrix)(ref transform)).Translation + new Vector3(0f, Math.Max(0f, Math.Min(settings.Area.Height, (float)worldSurface) * 16f - num3 * num4) / num4, 0f);
72678 }
72679 else if ((float)(settings.Area.X * 16) > vector.X - 16f && (float)(settings.Area.Y * 16) > vector.Y - 16f && (float)((settings.Area.X + settings.Area.Width) * 16) < vector.X + (float)num10 + 16f && (float)((settings.Area.Y + settings.Area.Height) * 16) < vector.Y + (float)num11 + 16f)
72680 {
72684 ((Matrix)(ref transform)).Translation = ((Matrix)(ref transform)).Translation + new Vector3(vector.X - (float)area.X * 16f, vector.Y - (float)area.Y * 16f, 0f);
72685 }
72686 Vector2 areaPosition = default(Vector2);
72687 ((Vector2)(ref areaPosition))._002Ector((float)(area.X * 16), (float)(area.Y * 16));
72688 int areaWidth = area.Width * 16;
72689 int areaHeight = area.Height * 16;
72690 tileBatch.Begin();
72692 tileBatch.End();
72693 spriteBatch.Begin((SpriteSortMode)0, BlendState.AlphaBlend, SamplerState.AnisotropicClamp, DepthStencilState.Default, RasterizerState.CullNone, (Effect)null, transform);
72694 int num5 = screenWidth;
72695 int num6 = screenHeight;
72696 Vector2 zero = Vector2.Zero;
72697 if (num5 < 800)
72698 {
72699 int num7 = 800 - num5;
72700 zero.X -= (float)num7 * 0.5f;
72701 num5 = 800;
72702 }
72703 if (num6 < 600)
72704 {
72705 int num8 = 600 - num6;
72706 zero.Y -= (float)num8 * 0.5f;
72707 num6 = 600;
72708 }
72709 SceneArea sceneArea2 = default(SceneArea);
72710 sceneArea2.bgTopY = 0;
72711 sceneArea2.totalWidth = num5;
72712 sceneArea2.totalHeight = num6;
72713 sceneArea2.SceneLocalScreenPositionOffset = zero;
72714 SceneArea sceneArea3 = sceneArea2;
72716 if (shimmerAlpha != 1f)
72717 {
72719 }
72720 if ((double)(screenPosition.Y / 16f) < worldSurface + 2.0)
72721 {
72723 }
72724 DrawSurfaceBG();
72725 spriteBatch.End();
72726 for (int m = 0; m < numClouds; m++)
72727 {
72728 cloud[m].position = array4[m];
72729 }
72730 scAdj = num2;
72735 }
72737 {
72738 spriteBatch.Begin();
72740 spriteBatch.End();
72741 }
72742 if (captureEntities)
72743 {
72744 spriteBatch.Begin();
72745 CacheNPCDraws();
72748 spriteBatch.End();
72749 }
72751 {
72752 spriteBatch.Begin();
72753 spriteBatch.Draw(TextureAssets.MagicPixel.Value, Vector2.Zero, (Rectangle?)null, Color.Black * shimmerAlpha, 0f, Vector2.Zero, new Vector2(Camera.UnscaledSize.X + (float)(offScreenRange * 2), Camera.UnscaledSize.Y + (float)(offScreenRange * 2)), (SpriteEffects)0, 0f);
72754 spriteBatch.End();
72755 }
72756 tileBatch.Begin();
72757 spriteBatch.Begin();
72759 tileBatch.End();
72760 spriteBatch.End();
72761 tileBatch.Begin();
72762 spriteBatch.Begin();
72763 if (biome == null)
72764 {
72766 }
72767 else
72768 {
72769 DrawLiquid(bg: true, bloodMoon ? 9 : biome.WaterStyle);
72770 }
72771 tileBatch.End();
72772 spriteBatch.End();
72774 {
72775 spriteBatch.Begin((SpriteSortMode)0, BlendState.AlphaBlend, DefaultSamplerState, (DepthStencilState)null, (RasterizerState)null, (Effect)null);
72778 spriteBatch.End();
72780 }
72782 {
72783 tileBatch.Begin();
72784 spriteBatch.Begin();
72786 tileBatch.End();
72787 spriteBatch.End();
72788 }
72789 tileBatch.Begin();
72790 spriteBatch.Begin();
72791 DrawWalls();
72792 tileBatch.End();
72793 spriteBatch.End();
72794 if (captureEntities)
72795 {
72796 spriteBatch.Begin();
72797 DrawWoF();
72798 spriteBatch.End();
72799 }
72801 {
72802 spriteBatch.Begin();
72804 spriteBatch.End();
72805 drawBackGore = true;
72806 }
72807 if (captureEntities)
72808 {
72809 spriteBatch.Begin();
72812 spriteBatch.End();
72813 }
72814 bool flag3 = false;
72815 bool intoRenderTargets = false;
72816 bool intoRenderTargets2 = false;
72819 tileBatch.Begin();
72820 spriteBatch.Begin();
72822 int waterStyleOverride = (bloodMoon ? 9 : biome.WaterStyle);
72823 if (biome == null)
72824 {
72826 }
72827 else
72828 {
72830 }
72831 tileBatch.End();
72832 spriteBatch.End();
72834 if (captureEntities)
72835 {
72836 spriteBatch.Begin();
72837 tileBatch.Begin();
72840 tileBatch.End();
72841 spriteBatch.End();
72842 }
72843 if (captureEntities)
72844 {
72846 spriteBatch.Begin();
72847 DrawNPCs(behindTiles: true);
72848 spriteBatch.End();
72849 }
72851 tileBatch.Begin();
72852 spriteBatch.Begin();
72853 if (biome == null)
72854 {
72856 }
72857 else
72858 {
72860 }
72861 tileBatch.End();
72862 spriteBatch.End();
72864 if (captureEntities)
72865 {
72868 spriteBatch.Begin();
72869 DrawNPCs();
72870 spriteBatch.End();
72871 spriteBatch.Begin();
72873 spriteBatch.End();
72879 spriteBatch.Begin();
72881 spriteBatch.End();
72882 spriteBatch.Begin();
72883 DrawItems();
72884 spriteBatch.End();
72885 spriteBatch.Begin();
72886 DrawRain();
72887 spriteBatch.End();
72888 spriteBatch.Begin();
72889 DrawGore();
72890 spriteBatch.End();
72891 DrawDust();
72892 }
72893 tileBatch.Begin();
72894 spriteBatch.Begin();
72895 if (biome == null)
72896 {
72898 }
72899 else
72900 {
72901 DrawLiquid(bg: false, biome.WaterStyle);
72902 }
72903 if (captureMech)
72904 {
72905 DrawWires();
72906 }
72907 tileBatch.End();
72908 spriteBatch.End();
72910 if (mapEnabled)
72911 {
72912 spriteBatch.Begin();
72913 for (int n = area.X; n < area.X + area.Width; n++)
72914 {
72915 for (int num9 = area.Y; num9 < area.Y + area.Height; num9++)
72916 {
72917 if (!Map.IsRevealed(n, num9))
72918 {
72919 spriteBatch.Draw(TextureAssets.BlackTile.Value, new Vector2((float)n * 16f, (float)num9 * 16f) - screenPosition, Color.Black);
72920 }
72921 }
72922 }
72923 spriteBatch.End();
72924 }
72925 renderCount = 99;
72931 cloudAlpha = num12;
72932 bgAlphaFrontLayer = array;
72934 SceneMetrics.HolyTileCount = holyTileCount;
72935 Lighting.Initialize();
72937 }
void PreDrawTiles(bool solidLayer, bool forRenderTargets, bool intoRenderTargets)
static void DrawExplosions(SpriteBatch spriteBatch)
static void DrawPieces(SpriteBatch spriteBatch)
static Asset< Texture2D > BlackTile
static Asset< Texture2D > MagicPixel
static void SetDesiredZoomContext(ZoomContext context)
static bool drawBackGore
Definition Main.cs:415
static Cloud[] cloud
Definition Main.cs:1471
static SceneMetrics SceneMetrics
Definition Main.cs:1441
float scAdj
Definition Main.cs:2668
void DrawTiles(bool solidLayer, bool forRenderTargets, bool intoRenderTargets, int waterStyleOverride=-1)
Definition Main.cs:21278
static int maxTilesY
The height of the currently-loaded world in tiles.
Definition Main.cs:1191
void DrawDust()
Definition Main.cs:49993
static void SetBackColor(InfoToSetBackColor info, out Color sunColor, out Color moonColor)
Definition Main.cs:80508
void DrawSuperSpecialProjectiles(List< int > projCache, bool startSpriteBatch=true)
Definition Main.cs:49123
void DrawWires()
Definition Main.cs:74315
List< int > DrawCacheNPCProjectiles
Definition Main.cs:2320
void DrawLiquid(bool bg=false, int waterStyle=0, float Alpha=1f, bool drawSinglePassLiquids=true)
Definition Main.cs:73184
static float cloudAlpha
Definition Main.cs:1393
static float GraveyardVisualIntensity
Definition Main.cs:1490
void UpdateBGVisibility_BackLayer(int? targetBiomeOverride, float? transitionAmountOverride)
Definition Main.cs:81213
void DrawStarsInBackground(SceneArea sceneArea, bool artificial)
Definition Main.cs:79903
static Color ColorOfSurfaceBackgroundsBase
Definition Main.cs:2662
void DrawPlayers_BehindNPCs()
Definition Main.cs:21861
static Color ColorOfTheSkies
Definition Main.cs:2660
void DrawItems()
Definition Main.cs:49927
void DrawRain()
Definition Main.cs:49935
WaterfallManager waterfallManager
Definition Main.cs:421
static Color ColorOfSurfaceBackgroundsModified
Definition Main.cs:2664
static SpriteBatch spriteBatch
Definition Main.cs:1043
static double worldSurface
The y-coordinate of the top of the dirt layer, in tile coordinates. Corresponds to 0' on the Depth Me...
Definition Main.cs:1351
static int numClouds
Definition Main.cs:1453
static int waterStyle
Definition Main.cs:1283
TileDrawing TilesRenderer
Definition Main.cs:2486
static float[] liquidAlpha
Definition Main.cs:1281
void DrawBlack(bool force=false)
Definition Main.cs:73870
static int netMode
Denotes the current network mode: 0 for single player client, 1 for multiplayer client,...
Definition Main.cs:2182
static bool drawToScreen
Definition Main.cs:628
void DrawWalls()
Definition Main.cs:74033
void DrawSimpleSurfaceBackground(Vector2 areaPosition, int areaWidth, int areaHeight)
Definition Main.cs:72376
static void ApplyColorOfTheSkiesToTiles()
Definition Main.cs:80130
List< int > DrawCacheNPCsBehindNonSolidTiles
Definition Main.cs:2322
void DrawWoF()
Definition Main.cs:49289
static bool bloodMoon
Definition Main.cs:1387
List< int > DrawCacheFirstFractals
Definition Main.cs:2334
List< int > DrawCacheProjsBehindNPCsAndTiles
Definition Main.cs:2324
List< int > DrawCacheNPCsOverPlayers
Definition Main.cs:2318
void CacheProjDraws()
Definition Main.cs:49013
static int screenHeight
Definition Main.cs:1870
static Vector2 screenPosition
The position of the top left corner of the screen in world coordinates. Modify in M:Terraria....
Definition Main.cs:1864
void DrawSurfaceBG()
Definition Main.cs:75602
static Matrix Transform
Definition Main.cs:2932
static int maxTilesX
The width of the currently-loaded world in tiles.
Definition Main.cs:1186
void DrawPlayers_AfterProjectiles()
Definition Main.cs:21867
void DrawCachedNPCs(List< int > npcCache, bool behindTiles)
Definition Main.cs:49079
static SpriteViewMatrix GameViewMatrix
Definition Main.cs:255
static int offScreenRange
Definition Main.cs:905
void DrawGore()
Definition Main.cs:21350
List< int > DrawCacheProjsBehindNPCs
Definition Main.cs:2326
static float[] bgAlphaFrontLayer
Definition Main.cs:881
List< int > DrawCacheProjsOverWiresUI
Definition Main.cs:2330
void DrawSunAndMoon(SceneArea sceneArea, Color moonColor, Color sunColor, float tempMushroomInfluence)
Definition Main.cs:79659
static TileBatch tileBatch
Definition Main.cs:1045
List< int > DrawCacheNPCsMoonMoon
Definition Main.cs:2316
static SamplerState DefaultSamplerState
Definition Main.cs:2978
void DrawGoreBehind()
Definition Main.cs:21283
static RasterizerState Rasterizer
Definition Main.cs:580
void DrawCachedProjs(List< int > projCache, bool startSpriteBatch=true)
Definition Main.cs:49094
static bool mapEnabled
Definition Main.cs:975
void DrawNPCs(bool behindTiles=false)
Definition Main.cs:21897
void UpdateBGVisibility_FrontLayer(int? targetBiomeOverride, float? transitionAmountOverride)
Definition Main.cs:81180
void CacheNPCDraws()
Definition Main.cs:48940
static int screenWidth
Definition Main.cs:1868
static float[] bgAlphaFarBackLayer
Definition Main.cs:883
void DrawTileEntities(bool solidLayer, bool overRenderTargets, bool intoRenderTargets)
Definition Main.cs:21195
void DrawProjectiles()
Definition Main.cs:21748
static bool gameMenu
Definition Main.cs:2076
static float shimmerAlpha
Definition Main.cs:1077
void DrawUnderworldBackground(bool flat)
Definition Main.cs:67083
static bool mapFullscreen
Definition Main.cs:1001
List< int > DrawCacheProjsBehindProjectiles
Definition Main.cs:2328
void DrawBackground()
Definition Main.cs:67299
static int renderCount
Definition Main.cs:1037
static Dust[] dust
Definition Main.cs:1822
List< int > DrawCacheProjsOverPlayers
Definition Main.cs:2332
void Draw(SpriteBatch spriteBatch)
void FindWaterfalls(bool forced=false)

References Terraria.Main.ApplyColorOfTheSkiesToTiles(), Terraria.Main.bgAlphaFarBackLayer, Terraria.Main.bgAlphaFrontLayer, Terraria.GameContent.TextureAssets.BlackTile, Terraria.Main.bloodMoon, Terraria.Main.CacheNPCDraws(), Terraria.Main.CacheProjDraws(), Terraria.Main.cloud, Terraria.Main.cloudAlpha, Terraria.Main.ColorOfSurfaceBackgroundsBase, Terraria.Main.ColorOfSurfaceBackgroundsModified, Terraria.Main.ColorOfTheSkies, Terraria.Main.DefaultSamplerState, Terraria.WaterfallManager.Draw(), Terraria.Main.drawBackGore, Terraria.Main.DrawBackground(), Terraria.Main.DrawBlack(), Terraria.Main.DrawCachedNPCs(), Terraria.Main.DrawCachedProjs(), Terraria.Main.DrawCacheFirstFractals, Terraria.Main.DrawCacheNPCProjectiles, Terraria.Main.DrawCacheNPCsBehindNonSolidTiles, Terraria.Main.DrawCacheNPCsMoonMoon, Terraria.Main.DrawCacheNPCsOverPlayers, Terraria.Main.DrawCacheProjsBehindNPCs, Terraria.Main.DrawCacheProjsBehindNPCsAndTiles, Terraria.Main.DrawCacheProjsBehindProjectiles, Terraria.Main.DrawCacheProjsOverPlayers, Terraria.Main.DrawCacheProjsOverWiresUI, Terraria.Main.DrawDust(), Terraria.GameContent.Events.MoonlordDeathDrama.DrawExplosions(), Terraria.Main.DrawGore(), Terraria.Main.DrawGoreBehind(), Terraria.Main.DrawItems(), Terraria.Main.DrawLiquid(), Terraria.Main.DrawNPCs(), Terraria.GameContent.Events.MoonlordDeathDrama.DrawPieces(), Terraria.Main.DrawPlayers_AfterProjectiles(), Terraria.Main.DrawPlayers_BehindNPCs(), Terraria.Main.DrawProjectiles(), Terraria.Main.DrawRain(), Terraria.Main.DrawSimpleSurfaceBackground(), Terraria.Main.DrawStarsInBackground(), Terraria.Main.DrawSunAndMoon(), Terraria.Main.DrawSuperSpecialProjectiles(), Terraria.Main.DrawSurfaceBG(), Terraria.Main.DrawTileEntities(), Terraria.Main.DrawTiles(), Terraria.Main.drawToScreen, Terraria.Main.DrawUnderworldBackground(), Terraria.Main.DrawWalls(), Terraria.Main.DrawWires(), Terraria.Main.DrawWoF(), Terraria.Main.dust, Terraria.WaterfallManager.FindWaterfalls(), Terraria.Main.gameMenu, Terraria.Main.GameViewMatrix, Terraria.Main.GraveyardVisualIntensity, Terraria.SceneMetrics.HallowTileMax, Terraria.SceneMetrics.HolyTileCount, Terraria.Lighting.Initialize(), Terraria.GameContent.Liquid.LiquidRenderer.Instance, Terraria.GameContent.Events.LanternNight.LanternsUp, Terraria.Lighting.LightTiles(), Terraria.Main.liquidAlpha, Terraria.GameContent.TextureAssets.MagicPixel, Terraria.Main.mapEnabled, Terraria.Main.mapFullscreen, Terraria.Main.maxTilesX, Terraria.Main.maxTilesY, Terraria.Main.netMode, Terraria.Main.numClouds, Terraria.Main.offScreenRange, Terraria.GameContent.Drawing.TileDrawing.PreDrawTiles(), Terraria.Main.Rasterizer, Terraria.Main.renderCount, Terraria.Main.scAdj, Terraria.Main.screenHeight, Terraria.Main.screenPosition, Terraria.Main.screenWidth, Terraria.WorldGen.SectionTileFrameWithCheck(), Terraria.Main.SetBackColor(), Terraria.GameInput.PlayerInput.SetDesiredZoomContext(), Terraria.GameInput.PlayerInput.SetZoom_Unscaled(), Terraria.Main.shimmerAlpha, Terraria.GameContent.Drawing.TileDrawing.SpecificHacksForCapture(), Terraria.Main.spriteBatch, Terraria.Main.tileBatch, Terraria.Main.TilesRenderer, Terraria.Main.Transform, Terraria.Graphics.Camera.UnscaledSize, Terraria.Main.UpdateBGVisibility_BackLayer(), Terraria.Main.UpdateBGVisibility_FrontLayer(), Terraria.Main.waterfallManager, Terraria.Main.waterStyle, and Terraria.Main.worldSurface.

+ Here is the call graph for this function: