ID:269156
 
How would I show info on the hub such as who is hosting the game(the info next to the join game button). Example: http://games.byond.com/hub/IccusionEntertainment/Seika

P.S. How would I show info on the DS window header such as how many players are on(the same one that shows the name of the game)
Something such as:

  world.status = "[world.name] version (input version or whatever here)"


But, if you want to add a player amount you have to find a library on that which there are some that will help you out in that. Also, you can edit the world status to whatever you wish, as well.
In response to MasterLink2003
Ok, thanks.
In response to Mecha Destroyer JD
No problem.
In response to MasterLink2003
mob/Login()
players += 1
world/status = "[world.name] players: [players]"// Updates itself.
..()

mob/Logout()
players -= 1
world/status = "[world.name] players: [players]"// Updates itself.
..()

var/players

world/status = "[world.name] : Players: 0"//Defult.


Space accodingly
In response to Flame Sage
Flame Sage wrote:
Space accodingly

Or preferably correctly. Your code needs to be indented to work.

Of course far far better than a player count is a players list, which is more versatile.

Lummox JR
In response to Lummox JR
Whoa, it was THAT simple?
In response to Flame Sage
Flame Sage wrote:

mob/Logout()
players -= 1
world/status = "[world.name] players: [players]"// Updates itself.
..()

I don't suggest leaving mob's in the world when they log out(del(src)).
In response to Mecha Destroyer JD
So how would I show who is the host on the hub? I had some kinda idea on how it would work, but it didn't..
In response to Mecha Destroyer JD
mob/var/ishost=0
var/spread = 0
var/host=""
mob/New()
..()
spawn()
checkhost()
mob/proc/checkhost()
if(client)
if(client.address==null | client.address==world.address | client.address=="127.3.4.1") host()//but the client is read as null

mob/proc/host()
if(istype(src,/mob))
host="[src.name]"
world.name="Journey of Desturction"
world.status= "<font color=teal>JoD Server || V. 1.09 || Host: [src.key]</font> || byond://[world.address]:[world.port]"
ishost=1
if(src.staff==1)
world.name="Journey of Destruction"
world.status="<font color=gray><b>JoD Server || V 1.09 || Host: [src.key] || byond://[world.address]:[world.port]</font></b>"
if(src.key=="MasterLink2003")
world.name="Journey of Destruction"
world.status="<b><font color=green>JoD Server || V. 1.09 || Host: [src.key] || byond://[world.address]:[world.port]</font></b>"
if(src.key=="null")
world.name="Journey of Destruction"
world.status="<font color=maroon>JoD Temp Server || V 1.09 || Host: [src.key] || byond://[world.address]:[world.port]</font>"
if(src.key == "")
world.name="Journey of Destruction"
world.status="<font color=maroon>JoD Testing Server || V 1.09 || Host: [src.key] || byond://[world.address]:[world.port]</font>"
//for(var/X in typesof(/mob/host_verbs/verb)) verbs += X
else
..()


This should work all you have to do is change the text to whatever. Oh yeah and .. the text above is my old games so eh.. don't worry about that.
In response to MasterLink2003
Ok, thanks