diff options
author | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2011-08-03 23:20:29 +0200 |
---|---|---|
committer | Yohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer> | 2011-08-03 23:20:29 +0200 |
commit | d11e7d49edb8374767d69859fe9ed542722013fe (patch) | |
tree | 619adb5b81a71337f0a180502ab96cac8307b055 /example/serverdata/scripts/crafting.lua | |
parent | 8a43d694173fa0197597ed54c4df4d89c3002e4f (diff) | |
download | manaserv-d11e7d49edb8374767d69859fe9ed542722013fe.tar.gz manaserv-d11e7d49edb8374767d69859fe9ed542722013fe.tar.bz2 manaserv-d11e7d49edb8374767d69859fe9ed542722013fe.tar.xz manaserv-d11e7d49edb8374767d69859fe9ed542722013fe.zip |
Unified the lua.cpp documentation.
I also changed the chatmessage function to chat_message
to follow the coding standard.
Diffstat (limited to 'example/serverdata/scripts/crafting.lua')
-rw-r--r-- | example/serverdata/scripts/crafting.lua | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/example/serverdata/scripts/crafting.lua b/example/serverdata/scripts/crafting.lua index ea306289..eae26a41 100644 --- a/example/serverdata/scripts/crafting.lua +++ b/example/serverdata/scripts/crafting.lua @@ -27,7 +27,7 @@ function on_craft(ch, recipe) -- uncomment one (but not both!) of the following three lines to enable the
-- example crafting systems
- mana.chatmessage(ch, "There is no crafting in this game world.")
+ mana.chat_message(ch, "There is no crafting in this game world.")
--craft_strict(ch, recipe)
--craft_lax(ch, recipe)
end
@@ -42,10 +42,10 @@ function craft_strict(ch, recipe) 8, -2, --take away the iron
9, -1, --take away the wood
5, 1 ) -- give a sword
- mana.chatmessage(ch, "You've crafted a sword")
+ mana.chat_message(ch, "You've crafted a sword")
return
end
- mana.chatmessage(ch, "This wouldn't create anything useful")
+ mana.chat_message(ch, "This wouldn't create anything useful")
end
-- a primitive example crafting system which doesn't care about item order
@@ -60,10 +60,10 @@ function craft_lax(ch, recipe) 8, -2, --take away the iron
9, -1, --take away the wood
5, 1 ) -- give a sword
- mana.chatmessage(ch, "You've crafted a sword")
+ mana.chat_message(ch, "You've crafted a sword")
return
end
- mana.chatmessage(ch, "This wouldn't create anything useful")
+ mana.chat_message(ch, "This wouldn't create anything useful")
end
-- this turns multiple occurences of the same item into one by adding up
|