PDA

View Full Version : IbproArcade - Top 10 Players


am-fs
11-28-2005, 10:00 PM
This edit will add the Top 10 Players to your IbproArcade System and remove the Arcade Highscore Champions.
Port off of :http://www.ipbarcadegames.com/index.php?showtopic=7022

In your arcade/skin/skin_Arcade.php
Find:
<td class="alt1" align="center" valign="top" style="width: 60%;padding-left:7px;padding-top:5px;padding-bottom:5px;">

<div class='tborder'>
<table width='100%' border='0' cellspacing='0' cellpadding='4'>
<tr>
<th width='100%' align='center' nowrap='nowrap' class='tcat' colspan='3'><img src="./arcade/images/trophy.gif" border="0" alt="">{$ibforums->lang['infobox_top3title']}<img src="./arcade/images/trophy.gif" border="0" alt=""></th>
</tr>

<tr>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'><b>{$Highscorechamp['ArcadeChampionSmily1']}</b></td>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'><b>{$Highscorechamp['ArcadeChampionSmily2']}</b></td>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'><b>{$Highscorechamp['ArcadeChampionSmily3']}</b></td>
</tr>

<tr>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'>{$Highscorechamp['ArcadeChampionAvatarCode1']}</td>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'>{$Highscorechamp['ArcadeChampionAvatarCode2']}</td>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'>{$Highscorechamp['ArcadeChampionAvatarCode3']}</td>
</tr>
<tr>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'>{$Highscorechamp['ArcadeChampion1']}</td>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'>{$Highscorechamp['ArcadeChampion2']}</td>
<td width='33%' align='center' nowrap='nowrap' class='alt2' valign='middle'>{$Highscorechamp['ArcadeChampion3']}</td>
</tr>
</table>
</div>

Replace With:
<td align="center" class="alt1" style="width: 50%;" valign='top'>
<div class='tborder'>
<table width='100%' border='0' cellspacing='1' cellpadding='4'>
<tr>
<th width='50%' align='center' nowrap='nowrap' class='tcat'> Top 10 Arcade Players</th>
</tr>
<tr>
<td width='50%' align='center' nowrap='nowrap' class="alt2" valign='top'><table border=0><tr><td align=center class="alt2">01.
{$Champion['ArcadeChampion1']}<br>02. {$Champion['ArcadeChampion2']}<br>03. {$Champion['ArcadeChampion3']}<br>04. {$Champion['ArcadeChampion4']}<br>05. {$Champion['ArcadeChampion5']}<br>06. {$Champion['ArcadeChampion6']}<br>07. {$Champion['ArcadeChampion7']}<br>08. {$Champion['ArcadeChampion8']}<br>09. {$Champion['ArcadeChampion9']}<br>10. {$Champion['ArcadeChampion10']}</td></tr></table></td>
</tr>
</table>
</div>

Find:
<div class="tborder">
<table width='100%' border="0" cellspacing="0" cellpadding="4">
<tr>
<td align="center" width="20%" nowrap="nowrap" class="tcat"> </td>
<td align="center" width="60%" nowrap="nowrap" class="tcat">$totalstext</td>
<td align="center" width="20%" nowrap="nowrap" class="tcat"> </td>

Replace With:

<div class="tborder">
<table width='100%' border="0" cellspacing="0" cellpadding="4">
<tr>
<td align="center" width="25%" nowrap="nowrap" class="tcat"> </td>
<td align="center" width="50%" nowrap="nowrap" class="tcat">$totalstext</td>
<td align="center" width="25%" nowrap="nowrap" class="tcat"> </td>

In your "forum root" arcade.php

Find:
$Champion['ArcadeChampion1'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion2'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion3'] = "{$ibforums->lang['top3box_norank']}";
$Cpt = 0;
$DB->query("select champ_mid, champ_name, count(*) nb, active, champ_gid, gid from ibf_games_champs inner join ibf_games_list on champ_gid=gid where active =1 group by champ_mid, champ_name order by 3 desc, 1 limit 3");
while ($res = $DB->fetch_row())
{
$Cpt++;
$Champion['ArcadeChampion'.$Cpt] = '<span style="font-weight: bold;"><a href="'.$ibforums->base_url.'act=Arcade&module=report&user='.$res['champ_mid'].'">'.$res['champ_name'].'</a></span><br />'.$ibforums->lang[arcadeking_txt1].'<b>'.$res['nb'].'</b>'.$ibforums->lang[arcadeking_txt2];
$Champion['ArcadeChampionMid'.$Cpt] = $res['champ_mid'];
}

