ID:178408
 
I have a verb called "GMChat", but when ever i use it, nothing happens, can someone help me out?

heres my code:

turf
GMChat
mob
GMs
verb
GMChat(msg as text)
/turf/GMChat << "[usr] GMChats, '[msg]'"

And, yes, im on the GMChat turf.
Redslash wrote:
I have a verb called "GMChat", but when ever i use it, nothing happens, can someone help me out?

heres my code:

turf
GMChat
mob
GMs
verb
GMChat(msg as text)
/turf/GMChat << "[usr] GMChats, '[msg]'"

And, yes, im on the GMChat turf.

That doesn't work because you're sending output to a type path, not an actual atom; that's not a valid BYOND syntax. As far as DM is concerned, it's like saying this:
3 << "You're the number 3."

It's just not valid.

Nor, as far as I know, is it valid to send output to a turf or area and expect all its contents to see it. What you really need to do is do this instead (if your goal is to send to every user standing on this type of turf):
for(var/mob/M in world)
var/turf/T=M.loc
if(!T || !istype(T,/turf/GMChat)) continue
M << "[usr] GMChats, '[msg]'"

Lummox JR