ID:177181
 
I'm trying to figure out how to make a command allowing you to message a single person.
If you could help me I'd be grateful

Comunicator(msg as text)
src << "You tap your communicator"

Thats what ive got now... I figure I could use an Input() command, and 'in list' would be all players... Is there a variable for 'all players?'
Meh, maybe this kind of command wouldnt even work
Gathin wrote:
I'm trying to figure out how to make a command allowing you to message a single person.
If you could help me I'd be grateful

Here is how you would do it:

mob/verb/Tell_One_Person(var/mob/M as mob in world, T as text)
set category = "Communication"
M << "[usr] tells you: [html_encode(T)]"


--Lee
In response to Mellifluous
To expand on that, you could also drop an argument and do it like this:
mob/verb/tell(msg as text)
set src in world
usr << "You tell [src]: [msg]"
src << "[usr] tells you: [msg]"
In response to WizDragon
WizDragon wrote:
To expand on that, you could also drop an argument and do it like this:
mob/verb/tell(msg as text)
> set src in world
> usr << "You tell [src]: [msg]"
> src << "[usr] tells you: [msg]"


Good point, I totally forgot about that when I did the verb I posted as I was kinda rushing things :S

Should stop trying to rush more that way I might be more accurate hehe.

--Lee