-- cheat_menu.lua
-- Define a table to store the cheat codes
local cheats = {
["god_mode"] = false,
["infinite_ammo"] = false,
["level_select"] = false
}
-- Define a function to toggle the cheat codes
function toggle_cheat(cheat)
cheats[cheat] = not cheats[cheat]
print("Cheat '" .. cheat .. "' is now " .. (cheats[cheat] and "enabled" or "disabled"))
end
-- Define a function to display the cheat menu
function show_cheat_menu()
print("Cheat Menu:")
print("1. God Mode")
print("2. Infinite Ammo")
print("3. Level Select")
print("Enter the number of the cheat to toggle it")
end
-- Define a function to handle user input
function handle_input()
local input = io.read()
if input == "1" then
toggle_cheat("god_mode")
elseif input == "2" then
toggle_cheat("infinite_ammo")
elseif input == "3" then
toggle_cheat("level_select")
else
print("Invalid input. Please enter the number of the cheat to toggle it.")
end
end
-- Show the cheat menu and handle user input in a loop
while true do
show_cheat_menu()
handle_input()
end
{"html5":"htmlmixed","css":"css","javascript":"javascript","php":"php","python":"python","ruby":"ruby","lua":"text\/x-lua","bash":"text\/x-sh","go":"go","c":"text\/x-csrc","cpp":"text\/x-c++src","diff":"diff","latex":"stex","sql":"sql","xml":"xml","apl":"apl","asterisk":"asterisk","c_loadrunner":"text\/x-csrc","c_mac":"text\/x-csrc","coffeescript":"text\/x-coffeescript","csharp":"text\/x-csharp","d":"d","ecmascript":"javascript","erlang":"erlang","groovy":"text\/x-groovy","haskell":"text\/x-haskell","haxe":"text\/x-haxe","html4strict":"htmlmixed","java":"text\/x-java","java5":"text\/x-java","jquery":"javascript","mirc":"mirc","mysql":"sql","ocaml":"text\/x-ocaml","pascal":"text\/x-pascal","perl":"perl","perl6":"perl","plsql":"sql","properties":"text\/x-properties","q":"text\/x-q","scala":"scala","scheme":"text\/x-scheme","tcl":"text\/x-tcl","vb":"text\/x-vb","verilog":"text\/x-verilog","yaml":"text\/x-yaml","z80":"text\/x-z80"}