------------------------------------
-- Commmand Related Functionality --
------------------------------------
local AddOnName, nsVars = ...
local ss = nsVars.SS

--slash command method
local function CommandFunc(msg)
  local cmd, rest = msg:match("^(%S*)%s*(.-)$");
  local restdouble2
  rest, restdouble2 = rest:match("^(%S*)%s*(.-)$");

  if cmd == "nuke" then
    ss:ResetSpheres()
  elseif cmd == "r" then
    ReloadUI()
  else
    ss:ToggleConfig()
  end
end

--setup the slash command stuff, hide the GUI
SlashCmdList["SS"] = CommandFunc;
SLASH_SS1 = "/ss";
