WebEngine's 6th Anniversary

On December 19th, 2018 we will be celebrating 6 years of WebEngine CMS!
The event is here!

1.0.9.8 WebEngine Rankings (+add GResets to IGCN)

ozon

New Member
#1
Hello, I was shocked when I saw WebEngine rankings so what I done
- I disabled Level, Grand Reset and Master Level Ranking and I customized Resets ranking to show all that rankings in one tab.

How to customize Resets ranking to show Level, MasterLVL, Reset
1. You have to edit class.rankings.php which is in root/includes/classes/
2. Find
Code:
case "IGCN": $result =
which is bellow
Code:
private function _resetsRanking() {
3. Change line $result = ... on
Code:
$result = $this->mu->query_fetch("SELECT TOP ".$this->_results." "._CLMN_CHR_NAME_.","._CLMN_CHR_CLASS_.","._CLMN_CHR_GRSTS_.", "._CLMN_CHR_RSTS_.", "._CLMN_CHR_MLVL_.", "._CLMN_CHR_LVL_." FROM "._TBL_CHR_." WHERE "._CLMN_CHR_NAME_." NOT IN(".$this->_rankingsExcludeChars().") ORDER BY  "._CLMN_CHR_RSTS_." DESC, "._CLMN_CHR_MLVL_." DESC, "._CLMN_CHR_LVL_." DESC");
If you would like to add Grand Resets than in step 3 paste
Code:
$result = $this->mu->query_fetch("SELECT TOP ".$this->_results." "._CLMN_CHR_NAME_.","._CLMN_CHR_CLASS_.","._CLMN_CHR_GRSTS_.", "._CLMN_CHR_RSTS_.", "._CLMN_CHR_MLVL_.", "._CLMN_CHR_LVL_." FROM "._TBL_CHR_." WHERE "._CLMN_CHR_NAME_." NOT IN(".$this->_rankingsExcludeChars().") ORDER BY "._CLMN_CHR_GRSTS_." DESC, "._CLMN_CHR_RSTS_." DESC, "._CLMN_CHR_MLVL_." DESC, "._CLMN_CHR_LVL_." DESC");
4. You have to edit resets.php in root/modules/rankings/
5. Find first line with
Code:
echo '<td style="width:80px;font-weight:bold;">'.lang('rankings_txt_11',true).'</td>';
and few lines bellow
Code:
echo '</tr>';
6. Change that lines on
Code:
    echo '<td style="width:80px;font-weight:bold;">'.lang('rankings_txt_11',true).'</td>';
    echo '<td style="width:220px;font-weight:bold;">'.lang('rankings_txt_10',true).'</td>';
    echo '<td style="font-weight:bold;">'.lang('rankings_txt_13',true).'</td>';
    echo '<td style="font-weight:bold;">'.lang('rankings_txt_22',true).'</td>';   
    echo '<td style="font-weight:bold;">'.lang('rankings_txt_12',true).'</td>';
    echo '</tr>';
And that should be all if i didn't forgot about something...

If you would like to add Grand Resets than in step 6 paste
Code:
    echo '<td style="width:80px;font-weight:bold;">'.lang('rankings_txt_11',true).'</td>';
    echo '<td style="width:220px;font-weight:bold;">'.lang('rankings_txt_10',true).'</td>';
    echo '<td style="font-weight:bold;">'.lang('rankings_txt_21',true).'</td>';
    echo '<td style="font-weight:bold;">'.lang('rankings_txt_13',true).'</td>';
    echo '<td style="font-weight:bold;">'.lang('rankings_txt_22',true).'</td>';   
    echo '<td style="font-weight:bold;">'.lang('rankings_txt_12',true).'</td>';
    echo '</tr>';
7. You have to edit language.php in root/includes/languages/en
8. Find
Code:
define('_CLMN_CHR_RSTS_', 'RESETS');
and ADD BELLOW
Code:
define('_CLMN_CHR_GRSTS_', 'GRESETS');
Do not delete or do not replace that like before
Code:
define('_CLMN_CHR_RSTS_', 'RESETS');

9. Go to your SQL and do a) or b)
a)
9.1 Find MuOnline>Tables>Press Right Mouse Button on dbo.Character>Design
9.2 In last blank row in first columnt (Column name) write
Code:
GRESETS
9.3 In second column (Data Type) write
Code:
int
9.4 Close table, save all and it should all work good after CRON if i didn't forgot about something again :)
b)
9.1 You have to make New Query
Code:
ALTER TABLE dbo.Character
ADD GRESETS int;
9.2 Now you have to wait on next cron and check your ranking
 

ozon

New Member
#3
Unfortunately not, because I made more customizations and without them you will have many errors on your page.
Is it something hard to understand in that tutorial? You've got path and filenames and code to find and just replace.
 

Edgar

New Member
#4
Unfortunately not, because I made more customizations and without them you will have many errors on your page.
Is it something hard to understand in that tutorial? You've got path and filenames and code to find and just replace.
Thnx i will try :)
 
Top