rewrote TPJ code a tad
This commit is contained in:
1 parent
b4612b6958
commit
c8fe866ecd
2 files changed
+7
-5
No files matched your search
@@ -10,8 +10,6 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
{
|
||||
public class TacticalPlagueEngine : ModItem
|
||||
{
|
||||
public static int BaseDamage = 52;
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
DisplayName.SetDefault("Tactical Plague Engine");
|
||||
@@ -23,7 +21,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
|
||||
public override void SetDefaults()
|
||||
{
|
||||
Item.damage = BaseDamage;
|
||||
Item.damage = 52;
|
||||
Item.mana = 10;
|
||||
Item.width = 28;
|
||||
Item.height = 20;
|
||||
@@ -46,7 +44,7 @@ namespace CalamityMod.Items.Weapons.Summon
|
||||
{
|
||||
int p = Projectile.NewProjectile(source, position.X, position.Y, velocity.X, velocity.Y, type, damage, knockback, player.whoAmI, 0f, 1f);
|
||||
if (Main.projectile.IndexInRange(p))
|
||||
Main.projectile[p].originalDamage = BaseDamage;
|
||||
Main.projectile[p].originalDamage = Item.damage;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -14,6 +14,7 @@ namespace CalamityMod.Projectiles.Summon
|
||||
public class TacticalPlagueJet : ModProjectile
|
||||
{
|
||||
public static Item FalseGun = null;
|
||||
public static Item PlagueEngine = null;
|
||||
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
@@ -44,9 +45,12 @@ namespace CalamityMod.Projectiles.Summon
|
||||
private static void DefineFalseGun()
|
||||
{
|
||||
int p90ID = ModContent.ItemType<P90>();
|
||||
int TPEID = ModContent.ItemType<TacticalPlagueEngine>();
|
||||
FalseGun = new Item();
|
||||
PlagueEngine = new Item();
|
||||
FalseGun.SetDefaults(p90ID, true);
|
||||
FalseGun.damage = TacticalPlagueEngine.BaseDamage;
|
||||
PlagueEngine.SetDefaults(TPEID, true);
|
||||
FalseGun.damage = PlagueEngine.damage;
|
||||
FalseGun.consumeAmmoOnFirstShotOnly = false;
|
||||
FalseGun.consumeAmmoOnLastShotOnly = false;
|
||||
|
||||
|
||||
Reference in new issue
Block a user