diff --git a/Epic_Not_Here_Counter/Epic_Not_Here_Counter.xml b/Epic_Not_Here_Counter/Epic_Not_Here_Counter.xml index 779ea4c..fe60efa 100644 --- a/Epic_Not_Here_Counter/Epic_Not_Here_Counter.xml +++ b/Epic_Not_Here_Counter/Epic_Not_Here_Counter.xml @@ -84,7 +84,21 @@ for k,v in pairs(group_table) do end EnableTrigger("End_Area", false) -Send("gt @W" .. #not_in_area .. " @Ymember(s) not in the area: @W" .. table.concat(not_in_area, ", ") .. "$C") +if SetCounterDebug == 0 then + Send("gt @W" .. #not_in_area .. " @Ymember(s) not in the area: @W" .. table.concat(not_in_area, ", ") .. "$C") +else + ColourNote("white", "darkcyan", "Epic Not Here debugging information!") + print("Epic Group") + for _,v in ipairs(epicgroup.members) do + print(v.name) + end + print("Group Table") + for k,v in pairs(group_table) do + print(k, v) + end + print("Not in Area") + print(table.concat(not_in_area, ", ")) +end if group_table["%1"] then group_table["%1"] = 1 -end +end + > group_table = {} -for _,v in ipairs(epic_group_members) do +for _,v in ipairs(epicgroup.members) do group_table[v.name] = 0 + print(v.name) end EnableTrigger("PlayersNear", true) Send("where") Send("echo") + + if "%1" == "on" then + SetCounterDebug = 1 + ColourNote("white", "darkcyan", "Epic Not Here debugging on!") + else + SetCounterDebug = 0 + ColourNote("white", "darkcyan", "Epic Not Here debugging off!") + end + + @@ -151,8 +184,9 @@ Send("echo") @@ -165,11 +199,19 @@ end function OnPluginBroadcast(msg, id, name, text) if (id == '3e7dedbe37e44942dd46d264') and (text == 'group') then - local res, group = CallPlugin("3e7dedbe37e44942dd46d264", "gmcpval", "group.members") + local res, group = CallPlugin("3e7dedbe37e44942dd46d264", "gmcpval", "group") - assert( loadstring( "epic_group_members = " .. group or "")) () + if group then + assert( loadstring( "epicgroup = " .. group or "")) () + else + epicgroup = {} + end end end + +function OnPluginInstall() + SetCounterDebug = 0 +end ]]>