Advertisement
Guest User

mymod settingstypes.txt and init.lua

a guest
Jan 27th, 2021
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.40 KB | None | 0 0
  1. -- Snip from my settingstypes.txt file
  2. mymod_allow_command_line (Allow mymod to be accessed via command) bool true
  3. -- End Snip
  4.  
  5. -- Snip from my init.lua file
  6. local mymod_command_access = minetest.settings:get_bool("mymod_allow_command_line", false)
  7. if mymod_command_access then
  8.     -- Here is where I register a command /mymod_ping
  9.     -- /mymod_ping simply responds with pong in chat
  10. end
  11. -- End Snip
  12.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement