ID:150009
 
How do you make a code for a verb so that anyone playing the game could see a list of mobs in the world?
for(var/mob/M in world)
if(M.client)
usr << M.name
In response to Exadv1
Exadv1 wrote:
for(var/mob/M in world)
if(M.client)
usr << M.name

You can do it this way, though if you have a lot of objects in your game it may be very inefficient. In general it's a good idea to keep a list of players logged into the game.

I have a Players library that does this:

byond://Deadron.Players

To get a list of players you call this:

base_PlayerMobs()