vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Arcade Anti-Cheater Mod (https://vborg.vbsupport.ru/showthread.php?t=67254)

Ron1n 07-15-2004 10:00 PM

Arcade Anti-Cheater Mod
 
Board: 3.x

Purpose:
If your board is a scripting/coding board you probably have cheaters using your arcade. They are people that use memoryhacks/colorbots, and believe me, people do cheat. This hack is to clean up scores. Before, if you wanted to remove a score, you had to create your own mysql query and even though the score was removed the highscore still showed up as belonging to them. This process has been fixed by this hack.

Functionaliy:
- Remove all scores from a user
- Remove a users highscores
- Fix the titleholders/highscores

Screenshot: http://www.elitecoders.org/ftp/ronin...rcadeadmin.jpg
Code: Attatched
No Edits Required PHP script: Attatched

Instructions: Perform the following edits, OR upload the attatched PHP file in place of your own arcadeadmin.php.

#-------------------------------------------------------------------------------#
Find In arcadeadmin.php
#-------------------------------------------------------------------------------#
Code:

        print_form_header('arcadeadmin', 'pruneinvalid');
        print_table_header("Remove All Invalid Scores");
        print_description_row("This action will remove all invalid score records from the database. Invalid records are created during automated score pruning, or if a session is terminated prematurely.");
        print_submit_row("Remove All Invalid Scores", 0);

#-------------------------------------------------------------------------------#
Add Below
#-------------------------------------------------------------------------------#
Code:

// ARCADE HACK BY RONIN       
        print_form_header('arcadeadmin', 'prunebyuser');
        print_table_header("Remove User Scores");
        print_description_row("This action will remove a users scores from the database.");
        print_input_row("Enter the userid here", 'userid');
        print_yes_no_row("Remove highscores only? (as opposed to all scores)", 'high', 0);
        print_submit_row("Remove User Scores", 0);
       
        print_form_header('arcadeadmin', 'fixhighscores');
        print_table_header("Fix High Scores");
        print_description_row("This action will update the highscore listings and awards with the actual highscore information for each game");
        print_submit_row("Update Highscores", 0);
// ARCADE HACK BY RONIN

#-------------------------------------------------------------------------------#
Find in arcadeadmin.php
#-------------------------------------------------------------------------------#
Code:

// ###################### INVALID RECORD PRUNING #######################
if ($_POST['do'] == "prunenoscore") {
        if ($_POST['confirmation']=="YES") {
                $DB_site->query("DELETE FROM " . TABLE_PREFIX . "gamesessions WHERE sessiontype=1");
        }

        define('CP_REDIRECT', 'arcadeadmin.php?do=scores');
        print_stop_message('arcade_cp_settingssaved');
}

#-------------------------------------------------------------------------------#
Add Below
#-------------------------------------------------------------------------------#
Code:

// ###################### PRUNE BY USER #######################
if ($_POST['do'] == "prunebyuser") {
        $userid=$_POST['userid'];
        $high=$_POST['high'];
       
 if ($high) {
        $query = "        SELECT gamename, MAX(score) AS score
                                FROM gamesessions
                                WHERE valid=1
                                GROUP BY gamename        ";
        $myquery = $DB_site->query($query);
        while($row = $DB_site->fetch_array($myquery)) {
                $delete = "DELETE FROM gamesessions WHERE gamename = '".$row['gamename']."' && userid ='".$userid."' && score = ".$row['score'];
                $DB_site->query($delete);
        }
        define('CP_REDIRECT', 'arcadeadmin.php?do=scores');
        print_stop_message('arcade_cp_settingssaved');
 } else {
        $DB_site->query("DELETE FROM " . TABLE_PREFIX . "gamesessions WHERE userid=".$userid);
        define('CP_REDIRECT', 'arcadeadmin.php?do=scores');
        print_stop_message('arcade_cp_settingssaved');
 }
}
// ###################### FIX HIGHSCORES #######################
if ($_POST['do'] == "fixhighscores") {
        $query = "        SELECT gamename, MAX(score) AS score
                                FROM gamesessions
                                WHERE valid=1
                                GROUP BY gamename        ";
        $myquery = $DB_site->query($query);
        while($row = $DB_site->fetch_array($myquery)) {
                $user =        "SELECT userid
                                        FROM gamesessions
                                        WHERE valid=1 AND score='".$row['score']."' AND gamename='".$row['gamename']."'";
                $userquery = $DB_site->query($user);
                while($useid = $DB_site->fetch_array($userquery)) {
                        $update =        "UPDATE games
                                        SET `highscore`='".$row['score']."', `highscorerid`='".$useid['userid']."'
                                        WHERE shortname='".$row['gamename']."'";
                        $DB_site->query($update);
                }
        }
        define('CP_REDIRECT', 'arcadeadmin.php?do=scores');
        print_stop_message('arcade_cp_settingssaved');
}


Musicpill 07-16-2004 10:03 PM

Why's this in the V2 section?

Ron1n 07-16-2004 10:24 PM

good point, i must have misread the forum i clicked on

can someone move this?

Musicpill 07-16-2004 10:29 PM

No problem, its easily done aint it?

assassingod 07-16-2004 10:31 PM

I'll move it for you:)

MrZeropage 07-17-2004 01:08 PM

*installed*

THANKS !

Dean C 07-17-2004 01:30 PM

Thanks for sharing your work - this is an addon though so I've moved it into that section :)

Oblivion Knight 07-17-2004 02:38 PM

If a user has a highscore and becomes the champion of a game, does this also clear the news associated with that user being the new champion? If not, it would be a good addition.. :)

