The
config.yml file contains some general settings:
Code (YAML):
jumpBoost
: 1.0
# sets % of default jump boost given when you retract the grapple while looking upwards (and being stationary)
showStatsOnDefaultGrapple
: false
# when false, the stats section of the lore will be omitted on default grapples
grappleNPCs
: false
# whether or not NPCs from the Citizens plugin can be moved with grappling hooks
hookTimeout
: 10.0
# the maximum duration a hook can be in the air (without having latched on to anything) before it is automatically deleted.
# Can be used to prevent stasis chambers
canEnchantGrapples
: true
# sets if players can use enchantment tables to enchant grappling hooks
grapples.json is where the grapple presets can be created and altered.
The jar includes 4 preset grapples, which are automatically generated on startup. These can all be modified or deleted, and more can be added.
The 'default' preset must be present in the file, however its stats (or name, crafting recipe, etc.) can be modified.
Removing presets can cause bugs with already extant grapples. Grapples linked to a defunct preset will be converted to 'default' grapples when they are used.
If any value in the preset is absent it will be substituted with a default value.
In the example below, 'default' is the preset name. This will be used for commands, e.g. '/grapple give @p default'.
The preset name must be unique, without spaces, and it is
not case-sensitive ('default' and 'DEFAULT' are the same). If there are issues, a notice will be printed in the console.
The displayName is what appears on the grapple item itself. §6 is a colour code.
Most of it is self explanatory. It is worth noting that if 'canCraft' is set to false, the contents of 'recipe' will be ignored. If a preset's crafting recipe cannot be generated, a notice will be printed to the console.
Code (Text):
{
"default" : {
"displayName" : "§6Standard Grapple",
"durability" : 200,
"stats" : {
"range" : 50.0,
"hookSpeed" : 3.5,
"strengthBlock" : 10.0,
"strengthEntity" : 5.0,
"pullSpeed" : 1.0,
"reloadTime" : 3.0
},
"canCraft":true,
"recipe" : {
"shape" : [
"a ",
" cr",
" rC"
],
"key" : {
"C":"crossbow",
"a":"arrow",
"r":"redstone",
"c":"chain"
}
}
},
"second_preset" : { ... }
}