summaryrefslogtreecommitdiffstats
path: root/MCServer/Plugins/ProtectionAreas/Config.lua
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-05-26 21:21:24 +0200
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2013-05-26 21:21:24 +0200
commit9a25f76697c2cf9c48e0ae7ff63b574436e45478 (patch)
tree869870fd8f7dedfc694f222c4c15146240938a72 /MCServer/Plugins/ProtectionAreas/Config.lua
parentProtectionAreas: Initial project import, skeleton code (diff)
downloadcuberite-9a25f76697c2cf9c48e0ae7ff63b574436e45478.tar
cuberite-9a25f76697c2cf9c48e0ae7ff63b574436e45478.tar.gz
cuberite-9a25f76697c2cf9c48e0ae7ff63b574436e45478.tar.bz2
cuberite-9a25f76697c2cf9c48e0ae7ff63b574436e45478.tar.lz
cuberite-9a25f76697c2cf9c48e0ae7ff63b574436e45478.tar.xz
cuberite-9a25f76697c2cf9c48e0ae7ff63b574436e45478.tar.zst
cuberite-9a25f76697c2cf9c48e0ae7ff63b574436e45478.zip
Diffstat (limited to '')
-rw-r--r--MCServer/Plugins/ProtectionAreas/Config.lua33
1 files changed, 33 insertions, 0 deletions
diff --git a/MCServer/Plugins/ProtectionAreas/Config.lua b/MCServer/Plugins/ProtectionAreas/Config.lua
new file mode 100644
index 000000000..c9b131f5c
--- /dev/null
+++ b/MCServer/Plugins/ProtectionAreas/Config.lua
@@ -0,0 +1,33 @@
+
+-- Config.lua
+
+-- Implements the cConfig class that holds the general plugin configuration
+
+
+
+
+
+cConfig = {
+ m_Wand = cItem(E_ITEM_STICK, 1, 1); -- TODO: Make this configurable by loading it from an INI file
+};
+
+
+
+
+
+--- Returns true if a_Item is the wand tool item
+function cConfig:IsWand(a_Item)
+ return (
+ (a_Item.m_ItemType == self.m_Wand.m_ItemType) and
+ (a_Item.m_ItemDamage == self.m_Wand.m_ItemDamage)
+ );
+end
+
+
+
+
+
+--- Returns the wand tool item as a cItem object
+function cConfig:GetWandItem()
+ return self.m_Wand;
+end \ No newline at end of file