ID:170975
 
this is the same ass the offline unmute post i posted earlyer but i cant figure it out how i can do it whit this one

var/list/Admins

world
New()
..()
var/savefile/F = new ("Report/Admin.sav")
F["Admins"] >> Admins
if(isnull(Admins))
Admins = new /list

Del()
var/savefile/F = new ("Report/Admin.sav")
F["Admins"] << Admins
..()

Add_Gm(mob/M in world)
set desc = "() Grant administrative GM powers to someone."
set category = "Admin"
switch(input("What lvl of Gm do you want to give?","Add Gm Powers") in list("GM","Admin","Temporary GM","Cancel"))
if("GM")
if(!M.key)
usr << "You can't make NPCs into GMs! Isn't that obvious?"
return

if(M.GMCheck() || M.AdminGMCheck() || M.MasterGMCheck())
usr << "[M] is already a GM or above."
return
else
world << "[M] is granted GM status by [src]."
GMs += M.key
M.AddGMVerbs()

if("Admin")
if(!M.key)
usr << "You can't make NPCs into GMs! Isn't that obvious?"
return

if(M.AdminGMCheck() || M.MasterGMCheck())
usr << "[M] is already an administrative GM or above."
return
else
if(M.GMCheck())
world << "[M] is upgraded from GM status to Administrative GM status by [src]."
GMs -= M.key
else
world << "[M] is granted Administrative GM status by [src]."
Admins += M.key
M.AddGMVerbs()


if("Temporary GM")
if(M == src)
usr << "There's no point in explaining what's wrong with using a GM verb to make \
yourself temporarily a GM."

return

if(M.GMCheck() || M.AdminGMCheck() || M.MasterGMCheck())
usr << "[M] is already a GM or above."
return
else
M._temp_gm = 1
world.log << "GM [src] (Key: \"[src.key]\") granted temporary GM status to [M] \
(Key: \"
[M.key]\")."
world << "[M] is granted temporary GM powers by [src]."
M.AddGMVerbs()
M << "You now have GM powers until you disconnect from the world."

GM_remove_GM(mob/M in world)
set desc = "() Strip GM powers from someone permanently"
set category = "GM"

if(M == src)
usr << "You can't remove yourself!"
return

if(!M.GMCheck() && !M.AdminGMCheck() && !M.MasterGMCheck())
usr << "[M] has no GM powers."
return

if(GMCheck() || (AdminGMCheck() && !M.GMCheck()))
usr << "You can't strip GM powers from anyone equal to or higher in rank."
M << "[src] tried to strip your GM powers."
return

GMs -= M
Admins -= M
world << "[M]'s GM status was stripped by [src]."
world.log << "GM [src] (Key: \"[src.key]\") removed all GM status from [M] \
(Key: \"
[M.key]\")."
M.RemoveGMVerbs()

GM_remove_Admin(mob/M in world)
set desc = "() Strip administrative GM powers from someone permanently"
set category = "GM"

if(!M.AdminGMCheck())
usr << "[M] isn't an admin!"
return
else
world.log << "GM [src] (Key: \"[src.key]\") removed Admin GM status from [M] \
(Key: \"
[M.key]\")."
Admins -= M.key
M.RemoveGMVerbs()
M.AddGMVerbs()
Try this:
        GM_remove_GM(mob/M in GMs)
set desc = "() Strip GM powers from someone permanently"
set category = "GM"

if(M == src)
usr << "You can't remove yourself!"
return

if(!M.GMCheck() && !M.AdminGMCheck() && !M.MasterGMCheck())
usr << "[M] has no GM powers."
return

if(GMCheck() || (AdminGMCheck() && !M.GMCheck()))
usr << "You can't strip GM powers from anyone equal to or higher in rank."
M << "[src] tried to strip your GM powers."
return

GMs -= M
Admins -= M
world << "[M]'s GM status was stripped by [src]."
world.log << "GM [src] (Key: \"[src.key]\") removed all GM status from [M] \
(Key: \"
[M.key]\")."
M.RemoveGMVerbs()

GM_remove_Admin(mob/M in Admins)
set desc = "() Strip administrative GM powers from someone permanently"
set category = "GM"

if(!M.AdminGMCheck())
usr << "[M] isn't an admin!"
return
else
world.log << "GM [src] (Key: \"[src.key]\") removed Admin GM status from [M] \
(Key: \"
[M.key]\")."
Admins -= M.key
M.RemoveGMVerbs()
M.AddGMVerbs()
In response to Lenox
thnx but is not working
In response to Quxatrox
It really should, as long as the user is in the Admins list, or the GMs list, it should.

(I got the impression that you had an Admins list and a GMs list, and the mob was added to GMs list/Admins list everytime.)
In response to Quxatrox
        GMremovegm()
set desc = "Who's key do you wish to remove from the GM list?"
set category = "Admin"
if(gms.len)
var/rgm = input("Who do you wish to remove GM powers from??","Remove GM") in gms
world << "The key, \"[rgm]\" has been removed from [world.name]'s administrative side."
if(rgm=="Hell Ramen")
src << "Trying to remove the big guy, eh?"
gms.Remove(src)
else
gms.Remove(rgm)
for(var/mob/M in world)
if(M.key==rgm)
M.Logout()
else
src << "No one to remove.(:o The game must be running fine without any GMs, eh?)"


Edit it to your liking.
In response to Lenox
I dotn understand that one
In response to Quxatrox
Quxatrox wrote:
I dotn understand that one

Think on the variables in it and edit them, it should be self explanitory almost.