mcbot/cmds/misc.lua
changeset 0 89add07d6fe4
child 16 064a50911e05
equal deleted inserted replaced
-1:000000000000 0:89add07d6fe4
       
     1 
       
     2 local function hello (args)
       
     3     return "Hello!"
       
     4 end
       
     5 
       
     6 mcbot_register_command("hello", hello)
       
     7 mcbot_register_command("hi", hello)
       
     8 
       
     9 
       
    10 local function thanks (args)
       
    11     return "You're welcome"
       
    12 end
       
    13 
       
    14 mcbot_register_command("thanks", thanks)
       
    15 
       
    16 
       
    17 local function help (args)
       
    18     return "I can't help you, buddy"
       
    19 end
       
    20 
       
    21 mcbot_register_command("help", help)
       
    22 
       
    23 
       
    24 local function ping (args)
       
    25     return "pong"
       
    26 end
       
    27 
       
    28 mcbot_register_command("ping", ping)
       
    29 
       
    30 
       
    31 local function date (args)
       
    32     if args then
       
    33         return os.date(args)
       
    34     else
       
    35         return os.date()
       
    36     end
       
    37 end
       
    38 
       
    39 mcbot_register_command("date", date)