Shampaggon / CrackShot

CrackShot plugin for Minecraft
58 stars 43 forks source link

Weapon straight up refuses to function, despite working code; see details. #77

Open SoldatChan opened 4 years ago

SoldatChan commented 4 years ago

I wanted to create a paired melee and ranged weapon, where the ranged weapon "ate health"(Harming I) and the melee weapon "drained health"(Healing I). It worked at first, but now I changed the damage value for the "melee" weapon(technically its an energy weapon) and it broke, but not entirely. It still is fully capable of switching modes, and the second mode is fully functional, but the first one isn't... unless I take the "broken" code out of it, create a new weapon from it, and use it. The new weapon works fine, despite using the "broken" weapon's [Shooting] module. I can't figure it out, so I figured I would ask the (hopefully) experts, if such see this.

Here is the code pasted; if you think the issue is formatting, I have also provided a .txt

Avarice: Item_Information: Item_Name: "&4Avarice &6and &5Anguish" Item_Type: enchanted_book ##netherite_sword Item_Lore: "&1Relic|&4Avarice&6:|&6Heals user on hit|&6Immobilizes victims|&6Can be changed into &5Anguish&6.|&5Anguish&6:|&6Infinite Range|&cUses wielder's health as ammo|&6Can be changed into &4Avarice&6." Inventory_Control: Relic Attachments: Type: main Info: Anguish Toggle_Delay: 10 Sounds_Toggle: BLOCK_PORTAL_TRAVEL-1-1-0 Sounds_Acquired: BAT_TAKEOFF-1-1-0 Remove_Unused_Tag: true Shooting: Right_Click_To_Shoot: false Cancel_Right_Click_Interactions: true Delay_Between_Shots: 10 Projectile_Amount: 1 Projectile_Type: energy Projectile_Subtype: 1-1-NONE-0 Projectile_Speed: 1 Projectile_Damage: 5 Bullet_Spread: 0 Sounds_Shoot: ENTITY_ENDERMAN_TELEPORT-1-1-0 Custom_Death_Message: Normal: "&6 lost everything to &4Avarice&6." Potion_Effects: Activation: hit Potion_Effect_Shooter: HEAL-1-1 Potion_Effect_Victim: SLOW_DIGGING-50-1,WEAKNESS-50-1,SLOW-50-1,LEVITATION-50-1,GLOWING-50-1 Abilities: Death_No_Drop: true Reset_Hit_Cooldown: true Knockback: 0 Hurt_Effect: true Hit_Events: Enable: true Sounds_Impact: ENTITY_ELDER_GUARDIAN_CURSE-1-1-0 Sounds_Victim: ENTITY_ELDER_GUARDIAN_CURSE-1-1-0 Anguish: Item_Information:

Item_Name: "&4An&5gui&1sh"

Item_Type: netherite_shovel

Item_Lore: "&4Unique Relic|&6Infinite Range|&cUses wielder's health as ammo|&6Can be changed into &4Avarice&6."

Attachments: Type: accessory Toggle_Delay: 10 Sounds_Toggle: BLOCK_PORTAL_TRAVEL-1-1-0 Sounds_Acquired: BAT_TAKEOFF-1-1-0 Remove_Unused_Tag: true Shooting: Right_Click_To_Shoot: false Cancel_Right_Click_Interactions: true Delay_Between_Shots: 50 Projectile_Amount: 1 Projectile_Type: arrow Remove_Arrows_On_Impact: true Remove_Bullet_Drop: true Projectile_Speed: 20 Projectile_Damage: 5 Bullet_Spread: 0 Sounds_Shoot: ENTITY_FIREWORK_ROCKET_LARGE_BLAST-1-1-0,ENTITY_FIREWORK_ROCKET_LAUNCH-1-1-0,ENTITY_FIREWORK_ROCKET_SHOOT-1-1-0,ENTITY_FIREWORK_ROCKET_TWINKLE-1-1-0 Burstfire: Enable: true Shots_Per_Burst: 5 Delay_Between_Shots_In_Burst: 1 Custom_Death_Message: Normal: "&6 was doused in the flames &5Anguish&6." Potion_Effects: Activation: shoot Potion_Effect_Shooter: HARM-1-1

Potion_Effect_Victim: SLOW-50-1,GLOWING-50-1,LEVITATION-50-1

Abilities: Death_No_Drop: true Reset_Hit_Cooldown: true Knockback: -1 Hurt_Effect: true Hit_Events: Enable: true Sounds_Impact: ENTITY_ELDER_GUARDIAN_CURSE-1-1-0 Sounds_Victim: ENTITY_ELDER_GUARDIAN_CURSE-1-1-0

TrulyTails commented 3 years ago

It actually is a format issue.. line 53, column 40 had wrong indention on "Cancel_Right_Click_Interactions: true" FixedAvariceAnguish - Copy.txt

SoldatChan commented 3 years ago

This is why I prefer working with Lua or C#. Thanks @TrulyTails for fixing it.

SirMrStep commented 3 years ago

If your issue is solved could you close your issue? (button next to the comment button)