I Made A Chat " Online Chat " Where People Can Talk To Each Other Free , But I Wanted To Load Online Players With Kind Of PlayerCard ( Movie_clip ) So Here is my C# Code :
Send info about all already connected users to the newly joined users chat
Message m = Message.Create("ChatInit");
m.Add(player.Id);
foreach(Player p in player) {
m.Add(p.Id, p.ConnectUserId);
}
player.Send(m);
//Informs other users chats that a new user just joined.
Broadcast("ChatJoin", player.Id, player.ConnectUserId);
}
// This method is called when a player leaves the game
public override void UserLeft(Player player) {
Broadcast("UserLeft", player.Id);
}
And Flash Code :
[flash=]
private function addUser(userid){
if(userid){
new playercard;
Menu.chat_tab.onlinelist.addChild(playercard)
Menu.chat_tab.onlinelist.addChild.playercard
Menu.chat_tab.onlinelist = new playercard ;
[/flash]
help please ?