Got first token modules working, and a bunch of bugfixes throughout
This commit is contained in:
@ -11,11 +11,6 @@ local localdir = minetest.get_modpath("modpol") .. "/modpol_minetest"
|
||||
dofile (localdir .. "/overrides/interactions.lua")
|
||||
dofile (localdir .. "/overrides/users.lua")
|
||||
|
||||
--testing command for "singleplayer"
|
||||
function modpol.msg(text)
|
||||
modpol.interactions.message("singleplayer",text)
|
||||
end
|
||||
|
||||
-- ===================================================================
|
||||
-- Minetest Chatcommands
|
||||
-- ===================================================================
|
||||
|
@ -34,6 +34,7 @@ regchat(
|
||||
"mptest", {
|
||||
privs = {privs=true},
|
||||
func = function(user)
|
||||
modpol.instance.members = modpol.list_users()
|
||||
modpol.orgs.reset()
|
||||
modpol.interactions.dashboard(user)
|
||||
return true, "Reset orgs"
|
||||
|
@ -20,7 +20,7 @@ priv_to_org.config = {
|
||||
function priv_to_org:initiate(result)
|
||||
local player_privs = minetest.get_player_privs(self.initiator)
|
||||
-- construct table for display
|
||||
local player_privs_table = {"View..."}
|
||||
local player_privs_table = {}
|
||||
for k,v in pairs(player_privs) do
|
||||
if player_privs[k] then
|
||||
table.insert(player_privs_table,k)
|
||||
|
@ -218,6 +218,9 @@ minetest.register_on_player_receive_fields(function (player, formname, fields)
|
||||
function(input)
|
||||
if input == "Yes" then
|
||||
org:call_module(module.slug, pname)
|
||||
elseif input == "No" then
|
||||
modpol.interactions.org_dashboard(
|
||||
pname, org.id)
|
||||
end
|
||||
end)
|
||||
end
|
||||
@ -389,3 +392,10 @@ minetest.register_on_player_receive_fields(function (player, formname, fields)
|
||||
minetest.close_formspec(pname, formname)
|
||||
end
|
||||
end)
|
||||
|
||||
-- TESTING
|
||||
|
||||
--testing command for "singleplayer"
|
||||
function modpol.msg(text)
|
||||
modpol.interactions.message("singleplayer",text)
|
||||
end
|
||||
|
Reference in New Issue
Block a user