lua: TextRPG.lua:15: attempt to call global 'command' (a nil value) -
i know 1 has been asked cant find helps, heres code:
print("welcome text rpg \n"); function commmand() print("what want do? \(\"help\" help\) \n note: must in caps") input = io.read() --condition = input == "help" or input == "east" or input == "west" or input =="north" or input == "south" or input == "shop" if input == "help" or input == "east" or input == "west" or input =="north" or input== "south" or input == "shop" --future game code end end command()
i tried searching couldent find answer, made account ask this
print("welcome text rpg \n"); function command() print("what want do? \(\"help\" help\) \n note: must in caps") input = io.read() --condition = input == "help" or input == "east" or input == "west" or input =="north" or input == "south" or input == "shop" if input == "help" or input == "east" or input == "west" or input =="north" or input== "south" or input == "shop" --future game code end end command()
you need change:
function commmand()
to
function command()
note removed m
.
Comments
Post a Comment