From dc2826f00a9daf522fbad006440b73a63568e16a Mon Sep 17 00:00:00 2001 From: Jaro Schladitz Date: Wed, 8 Feb 2023 10:29:31 -0500 Subject: [PATCH] Diamant plugin --- diamant.py.dir/plugin.py | 13 +++++++++++++ diamant.py.dir/plugin.yml | 7 +++++++ 2 files changed, 20 insertions(+) create mode 100644 diamant.py.dir/plugin.py create mode 100644 diamant.py.dir/plugin.yml diff --git a/diamant.py.dir/plugin.py b/diamant.py.dir/plugin.py new file mode 100644 index 0000000..19dad2b --- /dev/null +++ b/diamant.py.dir/plugin.py @@ -0,0 +1,13 @@ +class DiamantPlugin(PythonPlugin): + def onEnable(self): + pass + + def onCommand(self, sender, command, label, args): + position = sender.getLocation() + position.setX(position.getX() + 2) + + welt = sender.getWorld() + block = welt.getBlockAt(position) + block.setType(bukkit.Material.DIAMOND) + + return True diff --git a/diamant.py.dir/plugin.yml b/diamant.py.dir/plugin.yml new file mode 100644 index 0000000..d6b3212 --- /dev/null +++ b/diamant.py.dir/plugin.yml @@ -0,0 +1,7 @@ +name: Diamant-Plugin +main: DiamantPlugin +version: 1.0 +commands: + diamand: + description: Platziert einen diamant vor dem Spieler + usage: /diamant