//in Terraria.Main.DrawDust before universal dust drawing call // ModDust modDust = ModDust.GetDust(dust.type); // if(modDust != null) { modDust.Draw(dust, color5, scale); continue; } internal void Draw(Dust dust, Color alpha, float scale) { Main.spriteBatch.Draw(Texture2D, dust.position - Main.screenPosition, dust.frame, alpha, dust.rotation, new Vector2(4f, 4f), scale, SpriteEffects.None, 0f); if (dust.color != default) { Main.spriteBatch.Draw(Texture2D, dust.position - Main.screenPosition, dust.frame, dust.GetColor(alpha), dust.rotation, new Vector2(4f, 4f), scale, SpriteEffects.None, 0f); } if (alpha == Color.Black) { dust.active = false; } }
//in Terraria.Main.DrawDust before universal dust drawing call // ModDust modDust = ModDust.GetDust(dust.type); // if(modDust != null) { modDust.Draw(dust, color5, scale); continue; } internal void Draw(Dust dust, Color alpha, float scale) { Main.spriteBatch.Draw(Texture, dust.position - Main.screenPosition, new Microsoft.Xna.Framework.Rectangle?(dust.frame), alpha, dust.rotation, new Vector2(4f, 4f), scale, SpriteEffects.None, 0f); if (dust.color != default(Microsoft.Xna.Framework.Color)) { Main.spriteBatch.Draw(Texture, dust.position - Main.screenPosition, new Microsoft.Xna.Framework.Rectangle?(dust.frame), dust.GetColor(alpha), dust.rotation, new Vector2(4f, 4f), scale, SpriteEffects.None, 0f); } if (alpha == Microsoft.Xna.Framework.Color.Black) { dust.active = false; } }