Custom Items with Abilities and Stuff (A work in progress)!

roboChicken

New member
Oct 13, 2020
2
0
0
This is a work in progress and probably in a terrible state right now but I will update and add stuff to this as much as I could. Feel free to ping me on the discord channel RoboChicken#2356 or comment down any criticisms and things that I should've done to better improve the scripts.

What it does
This is a simple script allows you to easily attach task scripts unto your item scripts to do cool stuff.
Here are examples of how the skills look:
MKaeucG.gif

6SLkGW3.gif

MHiYbIr.gif

7MQmCM0.gif

For now it covers the triggers for:
- clicking blocks
- damaging entities
- bow shoot
- arrow hit
- shield toggle

I will add more but it should be easy to implement other events if you follow the format.​

How to use
First add the "SkillsHandler.dsc" into your scripts folder and reload.
Then to add the skills on your item scripts you must have a "skills" key then include one or more of these subkeys with the corresponding task script name:
Code:
skills:
    click: (task script)
    attack: (task script)
    bow: (task script)
    arrow: (task script)
    shield: (task script)
note that certain skills will not trigger on items that aren't intended for them e.g. adding "arrow" skill on shields

example script:
Code:
stick_o_wisdom:
  type: item
  material: stick
  display name: stick o' wisdom
  lore:
  - A stick that predicts your future
  skills:
    click: wisdom_foretell
    
wisdom_foretell:
  type: task
  script:
  - narrate "You will never be happy"

Skills Handler: https://one.denizenscript.com/haste/76784

Script samples based on skills:
- Click and attack skill (storm breaker): https://one.denizenscript.com/haste/76788
- Arrow skill: https://one.denizenscript.com/haste/76787
- Bow skill: https://one.denizenscript.com/haste/76786
- Shield skill: https://one.denizenscript.com/haste/76785



changelog:
for ver 0.2:
- added the shield toggle event
- cleaned the predefined tags and added more
 

roboChicken

New member
Oct 13, 2020
2
0
0
I dont know if i should add more and tidy up or completely remove the predefined tags because vs code keeps screaming about it
 

mcmonkey

Administrator
Staff member
Helper
roboChicken said:
I dont know if i should add more and tidy up or completely remove the predefined tags because vs code keeps screaming about it

The definitions: key on task scripts is required if you intend to pass definitions in (even via inject)