20-01-2007, 07:50 AM
I just took the exact code from my server. (mine also has char,account,map and ip)
I think I may of changed when totalonlineplayers() was called though..
whatever, all you gotta do is throw a for loop with a call of >listbox.additem Player(i).Char(Player(i).CharNum).Name <
I just put it in the function that I happenned to use whenever a character logged in/out.
Just sit down for 5 damn minutes
or for $2 I'll do it to your exact specs. :lol:
Elmrok: I thought player index's didn't depend on the map#.
Wouldn't you have to go something like:
or something simular (didn't check syntax)
Wouldn't it be easier to call that with a command button, so you don't have to reload the form to 'refresh' the list too?
I think I may of changed when totalonlineplayers() was called though..
whatever, all you gotta do is throw a for loop with a call of >listbox.additem Player(i).Char(Player(i).CharNum).Name <
I just put it in the function that I happenned to use whenever a character logged in/out.
Just sit down for 5 damn minutes

or for $2 I'll do it to your exact specs. :lol:
Elmrok: I thought player index's didn't depend on the map#.
Wouldn't you have to go something like:
Code:
Private Sub Form_Load()
frmMapChat.txtMap.Text = 1
frmMapChat.lblPlayers.Caption = GetTotalMapPlayers(1)
frmMapChat.lstPlayers.Clear
For i = 1 To max_players
if GetPlayerMap(i) = txtMap.Text
frmMapChat.lstPlayers.AddItem i & ": " & GetPlayerName(i)
end if
Next i
End Sub
Wouldn't it be easier to call that with a command button, so you don't have to reload the form to 'refresh' the list too?