Item-Preaction

1.8k Downloads
This plugin, unlike many No-Item Plugins, does not restrict the player from having the item to begin with. I found it more fun to troll the player. Imagine you host a server and you don't want people using Fire Charges or Flint and Steel to burn blocks or other people. Wouldnt it be ironic if when they used a fire charge they set themselves on fire? what about if they blowup (leaving no damage obviously to the environment or others). You can block the use of specific items by utilizing one of 5 built in actions: - BURN - EXPLODE - TELEPORT - KICK - BAN Each item is defined in it's own configuration file. A default example configuration file is included with the zip file, but you can also copy this code:
#ITEM STICK
#ACTION KICK

// This is a comment

-/

This is a Comment Block

the #ITEM tag is very important. it defines the name of the item to be checked against

each file only holds 1 item.

the #ACTION tag specifies the action that will be executed when the player used #ITEM

there are verious parameters for different events:

BURN:
    #TICKS [SERVER_TICKS]
EXPLODE:
    None
KICK:
    None
BAN:
    None
TELEPORT:
    #X [x]
    #Y [y]
    #Z [z]
    #WORLD [world]

files MUST be .ipc [ Item Preaction Config ]

you can include the optional tag #IGNORE_OP [true|false] which if true allows ops to bypass the action.

/-
TELEPORT can be used practically to send people to a Jail. You can define the xyz coords and the world and the player will be teleported. Al commands have deafults for the tags. For BURN the default it set to 200 ticks. For teleport, x y z and world are default set to the curent location of the player, and then are changed. if the player was at 50, 64, 50, and the code specified to teleport: #Z 161 #WORLD World2 the player would teleport to World2@(50x, 64y, 161z)