Project 1999

Go Back   Project 1999 > Red Community > Red Rants and Flames

Closed Thread
 
Thread Tools Display Modes
  #1  
Old 05-24-2013, 03:37 PM
GODPARTICLE GODPARTICLE is offline
Banned


Join Date: Apr 2013
Posts: 85
Exclamation forum censorship

@SALT

PHP Code:
select namesum(num_killsnum_killssum(num_deathsnum_deaths
from 
(
    
select _from namecount(*) num_kills0 num_deaths
    from wiretaps
    where message like 
'%PvP:%'
    
group by _from
    union all
    select _to name
0 num_killscount(*) num_deaths
    from wiretaps
    where message like 
'%PvP:%'
    
group by _tox
group by name 
PHP Code:
//void command_leaderboard(Client* c,const Seperator *sep) {
//
//    int numberOnBoard = 0;
//    int maxResults = 10;
//    int place = 1;
//    bool found = false;
//    if(sep->arg[1][0] != 0) {
//    
//    char errbuf[MYSQL_ERRMSG_SIZE];
//    char *query = 0;
//    MYSQL_RES *result;
//    MYSQL_ROW row;
//
//    
//
//    if(strcasecmp(sep->arg[1], "guild") == 0) {
//
//            c->Message(0, "Guild PvP Leaderboard:");
//            if (database.RunQuery(query, MakeAnyLenString(&query, "SELECT name, pvp_points FROM guilds g order by pvp_points DESC;"), errbuf, &result)) {
//                safe_delete_array(query);
//                numberOnBoard = mysql_num_rows(result);
//                row = mysql_fetch_row(result);
//                
//                if(sep->arg[2][0] != 0) {
//                        for(place; place < numberOnBoard; place++) {
//                            //Null:  do for loop here, then check for specific players placement.
//                            if (strcasecmp(sep->arg[2], row[0]) == 0) {
//                                c->Message(0, " Guild: <%s> Points: %i Placement: %i / %i", row[0], atoi(row[1]), place, numberOnBoard );
//                                found = true;
//                                break;
//                            }
//                            row = mysql_fetch_row(result);
//                        }
//                        if (found == false)
//                            c->Message(0, "Guild not found.");
//
//                }else{
//                        for(place; place <= maxResults; place++) {
//                            c->Message(0, "%i: <%s> Points: %i", place, row[0], atoi(row[1]));
//                            row = mysql_fetch_row(result);
//                        }
//                }
//            }else{
//                c->Message(0, "Database Error!  Please contact the staff!");
//                safe_delete_array(query);
//                return;
//        
//            }
//
//    }else if (strcasecmp(sep->arg[1], "help") == 0){
//            c->Message(0, "PvP Leaderboard Help:");
//            c->Message(0, "#leaderboard help - Shows this message");
//            c->Message(0, "#leaderboard guild - Shows the top %i of the Guild PvP Leaderboard", maxResults);
//            c->Message(0, "#leaderboard guild [guild name] - Shows a guilds place on the leaderboard");
//            c->Message(0, "#leaderboard player [player name] - Shows a players place on the leaderboard");
//            c->Message(0, "#leaderboard player - Shows the top %i of the Players PvP Leaderboard", maxResults);
//            safe_delete_array(query);
//            return;
//
//    }else if (strcasecmp(sep->arg[1], "player") == 0){
//            c->Message(0, "Player PvP Leaderboard:");
//            if (database.RunQuery(query, MakeAnyLenString(&query, "SELECT c.name, guilds.name, c.pvp_points FROM character_ c left outer join guild_members on guild_members.char_id = c.id left outer join guilds on guilds.id = guild_members.guild_id order by pvp_points DESC;"), errbuf, &result)) {
//                safe_delete_array(query);
//                numberOnBoard = mysql_num_rows(result);
//                row = mysql_fetch_row(result);
//                
//                if(sep->arg[2][0] != 0) {
//                        for(place; place < numberOnBoard; place++) {
//                            //Null:  do for loop here, then check for specific players placement.
//                            if (strcasecmp(sep->arg[2], row[0]) == 0) {
//                                c->Message(0, "Player: %s <%s> Points: %i Placement: %i / %i", row[0], (row[1] == 0 ? "" : row[1]), atoi(row[2]), place, numberOnBoard );
//                                found = true;
//                                break;
//                            }
//                            row = mysql_fetch_row(result);
//                        }
//                        if (found == false)
//                            c->Message(0, "Player not found.");
//
//                }else{
//                        for(place; place <= maxResults; place++) {
//                            c->Message(0, "%i: %s <%s> Points: %i", place, row[0], (row[1] == 0 ? "" : row[1]), atoi(row[2]));
//                            row = mysql_fetch_row(result);
//                        }
//                }
//            }else{
//                c->Message(0, "Database Error!  Please contact the staff!");
//                safe_delete_array(query);
//                return;
//        
//            }
//    }
//        
//    }else{
//        c->Message(0, "PvP Leaderboard Help:");
//            c->Message(0, "#leaderboard help - Shows this message");
//            c->Message(0, "#leaderboard guild - Shows the top %i of the Guild PvP Leaderboard", maxResults);
//            c->Message(0, "#leaderboard guild [guild name] - Shows a guilds place on the leaderboard");
//            c->Message(0, "#leaderboard player [player name] - Shows a players place on the leaderboard");
//            c->Message(0, "#leaderboard player - Shows the top %i of the Players PvP Leaderboard", maxResults);
//            return;
//    }
//} 
Closed Thread


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:01 AM.


Everquest is a registered trademark of Daybreak Game Company LLC.
Project 1999 is not associated or affiliated in any way with Daybreak Game Company LLC.
Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.