Suggestions and fixes

- Various dye slot changes for accessory/armor dust spawning
- Lab Hologram Projectors can now face left or right
- Dragonblood Disgorger minor tooltip changes
- Nuclear Rod renamed to Nuclear Fuel Rod
- Graveyard enemies can now drop Blood Orbs
- Nadir now uses Auric Bars and is buffed accordingly
- [1.4.4 fix] Fixed typical spear AI prematurely expiring
- [1.4.4 fix] Fixed Wulfrum Blunderbuss ammo text being misplaced
This commit is contained in:
Altixal committed 2023-07-05 02:40:49 +07:00
1 parent 8913aec8c3
commit 822c673bd1
42 files changed
+94 -103

No files matched your search

+6 -5
View File
@@ -435,7 +435,7 @@ namespace CalamityMod.CalPlayer
public bool eTalisman = false;
public int statisTimer = 0;
public bool nucleogenesis = false;
public bool nuclearRod = false;
public bool nuclearFuelRod = false;
public bool elysianAegis = false;
public bool elysianGuard = false;
public bool nCore = false;
@@ -1581,7 +1581,7 @@ namespace CalamityMod.CalPlayer
eGauntlet = false;
eTalisman = false;
nucleogenesis = false;
nuclearRod = false;
nuclearFuelRod = false;
heartOfDarkness = false;
shadowMinions = false;
holyMinions = false;
@@ -3603,7 +3603,7 @@ namespace CalamityMod.CalPlayer
dust.position.Y += Main.rand.Next(-20, 21);
dust.velocity *= 0.4f;
dust.scale *= 1f + Main.rand.Next(40) * 0.01f;
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.cWaist, Player);
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.ArmorSetDye(), Player);
if (Main.rand.NextBool(2))
{
dust.scale *= 1f + Main.rand.Next(40) * 0.01f;
@@ -3637,7 +3637,7 @@ namespace CalamityMod.CalPlayer
dust.position.Y += Main.rand.Next(-20, 21);
dust.velocity *= 0.4f;
dust.scale *= 1f + Main.rand.Next(40) * 0.01f;
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.cWaist, Player);
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.cNeck, Player);
if (Main.rand.NextBool(2))
{
dust.scale *= 1f + Main.rand.Next(40) * 0.01f;
@@ -3813,7 +3813,8 @@ namespace CalamityMod.CalPlayer
dust.position.Y += Main.rand.Next(-20, 21);
dust.velocity *= 0.9f;
dust.scale *= 1f + Main.rand.Next(40) * 0.01f;
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.cWaist, Player);
// Change this accordingly if we have a proper equipped sprite.
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.cBody, Player);
if (Main.rand.NextBool(2))
dust.scale *= 1f + Main.rand.Next(40) * 0.01f;
}
+4 -4
View File
@@ -1087,7 +1087,7 @@ namespace CalamityMod.CalPlayer
if (voltaicJelly)
Player.maxMinions++;
if (nuclearRod)
if (nuclearFuelRod)
Player.maxMinions++;
}
}
@@ -1379,7 +1379,7 @@ namespace CalamityMod.CalPlayer
Main.dust[green].velocity *= 0.9f;
Main.dust[green].noGravity = true;
Main.dust[green].scale *= 1f + (float)Main.rand.Next(40) * 0.01f;
Main.dust[green].shader = GameShaders.Armor.GetSecondaryShader(Player.cWaist, Player);
Main.dust[green].shader = GameShaders.Armor.GetSecondaryShader(Player.ArmorSetDye(), Player);
if (Main.rand.NextBool(2))
Main.dust[green].scale *= 1f + (float)Main.rand.Next(40) * 0.01f;
}
@@ -1410,7 +1410,7 @@ namespace CalamityMod.CalPlayer
dust.velocity *= 0.9f;
dust.noGravity = true;
dust.scale *= 1f + (float)Main.rand.Next(40) * 0.01f;
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.cWaist, Player);
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.ArmorSetDye(), Player);
if (Main.rand.NextBool(2))
dust.scale *= 1f + (float)Main.rand.Next(40) * 0.01f;
}
@@ -1481,7 +1481,7 @@ namespace CalamityMod.CalPlayer
dust.velocity *= 0.9f;
dust.noGravity = true;
dust.scale *= 1f + (float)Main.rand.Next(40) * 0.01f;
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.cWaist, Player);
dust.shader = GameShaders.Armor.GetSecondaryShader(Player.ArmorSetDye(), Player);
if (Main.rand.NextBool(2))
dust.scale *= 1f + (float)Main.rand.Next(40) * 0.01f;
}
+1 -1
View File
@@ -742,7 +742,7 @@ namespace CalamityMod.CalPlayer
Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<SummonAstralExplosion>(), starburstDamage, 3.5f, proj.owner);
summonProjCooldown = 60f;
}
else if (nuclearRod)
else if (nuclearFuelRod)
{
int nuclearDamage = (int)Player.GetTotalDamage<SummonDamageClass>().ApplyTo(20);
Projectile.NewProjectile(source, proj.Center, Vector2.Zero, ProjectileType<IrradiatedAura>(), nuclearDamage, 0f, proj.owner);
+2 -2
View File
@@ -31,7 +31,7 @@ namespace CalamityMod.CalPlayer.Dashes
holyFireDashDust.velocity += Main.rand.NextVector2Circular(5f, 5f);
holyFireDashDust.velocity *= 0.75f;
holyFireDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
holyFireDashDust.noGravity = true;
holyFireDashDust.fadeIn = 0.5f;
}
@@ -51,7 +51,7 @@ namespace CalamityMod.CalPlayer.Dashes
Dust fireDashDust = Dust.NewDustDirect(player.position + Vector2.UnitY * 4f, player.width, player.height - 8, dashDustID, 0f, 0f, 100, default, 2f);
fireDashDust.velocity *= 0.1f;
fireDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
fireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
fireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
fireDashDust.noGravity = true;
if (Main.rand.NextBool(2))
fireDashDust.fadeIn = 0.5f;
+2 -2
View File
@@ -30,7 +30,7 @@ namespace CalamityMod.CalPlayer.Dashes
holyFireDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
holyFireDashDust.velocity *= 0.2f;
holyFireDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
holyFireDashDust.noGravity = true;
holyFireDashDust.fadeIn = 0.5f;
}
@@ -44,7 +44,7 @@ namespace CalamityMod.CalPlayer.Dashes
Dust holyFireDashDust = Dust.NewDustDirect(player.position + Vector2.UnitY * 4f, player.width, player.height - 8, 246, 0f, 0f, 100, default, 2.75f);
holyFireDashDust.velocity *= 0.1f;
holyFireDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
holyFireDashDust.noGravity = true;
if (Main.rand.NextBool(2))
holyFireDashDust.fadeIn = 0.5f;
+2 -2
View File
@@ -23,7 +23,7 @@ namespace CalamityMod.CalPlayer.Dashes
redDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
redDashDust.velocity *= 0.2f;
redDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
redDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShoe, player);
redDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cNeck, player);
}
}
@@ -44,7 +44,7 @@ namespace CalamityMod.CalPlayer.Dashes
Dust redDashDust = Dust.NewDustDirect(dustSpawnPosition, player.width, dustSpawnHeight, 235, 0f, 0f, 100, default, 1.4f);
redDashDust.velocity *= 0.1f;
redDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
redDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShoe, player);
redDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cNeck, player);
}
}
}
+2 -2
View File
@@ -23,7 +23,7 @@ namespace CalamityMod.CalPlayer.Dashes
iceDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
iceDashDust.velocity *= 0.2f;
iceDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
iceDashDust.noGravity = true;
iceDashDust.fadeIn = 0.5f;
}
@@ -37,7 +37,7 @@ namespace CalamityMod.CalPlayer.Dashes
iceDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
iceDashDust.velocity *= 0.2f;
iceDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
iceDashDust.noGravity = true;
if (Main.rand.NextBool(2))
iceDashDust.fadeIn = 0.5f;
+2 -2
View File
@@ -30,7 +30,7 @@ namespace CalamityMod.CalPlayer.Dashes
holyFireDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
holyFireDashDust.velocity *= 0.2f;
holyFireDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
holyFireDashDust.noGravity = true;
holyFireDashDust.fadeIn = 0.5f;
}
@@ -44,7 +44,7 @@ namespace CalamityMod.CalPlayer.Dashes
Dust holyFireDashDust = Dust.NewDustDirect(player.position + Vector2.UnitY * 4f, player.width, player.height - 8, 246, 0f, 0f, 100, default, 2.75f);
holyFireDashDust.velocity *= 0.1f;
holyFireDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
holyFireDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
holyFireDashDust.noGravity = true;
if (Main.rand.NextBool(2))
holyFireDashDust.fadeIn = 0.5f;
+1 -1
View File
@@ -79,7 +79,7 @@ namespace CalamityMod.CalPlayer.Dashes
cosmiliteDust.position += Main.rand.NextVector2Square(-20f, 20f);
cosmiliteDust.velocity *= 0.9f;
cosmiliteDust.scale *= Main.rand.NextFloat(1f, 1.4f);
cosmiliteDust.shader = GameShaders.Armor.GetSecondaryShader(player.cWaist, player);
cosmiliteDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
if (Main.rand.NextBool(2))
cosmiliteDust.scale *= Main.rand.NextFloat(1f, 1.4f);
}
+2 -2
View File
@@ -28,7 +28,7 @@ namespace CalamityMod.CalPlayer.Dashes
iceDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
iceDashDust.velocity *= 0.2f;
iceDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
iceDashDust.noGravity = true;
iceDashDust.fadeIn = 0.5f;
}
@@ -42,7 +42,7 @@ namespace CalamityMod.CalPlayer.Dashes
iceDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
iceDashDust.velocity *= 0.2f;
iceDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShield, player);
iceDashDust.noGravity = true;
if (Main.rand.NextBool(2))
iceDashDust.fadeIn = 0.5f;
+2 -2
View File
@@ -25,7 +25,7 @@ namespace CalamityMod.CalPlayer.Dashes
iceDashDust.position += Main.rand.NextVector2Square(-5f, 5f);
iceDashDust.velocity *= 0.2f;
iceDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.ArmorSetDye(), player);
iceDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cWaist, player);
iceDashDust.noGravity = true;
iceDashDust.fadeIn = 0.5f;
}
@@ -46,7 +46,7 @@ namespace CalamityMod.CalPlayer.Dashes
Dust purpleDashDust = Dust.NewDustDirect(dustSpawnPosition, player.width, dustSpawnHeight, 70, 0f, 0f, 100, default, 1.4f);
purpleDashDust.velocity *= 0.1f;
purpleDashDust.scale *= Main.rand.NextFloat(1f, 1.2f);
purpleDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cShoe, player);
purpleDashDust.shader = GameShaders.Armor.GetSecondaryShader(player.cWaist, player);
// Periodically release scythes.
player.Calamity().statisTimer++;
@@ -5,7 +5,8 @@ using Terraria.ID;
namespace CalamityMod.Items.Accessories
{
public class NuclearRod : ModItem, ILocalizedModType
[LegacyName("NuclearRod")]
public class NuclearFuelRod : ModItem, ILocalizedModType
{
public new string LocalizationCategory => "Items.Accessories";
public override void SetDefaults()
@@ -19,7 +20,7 @@ namespace CalamityMod.Items.Accessories
public override void UpdateAccessory(Player player, bool hideVisual)
{
player.Calamity().nuclearRod = true;
player.Calamity().nuclearFuelRod = true;
player.buffImmune[ModContent.BuffType<Irradiated>()] = true;
}
}
File renamed without changes.

Before

Width:  |  Height:  |  Size: 580 B

After

Width:  |  Height:  |  Size: 580 B

+1 -1
View File
@@ -34,7 +34,7 @@ namespace CalamityMod.Items.Accessories
{
CreateRecipe().
AddIngredient<JellyChargedBattery>().
AddIngredient<NuclearRod>().
AddIngredient<NuclearFuelRod>().
AddIngredient<StarbusterCore>().
AddIngredient<LifeAlloy>(3).
AddTile(TileID.MythrilAnvil).
@@ -93,7 +93,7 @@ namespace CalamityMod.Items.Fishing.SulphurCatches
ModContent.ItemType<SlitheringEels>(),
ModContent.ItemType<SkyfinBombers>(),
ModContent.ItemType<SpentFuelContainer>(),
ModContent.ItemType<NuclearRod>()
ModContent.ItemType<NuclearFuelRod>()
));
// Pre-HM Abyss Equipment (and Torrential Tear)
+3 -3
View File
@@ -11,12 +11,12 @@ namespace CalamityMod.Items.Weapons.Melee
public class Nadir : ModItem, ILocalizedModType
{
public new string LocalizationCategory => "Items.Weapons.Melee";
public static int BaseDamage = 280;
public static int BaseDamage = 350;
public static float ShootSpeed = 12f;
public override void SetStaticDefaults()
{
ItemID.Sets.Spears[Item.type] = true;
ItemID.Sets.Spears[Item.type] = true;
}
public override void SetDefaults()
@@ -49,8 +49,8 @@ namespace CalamityMod.Items.Weapons.Melee
{
CreateRecipe().
AddIngredient<ElementalLance>().
AddIngredient<AuricBar>(5).
AddIngredient<TwistingNether>(5).
AddIngredient<CosmiliteBar>(8).
AddIngredient<DarksunFragment>(8).
AddTile<CosmicAnvil>().
Register();
+1 -6
View File
@@ -31,11 +31,6 @@ namespace CalamityMod.Items.Weapons.Ranged
public static int ShotsPerScrap = 30;
public int storedScrap = 0;
public override void SetStaticDefaults()
{
//Funny lore quip about how it can perform ecgologically be recyling the scrap parts of the faulty robots youre forced to shoot at as new ammo.
}
public override void SetDefaults()
{
Item.damage = 11;
@@ -178,7 +173,7 @@ namespace CalamityMod.Items.Weapons.Ranged
spriteBatch.Draw(barBG, drawPos, null, colorBG, 0f, origin, scale * barScale, 0f, 0f);
spriteBatch.Draw(barFG, drawPos, frameCrop, colorFG * 0.8f, 0f, origin, scale * barScale, 0f, 0f);
DrawBorderStringEightWay(spriteBatch, FontAssets.MouseText.Value, storedScrap.ToString(), drawPos + new Vector2(-3, -3) * scale, Color.GreenYellow, Color.Black, scale);
DrawBorderStringEightWay(spriteBatch, FontAssets.MouseText.Value, storedScrap.ToString(), drawPos + new Vector2(-30, -3) * scale, Color.GreenYellow, Color.Black, scale);
}
public override void AddRecipes()
@@ -1107,8 +1107,8 @@ NecklaceofVexation: {
'''
}
NuclearRod: {
DisplayName: Nuclear Rod
NuclearFuelRod: {
DisplayName: Nuclear Fuel Rod
Tooltip:
'''
Minions release an irradiated aura on enemy hits
@@ -267,6 +267,7 @@ DragonbloodDisgorger: {
Tooltip:
'''
Summons a skeletal dragon and her two children
Baby spits passively heal the player
Requires 6 minion slots to be summoned
There can only be one family at a time
'''
+2 -2
View File
@@ -515,9 +515,9 @@ namespace CalamityMod.NPCs.AcidRain
// If post-Polter, the drop rates are 10%. Otherwise they're 100%.
// This is accomplished by adding rules if the CONDITION "Post-Polter" fails.
LeadingConditionRule postPolter = npcLoot.DefineConditionalDropSet(() => DownedBossSystem.downedPolterghast);
postPolter.Add(ModContent.ItemType<NuclearRod>(), 10, hideLootReport: !DownedBossSystem.downedPolterghast);
postPolter.Add(ModContent.ItemType<NuclearFuelRod>(), 10, hideLootReport: !DownedBossSystem.downedPolterghast);
postPolter.Add(ModContent.ItemType<SpentFuelContainer>(), 10, hideLootReport: !DownedBossSystem.downedPolterghast);
postPolter.AddFail(ModContent.ItemType<NuclearRod>(), hideLootReport: DownedBossSystem.downedPolterghast);
postPolter.AddFail(ModContent.ItemType<NuclearFuelRod>(), hideLootReport: DownedBossSystem.downedPolterghast);
postPolter.AddFail(ModContent.ItemType<SpentFuelContainer>(), hideLootReport: DownedBossSystem.downedPolterghast);
npcLoot.Add(ModContent.ItemType<CragmawMireTrophy>(), 10);
+9
View File
@@ -487,6 +487,15 @@ namespace CalamityMod.NPCs
break;
#endregion
#region Graveyard
// Alternate Blood Orb obtainment methods (10%)
case NPCID.MaggotZombie:
case NPCID.TheBride:
case NPCID.TheGroom:
npcLoot.Add(ModContent.ItemType<BloodOrb>(), 10);
break;
#endregion
#region Blood Moon
// All Blood Moon enemies
// Drop Blood Orbs @ 100% (25% for common enemies)
@@ -1,4 +1,5 @@
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using System;
using Terraria;
using Terraria.ModLoader;
@@ -34,7 +35,7 @@ namespace CalamityMod.Projectiles.BaseProjectiles
player.itemTime = player.itemAnimation;
// Stick to the player
Projectile.position = player.Center - Projectile.Size / 2f;
Projectile.Center = player.RotatedRelativePoint(player.MountedCenter);
// And move outward/inward based on the speed variable.
Projectile.position += Projectile.velocity * Projectile.ai[0];
@@ -156,6 +157,19 @@ namespace CalamityMod.Projectiles.BaseProjectiles
}
}
public override bool PreDraw(ref Color lightColor)
{
if (SpearAiType == SpearType.TypicalSpear)
{
Texture2D texture = ModContent.Request<Texture2D>(Texture).Value;
Vector2 drawPosition = Projectile.Center - Main.screenPosition;
Vector2 origin = Vector2.Zero;
Main.EntitySpriteDraw(texture, drawPosition, null, Projectile.GetAlpha(lightColor), Projectile.rotation, origin, Projectile.scale, 0, 0);
return false;
}
return base.PreDraw(ref lightColor);
}
#region Virtual Values
// Typical spear virtual values
public virtual float InitialSpeed => 3f;
@@ -9,11 +9,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 70;
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 28;
Projectile.DamageType = DamageClass.Melee;
Projectile.timeLeft = 90;
Projectile.height = 70;
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
+1 -3
View File
@@ -12,11 +12,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = TrueMeleeDamageClass.Instance;
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
+1 -3
View File
@@ -10,11 +10,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = TrueMeleeDamageClass.Instance;
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -9,11 +9,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = TrueMeleeDamageClass.Instance;
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
+1 -4
View File
@@ -10,12 +10,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = DamageClass.Melee; //Dictates whether projectile is a melee-class weapon.
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.scale = 1.5f;
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -10,11 +10,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = DamageClass.Melee; //Dictates whether this is a melee-class weapon.
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -9,11 +9,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = TrueMeleeDamageClass.Instance;
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -8,11 +8,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 54; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = DamageClass.Melee; //Dictates whether this is a melee-class weapon.
Projectile.timeLeft = 90;
Projectile.height = 54; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -11,11 +11,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = DamageClass.Melee; //Dictates whether this is a melee-class weapon.
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -10,11 +10,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40;
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = DamageClass.Melee;
Projectile.timeLeft = 90;
Projectile.height = 40;
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
+2 -4
View File
@@ -11,9 +11,7 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 55;
Projectile.height = 55;
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 56;
Projectile.DamageType = DamageClass.Melee;
Projectile.timeLeft = 90;
Projectile.friendly = true;
@@ -29,7 +27,7 @@ namespace CalamityMod.Projectiles.Melee.Spears
public override float ForwardSpeed => 1.1f;
public override Action<Projectile> EffectBeforeReelback => (proj) =>
{
int damage = Projectile.damage / 4;
int damage = (int)(Projectile.damage * 0.5f);
float kb = Projectile.knockBack * 0.5f;
Vector2 projPos = Projectile.Center + Projectile.velocity;
Vector2 projVel = Projectile.velocity * 0.75f;
@@ -8,11 +8,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 44; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 44;
Projectile.DamageType = TrueMeleeDamageClass.Instance;
Projectile.timeLeft = 90;
Projectile.height = 42; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -9,11 +9,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = DamageClass.Melee; //Dictates whether projectile is a melee-class weapon.
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -12,9 +12,7 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 46; //The width of the .png file in pixels divided by 2.
Projectile.height = 46; //The height of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 46;
Projectile.DamageType = DamageClass.Melee; //Dictates whether projectile is a melee-class weapon.
Projectile.timeLeft = 90;
Projectile.friendly = true;
@@ -9,11 +9,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = DamageClass.Melee; //Dictates whether this is a melee-class weapon.
Projectile.timeLeft = 90;
Projectile.height = 40; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -11,11 +11,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 95; //The width of the .png file in pixels divided by 2.
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 44;
Projectile.DamageType = TrueMeleeDamageClass.Instance;
Projectile.timeLeft = 90;
Projectile.height = 95; //The height of the .png file in pixels divided by 2.
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
@@ -9,11 +9,9 @@ namespace CalamityMod.Projectiles.Melee.Spears
{
public override void SetDefaults()
{
Projectile.width = 40;
Projectile.aiStyle = ProjAIStyleID.Spear;
Projectile.width = Projectile.height = 40;
Projectile.DamageType = TrueMeleeDamageClass.Instance;
Projectile.timeLeft = 90;
Projectile.height = 40;
Projectile.friendly = true;
Projectile.hostile = false;
Projectile.tileCollide = false;
+1 -1
View File
@@ -32,7 +32,7 @@ namespace CalamityMod.Projectiles.Melee
Projectile.ignoreWater = true;
Projectile.alpha = 80;
Projectile.penetrate = 8;
Projectile.penetrate = 4;
Projectile.usesLocalNPCImmunity = true;
Projectile.localNPCHitCooldown = 4;
Projectile.extraUpdates = 1;
@@ -47,6 +47,14 @@ namespace CalamityMod.Tiles.DraedonStructures
ModTileEntity te = ModContent.GetInstance<TELabHologramProjector>();
TileObjectData.newTile.HookPostPlaceMyPlayer = new PlacementHook(te.Hook_AfterPlacement, -1, 0, true);
TileObjectData.newTile.StyleWrapLimit = 2;
TileObjectData.newTile.StyleMultiplier = 2;
TileObjectData.newTile.StyleHorizontal = true;
TileObjectData.newTile.Direction = TileObjectDirection.PlaceRight;
TileObjectData.newAlternate.CopyFrom(TileObjectData.newTile);
TileObjectData.newAlternate.Direction = TileObjectDirection.PlaceLeft;
TileObjectData.addAlternate(1);
TileObjectData.addTile(Type);
AddMapEntry(new Color(99, 131, 199), CalamityUtils.GetItemName<LabHologramProjectorItem>());
AnimationFrameHeight = 112;
@@ -116,12 +124,9 @@ namespace CalamityMod.Tiles.DraedonStructures
frame -= IdleFrames - 2;
}
int xPos = Main.tile[i, j].TileFrameX;
int yPos = Main.tile[i, j].TileFrameY;
// Accomodation for X frames textures.
xPos += frame / 8 * 96;
yPos += frame % 8 * 112;
int xPos = trackTile.TileFrameX;
int yPos = trackTile.TileFrameY;
yPos += frame % 16 * 112;
Texture2D tileTexture = ModContent.Request<Texture2D>("CalamityMod/Tiles/DraedonStructures/LabHologramProjector").Value;
Vector2 offset = Main.drawToScreen ? Vector2.Zero : new Vector2(Main.offScreenRange);
Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.9 KiB

After

Width:  |  Height:  |  Size: 38 KiB