• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Problem z wyswietlaniem liczby graczy na serwerze

ximmy

Member
Joined
Oct 31, 2009
Messages
374
Reaction score
6
http://otland.net/f451/how-not-count-x-logged-players-81370/

Zainstalowalem ten system u siebie, pomijam juz to ze zle liczy liczbe graczy.

Mam problem z wyswietleniem calej sumy graczy na stronie glownej

Do tej pory uzywalem takiego kodu zeby wyswietlic liczbe graczy na stronie glownej w layout.php

<?PHP
if($config['status']['serverStatus_online'] == 1)
echo '
<center><font color="green"><b>
Players Online: '.$config['status']['serverStatus_players'].'
<center></font>';
else
echo '<font color="red"><b>Server Offline</b></font>';
?>

Po za instalowaniu tego skryptu wyswietla tylko aktywnych ( chce zeby wyswietlal sume )


Po malych przerobkach skrypt wyswietla sume graczy ale tylko gdy jestem w zakladche whoisonline.php a na kazdej innej nie widac liczby graczy

skrypt po przerobce gdzie widac sume graczy bedac tylko w zakladce whoisonline:

<?PHP
if($config['status']['serverStatus_online'] == 1)
echo '
<center><font color="green"><b>
Players Online: '.$number_of_players_online.'
<center></font>';
else
echo '<font color="red"><b>Server Offline</b></font>';
?>

- - - Updated - - -

Rozwiazalem problem troche na opak, ale dziala

- - - Updated - - -

Jak macie jakies normalne pomysly jak to naprawic to dajcie bo moje dzielo troche zamula stronke
 
Last edited:
Back
Top