diff --git a/Items/Gloves/FasterSnowballGlove.cs b/Items/Gloves/FasterSnowballGlove.cs index 35a39c9..b718069 100644 --- a/Items/Gloves/FasterSnowballGlove.cs +++ b/Items/Gloves/FasterSnowballGlove.cs @@ -49,7 +49,8 @@ public override void AddRecipes() recipe.AddRecipe(); } - public override void OnConsumeAmmo(Player player) { + public override bool Shoot(Player player, ref Vector2 position, ref float speedX, ref float speedY, ref int type, ref int damage, ref float knockBack) + { const int NUM_DUSTS = 10; float posX = player.position.X; float posY = player.position.Y; @@ -59,6 +60,7 @@ public override void OnConsumeAmmo(Player player) { posX--; posY--; } + return true; } } } \ No newline at end of file diff --git a/Items/Gloves/SnowballGlove.cs b/Items/Gloves/SnowballGlove.cs index f573c89..9bbbaf9 100644 --- a/Items/Gloves/SnowballGlove.cs +++ b/Items/Gloves/SnowballGlove.cs @@ -52,9 +52,10 @@ public override void AddRecipes() /** * My item has the noUseGraphic property because I don't want it to be displayed. * But because of this property I can't call the method MeleeEffects. - * So, in order to have an effect when I use my item, I call the OnConsummeAmmo method. + * So, in order to have an effect when I use my item, I call the Shoot method. */ - public override void OnConsumeAmmo(Player player) { + public override bool Shoot(Player player, ref Vector2 position, ref float speedX, ref float speedY, ref int type, ref int damage, ref float knockBack) + { const int NUM_DUSTS = 5; float posX = player.position.X; float posY = player.position.Y; @@ -64,6 +65,7 @@ public override void OnConsumeAmmo(Player player) { posX--; posY--; } + return true; } } } \ No newline at end of file diff --git a/Items/Snowballs/SnowballWithGrenade.cs b/Items/Snowballs/SnowballWithGrenade.cs index b24bbe9..838e5bd 100644 --- a/Items/Snowballs/SnowballWithGrenade.cs +++ b/Items/Snowballs/SnowballWithGrenade.cs @@ -39,9 +39,8 @@ public override void SetDefaults() item.noMelee = true; item.noUseGraphic = true; - item.ammo = AmmoID.Snowball; + item.ammo = item.type; //No integration with gloves for the moment } - public override void AddRecipes() { ModRecipe recipe = new ModRecipe(mod);