Items
Structure
item:
model-data: 499
flags:
- "HIDE_ATTRIBUTES"
- "HIDE_ENCHANTS"
enchants:
- "infinity"
material: "DIAMOND"
name: "<gold>Name"
lore:
- "<blue>Lore"
hide-tooltip: false
placeholders:
single: "<gold>Name"
multiple: "<gold>Names"
attributes:
event:
bypass:
- "BLOCK_BREAK"
cancel:
- "BLOCK_PLACE"
stackable: true
durability: 1
on-break-replacement: "Items/Currency/scrap.yml"
allow-enchant: false
allow-anvil: false
actions:
LEFT_CLICK:
- "[MESSAGE] <green>You left clicked!"
model-data
- Custom model data applied to the item
flags
- Attribute flags the item will have
enchants
- What enchants will the item have
material
- Material
name
- The name of the item
lore
- The lore of the item
hide-tooltip
- Hide the "hover" tooltip of the item
placeholders
- Placeholders to use when the item is mentioned somewhere else
attributes.event.bypass
- Bypasses protected areas mentioned permissions - applies to member permissions
attributes.event.cancel
- Cancels the mentioned event - does not prevent actions from executing
attributes.stackable
- Allow the item to be stacked or not if applicable
attributes.durability
- The item's durability
attributes.on-break-replacement
- The replacement of the item when durability hits 0, leave empty for none
attributes.allow-enchant
- Allow the item to be used inside an enchanting table
attributes.allow-anvil
- Allow the item to be used inside an anvil
actions
- Item actions
Item types
Item type - "consumable"
To make an item have consumable properties it will need the consumable
attribute:
item:
<...>
attributes:
<...>
consumable:
heal: 10
fuel: 1
actions:
RIGHT_CLICK:
1:
conditions:
- if: "%clicked-protection% && %consumable-has-effect%"
then:
- "[SOUND] ui.button.click 1 1"
durability-cost: 1
cancel-event: false
- else-if: "!%clicked-protection%"
then:
- "[MESSAGE] <red>Right click a protection block to use this!"
consumable.heal
- How much to heal per use - Applies only on protectionsconsumable-fuel
- How much to fuel per use - Applies only on protections
Make sure to give it conditions to avoid wasting the item.
Item type - "currency"
To make an item have currency properties it will need the currency
attribute:
item:
<...>
attributes:
<...>
currency: true
currency
- Setting this to true will allow the item to be used as currency
Item type - "protection"
To make an item have protection block properties it will need the protection
attribute:
item:
<...>
attributes:
<...>
protection:
default-status: "Status/default-active.yml" # Starting status the protection should have
upgrades: # Available upgrades
- "Upgrades/range-1.yml"
#- "Upgrades/range-2.yml"
world-whitelist: [] # Override "global-whitelist" from "config.yml"
#- "world"
#- "!world_the_end"
block-material: "IRON_BLOCK" # Material the protection should be when it's placed
particle:
display:
range: 5.5 # Blocks | Display the particles when within X blocks
interval: 2 # Ticks | Spawn the particles every X ticks
member: "Particles/member.yml"
outsider: "Particles/outsider.yml"
ranks:
default:
owner: "Ranks/default-owner.yml"
member: "Ranks/default-member.yml"
outsider: "Ranks/default-outsider.yml"
protection: "Ranks/default-protection.yml"
available:
- "Ranks/default-enforcer.yml"
systems:
health:
amount: 25
capacity: 50
regen:
amount: 1
interval: 60 # Ticks
damage-delay: 100 # Ticks
range:
amount: 5
infinite-y: false
generator:
money:
amount: 25
interval: 2400 # Ticks
capacity: 500
items:
interval: 2400 # Ticks
capacity: 10
generate:
1:
currency: "Items/Currency/scrap.yml"
chance: 20.0
amounts: # Amount : Weight
1: 90
2: 9
4: 1
2:
currency: "Items/Consumables/copper-gear.yml"
chance: 10.0
amounts: # Amount : Weight
1: 90
2: 9
3: 1
storage:
slot-capacity: 10
fuel:
amount: 15
capacity: 25
consume-interval: 72000 # Ticks
price:
money:
amount: 100.0
modify: 0.0
multiply: 1.0
item:
currencies:
1:
currency: "Items/Currency/scrap.yml"
required: true
amount: 1
modify: 0.0
multiply: 1.0
decay:
interval: 216000 # Ticks
price:
money:
amount: 2500.0
item:
currencies:
1:
currency: "Items/Currency/scrap.yml"
required: true
amount: 20
on-redeem:
fuel:
modify: 5
multiply: 1
health:
modify: 5
multiply: 1
generator:
money:
modify: 0
multiply: 0.75
items: # Randomly selected
amount: 0.2 # Percent amount of items to remove
storage:
remove-items: # Randomly selected
amount: 0.2 # Percent amount of items to remove
decay-timer:
reset: true
trap:
radius: 80 # Percent radius of the protection's range
player-cooldown: 100 # Ticks
events:
on-entry:
executables:
- "[EFFECT] SLOWNESS 100 1" # <EFFECT> <TIMER> <AMPLIFIER>
announce:
outsider: true
members: true
damage: # Default damage amount per source - Gets added on top of the item's damage if applicable
blast: 25
tool: 5
none: 1
defense: # Formula: incoming_damage * (scaling_factor / (scaling_factor + defense))
amount: 0
capacity: -1
scaling-factor: 100
augments:
crops:
growth-speed:
multiplier: 1.5
yield-bonus:
chance: 25.0
multiplier: 1.5
multi-harvest:
chance: 10.5
multiplier: 2.0
fertilizer-efficiency:
chance: 75.0
multiplier: 1.5
exp:
chance: 5.0
amount: 1
mobs:
looting:
multiplier: 2.0
exp:
multiplier: 1.25
spawner:
limit:
bonus: 3
interval-reduction:
amount: 20 # Ticks
Item type - "tool"
Tools are mostly regular items, but with actions, conditions and damage.
item:
<...>
attributes:
<...>
protection:
damage: 10 # How much damage the item does against protection blocks
bypass-regen: true # Allow the item to bypass the regen system in some scenarios
actions:
BLOCK_BREAK:
1:
conditions:
- if: "%clicked-other-protection%"
then:
- "[SOUND] block.beacon.deactivate 1.0 1.0"
durability-cost: 1
cancel-event: false
Item type - "weapon"
item:
<...>
attributes:
<...>
protection:
damage: 15 # How much damage the item does against protection blocks
bypass-regen: true # Allow the item to bypass the regen system in some scenarios
weapon:
explosion:
entity: "TNT"
fuse-time: 100 # Ticks | Explode afterwards
glow: true # Make the projectile have a glowing outline
silent: false # Peace and quiet
gravity: 0.08 # How fast should the explosive be pulled down while in the air
power: 3.75 # Explosion strength
incendiary: false # Create fire when exploding
block-break: true # Block breaks when exploding
throw:
enable: true # Spawning the item will be 'thrown' instead of just sitting there, menacingly
entity: "SNOWBALL" # Only use projectile-type entities here
power: 1.4 # Throwing power
velocity: 1.0 # Multiply power by the player's current velocity (the faster the player the further the throw)
bounce:
amount: 10 # How many bounces are allowed before it explodes
from-entities: true # Allow the explosive to bounce from entities -- otherwise explode
from-blocks: true # Allow the explosive to bounce from blocks -- otherwise explode
elasticity: 0.7 # How much velocity to retain after each bounce
actions:
RIGHT_CLICK:
1:
conditions: # Conditions & actions, use only "- finally:" to skip the conditions
- finally:
- "[SPECIAL] spawn-weapon Items/Weapons/breach-charge.yml"
durability-cost: 1 # Durability cost to run (stacks if more than one condition is met and has a cost)
cancel-event: true # Cancel the event (Doesn't work with GUIs) -- Bypasses attribute event cancel
stop: true # Stops any other action to be executed
Last updated