ID:177151
 
How can I keep some people from loging in?

I tried this

Mob/logout
key = "DBZjerk"
Logout()
..()

but it doesnt work
please help

Treasurecat wrote:
How can I keep some people from loging in?

I tried this

Mob/logout
key = "DBZjerk"
Logout()
..()

but it doesnt work
please help

Mob/Login()
..()
if(key == "DBZjerk")
del(src)
In response to Skysaw
Skysaw wrote:
but it doesnt work
please help

Mob/Login()
..()
if(key == "DBZjerk")
del(src)

Isn't the DM compiler case sensitive..
In response to Super16
Yes, but Skysaw isn't.
In response to Super16
There is a better way of doing this.
set a proc
mob/proc/banned()
if(src.key == "Jacob"||"Punk"||"Key3")
del(src)
then put the thing that activates the proc in the login
mob/Login()
src.banned()
In response to Super16
Super16 wrote:
Skysaw wrote:
but it doesnt work
please help

Mob/Login()
..()
if(key == "DBZjerk")
del(src)

Isn't the DM compiler case sensitive..

He didn't ask for case sensitivity. In general, I wouldn't hard code names in anyway, but would read them from a file. Until more information is requested, I tend to just answer the question asked.
http://www.byond.com/hub/Polatrite/SavingForDummies

This has probably one of the single most simple banning functions in BYOND. Also, as labelled, it has an easy mob saving code too. Take a peek at it!