Replace With:
$Champion['ArcadeChampion1'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion2'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion3'] = "{$ibforums->lang['top3box_norank']}";
$Cpt = 0;
$DB->query("select champ_mid, champ_name, count(*) nb, active, champ_gid, gid from ibf_games_champs inner join ibf_games_list on champ_gid=gid where active =1 group by champ_mid, champ_name order by 3 desc, 1 limit 10");
while ($res = $DB->fetch_row())
{
$Cpt++;
$Champion['ArcadeChampion'.$Cpt] = '<span style="font-weight: bold;"><a href="'.$ibforums->base_url.'act=Arcade&module=report&user='.$res['champ_mid'].'">'.$res['champ_name'].'</a></span><br />'.$ibforums->lang[top10_txt1].'<b>'.$res['nb'].'</b>'.$ibforums->lang[top10_txt2];
$Champion['ArcadeChampionMid'.$Cpt] = $res['champ_mid'];
}

Now in your arcade/lang/lang_Arcade_en.php
Find:
#complete phrasing

Add:
top10_txt1 => " has ",
top10_txt2 => " Wins!",

Boofo
11-29-2005, 02:58 PM
Screenshots and text file please? ;)

am-fs
11-29-2005, 02:59 PM
There you Go :).....Note I use Top 20 instead of 10

Boofo
11-29-2005, 03:02 PM
Can you add the text to the first post, please? ;)

And looks good. ;)

Koopa
11-29-2005, 04:38 PM
Can you add the text to the first post, please? ;)

And looks good. ;)

Thanks for this :)

am-fs
11-29-2005, 05:25 PM
Up-dated the txt file for easy viewing for editing. ;)

Dadoo
11-29-2005, 07:20 PM
there is a BUG in txt file at


$Champion['ArcadeChampion1'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion2'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion3'] = "{$ibforums->lang['top3box_norank']}";
$Cpt = 0;
$DB->query("select champ_mid, champ_name, count(*) nb, active, champ_gid, gid from ibf_games_champs inner join ibf_games_list on champ_gid=gid where active =1 group by champ_mid, champ_name order by 3 desc, 1 limit 10");
while ($res = $DB->fetch_row())
{
$Cpt++;
$Champion['ArcadeChampion'.$Cpt] = '<span style="font-weight: bold;"><a href="'.$ibforums->base_url.'act=Arcade&module=report&user='.$res['champ_mid'].'">'.$res['champ_name'].'</a></span><br />'.$ibforums->lang[top10_txt1].'<b>'.$res['nb'].'</b>'.$ibforums->lang[top10_txt2];
$Champion['ArcadeChampionMid'.$Cpt] = $res['champ_mid'];
}


last "}" is missing..

otherwise, in first file edit (skin_Arcade.php) if you have make choice to have V3arcade skin and not ibProArcade skin, modify skin_v3Arcade.php file and not skin_arcade.php

am-fs
11-29-2005, 07:34 PM
Fixed.....Thanks

Dadoo
11-29-2005, 07:38 PM
thanks to you, good job i like your hack and use it !!!

G-Force 199
11-29-2005, 09:43 PM
TX + Installed
Where did u download ur games :) ?

Snake
12-01-2005, 03:15 PM
Nice one.

rinkrat
12-01-2005, 09:52 PM
Thanks!

VBUsers
12-27-2005, 09:30 PM
my list shows like this how can i fix it to show like the image posted?

01. jtcny
has 82 Wins!
02. thedoulou
has 60 Wins!
03. evilvinny
has 25 Wins!
04. BBQUEEN
has 10 Wins!
05. Disp29
has 8 Wins!
06. atlantaazfinest
has 3 Wins!
07. Caddyman
has 3 Wins!
08. LOW
has 2 Wins!
09. i710
has 1 Wins!
10.

Zia
12-31-2005, 09:54 AM
Nice ...liked this Hack
/klicks Install.

Umm where to find games pls?

Loki12
12-31-2005, 11:51 AM
my list shows like this how can i fix it to show like the image posted?

01. jtcny
has 82 Wins!
02. thedoulou
has 60 Wins!
03. evilvinny
has 25 Wins!
04. BBQUEEN
has 10 Wins!
05. Disp29
has 8 Wins!
06. atlantaazfinest
has 3 Wins!
07. Caddyman
has 3 Wins!
08. LOW
has 2 Wins!
09. i710
has 1 Wins!
10.