Littlebit 07-17-2004 03:11 PM

Hey, thanks for this add :)
I did run into an error with the /admincp/arcadeadmin.php?do=scores
When I used the option with an admin username and with a registered user, it gave this error: Invalid SQL: DELETE FROM gamesessions WHERE userid=fred
mysql error: Unknown column 'fred' in 'where clause'

with 3.0.3

Ron1n 07-17-2004 04:00 PM

Quote:

Originally Posted by Littlebit
Hey, thanks for this add :)
I did run into an error with the /admincp/arcadeadmin.php?do=scores
When I used the option with an admin username and with a registered user, it gave this error: Invalid SQL: DELETE FROM gamesessions WHERE userid=fred
mysql error: Unknown column 'fred' in 'where clause'

with 3.0.3

I am willing to bet $500 that "fred" is not a valid userid. When you visited fred's arcade profile it should have had all the links and then u=# at the end. The number at the end of the URL is their userID. You can also view the userid from the admin pannel via a search.

Littlebit 07-17-2004 04:09 PM

That was it, I spaced. Thank you! It works just great :)

gwhooooey 07-18-2004 12:38 AM

Can't you just click the red X next to someone's score that you want to remove? :-\

pmay68 07-20-2004 12:12 AM

i get this error

Database error in vBulletin 3.0.1:

Invalid SQL: SELECT gamename, MAX(score) AS score
FROM gamesessions
WHERE valid=1
GROUP BY gamename
mysql error: Table 'datbase.gamesessions' doesn't exist

mysql error number: 1146

Date: Monday 19th of July 2004 06:11:11 PM
Script: http://adventurersunited.com/forums/...rcadeadmin.php
Referer: http://adventurersunited.com/forums/....php?do=scores
Username: lieutan
IP Address: 66.76.222.164

any suggestions

grief 07-21-2004 05:52 PM

Very nice this will definately come in handy

Ron1n 07-21-2004 08:29 PM

Quote:

Originally Posted by gwhooooey
Can't you just click the red X next to someone's score that you want to remove? :-\

I made this mod for myself, because some user on my board won over 40 games using a memory hack. I didnt want to delete every score by hand, so I made it so that you could remove all scores by a user. I then decided that in the future it might be nice to be able to just remove high scores and not all scores. I made this for www.elitecoders.org and www.mpcforum.de. We are cheater forums, so we have a lot of cheaters we must deal with. This tool makes it very easy.


Quote:

Invalid SQL: SELECT gamename, MAX(score) AS score
FROM gamesessions
WHERE valid=1
GROUP BY gamename
mysql error: Table 'datbase.gamesessions' doesn't exist
Please log into your PHP MyAdmin and see if there is a gamesessions table. If there is, copy down the prefix (the prefix should be something like vb_). if the prefix is not similar to your boards standard prefix it wont find the right table, if it is similar and you still have problems, then ill talk with you on MSN to help you fix this.

Renat_ 07-23-2004 05:29 PM

Installed and working fine. Thank you Ronin!

Renat_ 07-23-2004 06:06 PM

