summaryrefslogtreecommitdiff
path: root/readme.md
diff options
context:
space:
mode:
authorWuzzy <wuzzy2@mail.ru>2016-11-15 01:57:01 +0100
committerGitHub <noreply@github.com>2016-11-15 01:57:01 +0100
commit38c504e938e169e0337591b7ffe13863ff21250d (patch)
treee35f4fdc8eda2f3eb67f2ee7bf806bbe7304efff /readme.md
parentab7206e15050b050257c7e45b804dc9b1352d41d (diff)
Add eat trigger, extend existing triggers, add 9 awards (#35)
* Add eat trigger and 2 new awards * Add mushroom eating awards * Add support for counting any eat/dig/craft/place * Update readme * Add 4 builder awards * Update German locale * Update dependencies * Fix mistake in German translation * Revert removal of background
Diffstat (limited to 'readme.md')
-rw-r--r--readme.md31
1 files changed, 27 insertions, 4 deletions
diff --git a/readme.md b/readme.md
index db5fc41..8323513 100644
--- a/readme.md
+++ b/readme.md
@@ -18,10 +18,19 @@ old fork in Carbone, under same license.
* image [optional] - texture name, eg: award_one.png
* background [optional] - texture name, eg: award_one.png
* trigger [optional] [table]
- * type - "dig", "place", "craft", "death", "chat" or "join"
- * (for dig/place type) node - the nodes name
- * (for craft type) item - the items name
- * (for all types) target - how many to dig / place
+ * type - "dig", "place", "craft", "death", "chat", "join" or "eat"
+ * dig type: Dig a node.
+ * node: the dug node type. If nil, all dug nodes are counted
+ * place type: Place a node.
+ * node: the placed node type. If nil, all placed nodes are counted
+ * eat type: Eat an item.
+ * item: the eaten item type. If nil, all eaten items are counted
+ * craft type: Craft something.
+ * item: the crafted item type. If nil, all crafted items are counted
+ * death type: Die.
+ * chat type: Write a chat message.
+ * join type: Join the server.
+ * (for all types) target - how many times to dig/place/craft/etc.
* See Triggers
* secret [optional] - if true, then player needs to unlock to find out what it is.
* on_unlock [optional] - func(name, def)
@@ -101,6 +110,14 @@ Callbacks (register a function to be run)
target = 100
}
+### eat
+
+ trigger = {
+ type = "eat",
+ item = "default:apple",
+ target = 100
+ }
+
## Callbacks relating to triggers
* awards.register_on_dig(func(player, data))
@@ -109,6 +126,9 @@ Callbacks (register a function to be run)
* awards.register_on_place(func(player, data))
* data is player data (see below)
* return award name or null
+* awards.register_on_eat(func(player, data))
+ * data is player data (see below)
+ * return award name or null
* awards.register_on_death(func(player, data))
* data is player data (see below)
* return award name or null
@@ -134,6 +154,9 @@ A list of data referenced/hashed by the player's name.
* craft [table] - craft counter
* modname [table]
* itemname [int]
+ * eat [table] - eat counter
+ * modname [table]
+ * itemname [int]
* deaths
* chats
* joins