Skript ver: 2.4
Mincraft ver: 1.12.2
I was making a skript about gun which shoots stone button, but the effects when button hits the entity doesn't work and also reloading system doesn't work too. I need some feedback and help to fix my code.
Mincraft ver: 1.12.2
I was making a skript about gun which shoots stone button, but the effects when button hits the entity doesn't work and also reloading system doesn't work too. I need some feedback and help to fix my code.
Code:
On Load:
set {ammo} to 20
command /gun:
trigger:
give 1 of paper named "&6gun" with lore "&fright click - shoot" to player
on right click:
if name of player's tool contains "&6gun":
if {ammo} is 0:
wait 3 seconds
set {ammo} to 20
else:
make player shoot an item projectile of stone button at speed 5
wait 0.3 seconds
reduce {ammo} by 1
on projectile hit:
if event-projectile is stone button:
damage entity by 3 hearts
delete event-projectile