I have the same problem....

am-fs
01-01-2006, 04:32 AM
in the arcade.php file

Find:
$Champion['ArcadeChampion1'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion2'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion3'] = "{$ibforums->lang['top3box_norank']}";
$Cpt = 0;
$DB->query("select champ_mid, champ_name, count(*) nb, active, champ_gid, gid from ibf_games_champs inner join ibf_games_list on champ_gid=gid where active =1 group by champ_mid, champ_name order by 3 desc, 1 limit 3");
while ($res = $DB->fetch_row())
{
$Cpt++;
$Champion['ArcadeChampion'.$Cpt] = '<span style="font-weight: bold;"><a href="'.$ibforums->base_url.'act=Arcade&module=report&user='.$res['champ_mid'].'">'.$res['champ_name'].'</a></span><br />'.$ibforums->lang[arcadeking_txt1].'<b>'.$res['nb'].'</b>'.$ibforums->lang[arcadeking_txt2];
$Champion['ArcadeChampionMid'.$Cpt] = $res['champ_mid'];
}


Replace with:
$Champion['ArcadeChampion1'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion2'] = "{$ibforums->lang['top3box_norank']}";
$Champion['ArcadeChampion3'] = "{$ibforums->lang['top3box_norank']}";
$Cpt = 0;
$DB->query("select champ_mid, champ_name, count(*) nb, active, champ_gid, gid from ibf_games_champs inner join ibf_games_list on champ_gid=gid where active =1 group by champ_mid, champ_name order by 3 desc, 1 limit 3");
while ($res = $DB->fetch_row())
{
$Cpt++;
$Champion['ArcadeChampion'.$Cpt] = '<span style="font-weight: bold;"><a href="'.$ibforums->base_url.'act=Arcade&module=report&user='.$res['champ_mid'].'">'.$res['champ_name'].'</a></span>'.$ibforums->lang[arcadeking_txt1].'<b>'.$res['nb'].'</b>'.$ibforums->lang[arcadeking_txt2];
$Champion['ArcadeChampionMid'.$Cpt] = $res['champ_mid'];
}

Loki12
01-01-2006, 10:51 AM
Still doesn't work...

01. ***got 15 times
the High Score of all time
02. ***got 6 times
the High Score of all time
03. ***got 4 times
the High Score of all time
04.
05.
06.
07.
08.
09.
10.

am-fs
01-01-2006, 12:26 PM
Still doesn't work...

01. ***got 15 times
the High Score of all time
02. ***got 6 times
the High Score of all time
03. ***got 4 times
the High Score of all time
04.
05.
06.
07.
08.
09.
10.

You have not edited all of the lines then. It should not have this ***got 4 times
the High Score of all time
The Text is to long to fit in the box.

Should Be **** has 5 Wins!

Neo_obs
04-25-2006, 08:26 PM
ok so why isnt number 10 appearing? can you post how your actual edits to your arcade? the ones done to your Skin_arcade.php

Gemma
04-26-2006, 04:28 PM
This should run okey,it's based on a modification I did for vb 3.0.x and arcade 2.5.1 - I'm still running it now on vb 3.5.4 and arcade 2.5.5+ and haven't had any problems :)

NDRPrelude
04-26-2006, 06:26 PM
Thanks you so much!!! I am finally showing King of the Arcade! Now if I could just get the tournaments to work.

NDRPrelude
04-26-2006, 06:44 PM
Holy shit, the tournaments are working too!

Neo_obs
04-27-2006, 05:51 AM
I found out why my number 10 doesnt show. Because there are not enough users. so when you add all the numbers up if less than 10 people are champions then it wont display those fields. I did fix this in mine by adding this line 10 times and replacing 1 with each number 1-10

$Champion['ArcadeChampion1'] = "{$ibforums->lang['top3box_norank']}";

edytwinky
11-07-2007, 01:28 PM
This should run okey,it's based on a modification I did for vb 3.0.x and arcade 2.5.1 - I'm still running it now on vb 3.5.4 and arcade 2.5.5+ and haven't had any problems :)

How did you get it to split with the three main trophy winners and then the best of the rest?

And is this mod for total trophy count or best scores of all time?

YLP1
05-14-2008, 10:27 PM
Can this be used on the latest ibProArcade version?