Is this any way to stop one Registered member from paying arcade?

Datenpapst 07-26-2004 12:02 PM

Quote:

Originally Posted by Renat_
Is this any way to stop one Registered member from paying arcade?

Whats the sence in cheating in the Arcade?

RichieBoy67 07-26-2004 12:48 PM

It's a great hack but is there anyway to actually stop people from cheating??

Datenpapst 07-26-2004 01:36 PM

Quote:

Originally Posted by RichieBoy67
It's a great hack but is there anyway to actually stop people from cheating??

hmm dont think so.

Diva 08-02-2004 06:19 PM

Quote:

Originally Posted by Oblivion Knight
If a user has a highscore and becomes the champion of a game, does this also clear the news associated with that user being the new champion? If not, it would be a good addition.. :)

Hi! I was wondering if the hack removes the news also?

Rampag33 08-19-2004 04:47 PM

did the manual edit .... worked with no problem and no errors.

great and thanks!

Cerb 08-21-2004 04:15 PM

Yeah hacking arcades is actually pretty easy, tested with Yeti Sports 1.5 with Firefox and the offsets are stored in 16 bit memory in double format.

However I have no idea how this hack would prevent cheating, it could remove high scores, but it could not for sure detect if a score has been hacked or not since the offsets are stored in the client's virtual memory then sent to the server

Ron1n 09-11-2004 09:16 PM

the reason i needed this mod is that if I didnt have it, over 90% of the people in my forum would be cheating because we are, by definition, a cheat site :P

it cant prevent people from cheating, i could run a perl script to see whats running on their computers while they play... but tbh that would waste tons of bandwidth and i doubt your users would allow me to check that. :)

Reverend 09-14-2004 09:48 PM

This hack doesn't remove the users score from the News & Events list.Is it possible to include some code to add this feature as well.

The Professor 09-15-2004 11:56 PM

Greetings everyone. To dispose of any concern that I am asking on how to cheat for negative purposes, I would like to preface my question with the following:
I am a member / administrator on MajorGeeks.com under the username of Kodo. If anyone wishes to confirm my account and the fact that this is indeed legitimate, please send me an email at Kodo (at) MajorGeeks.com and I will reply or merely ask the Owners of the site who I am. Or ask me to post something on MajorGeeks and it will be done.

Now, onto my question. We have a member that I suspect is cheating. The game in question is KF9000 kite flying. If anyone knows if this game is flawed, please let me know. I suspect a dozen or so other games have been "bypassed" in some manner, either by the game being bad or this person somehow "posting" altered data. I'm leaning to the latter.

I would like to gather as much specific information I can on how the arcade is by passed (and by god don't post the specifics in this thread!) via e-mail correspondence or PM. I tried today with limited success but I am by no means a "hacker/cracker" and do not aspire to be labeled as such. I am merely trying to determine how this is done step by step as proof of concept and assist in better determining who is cheating.

Some people are good cheaters. They'll hack the highscore and play several games regularly to populate lower scores. I really need to nail down some more info though.

I thank anyone who can help me.

Regards
-Jim Losi
Kodo on MajorGeeks

enterprise 10-11-2004 12:36 PM

Nice work, been having problems with my forum's arcade, thanks!

Soto 01-16-2005 09:43 PM

Installed - thank you

Polo 03-11-2005 12:47 PM

[high]* Polo clicks install
[/high]

Thanks;)

ryne661 07-18-2005 02:22 AM

How exactly would they be able to cheat in the arcade?

o0Hubba0o 08-08-2005 03:30 AM

Quote:

Originally Posted by ryne661
How exactly would they be able to cheat in the arcade?

There has to be a way to know they are cheating, does anyone know how to tell or if there's a way. I hate to remove all of someones scores just because "I think" or "assume" they are cheating.

csidlernet 08-19-2005 09:27 AM

THanks!
/me hits install

Ron1n 08-21-2005 11:02 PM

Quote:

Originally Posted by o0Hubba0o
There has to be a way to know they are cheating, does anyone know how to tell or if there's a way. I hate to remove all of someones scores just because "I think" or "assume" they are cheating.

If they score higher than the max score for the game, you know they cheated.

There is no way to know whether they cheated/are cheating in a simple arcade game.


All times are GMT. The time now is 04:44 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01988 seconds
  • Memory Usage 1,824KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_code_printable
  • (8)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (33)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete