vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   ibProArcade Archive (https://vborg.vbsupport.ru/forumdisplay.php?f=174)
-   -   Scoring bug when the user has two open game windows (https://vborg.vbsupport.ru/showthread.php?t=226940)

AfterWorldForum 10-28-2009 05:21 AM

Scoring bug when the user has two open game windows
 
One of our users reported a major flaw in the Arcade mod.

If he opens 1 game in one browser window, and plays, but does not submit scores, and then goes and plays another game in a second browser window, it is possible to have the score for game 2 to be submitted as the score for game 1.

Here's some more info posted by himon how to reproduce the problem:

Quote:

Play Game 1
Finish Game 1 but donot submit the score.
Start Game 2
No go and submit Game 1 score
It will get recorded in Game 2
Maybe it's possible to have the score-submission part of the mod verify the score is coming from the proper game somehow?

Thanks.

Regards,

Peter

Kimberley 10-31-2009 03:38 PM

Just wondering why he wouldn't submit a game score before playing another, your friend must be a masterful gamer addict ;)

I am going to see if this happens in my arcade and I'll let you know and if it does try and find a fix for it. However I doubt it can be fixed as we get a similar problem when my husband and I play same game in a tourney and submit it disqualifies and thinks we have played as I believe it to be an IP issue and confuses the code on where it should be submitting.

AfterWorldForum 11-02-2009 01:50 PM

Quote:

Originally Posted by Kimberley (Post 1908709)
Just wondering why he wouldn't submit a game score before playing another, your friend must be a masterful gamer addict ;)

I am going to see if this happens in my arcade and I'll let you know and if it does try and find a fix for it. However I doubt it can be fixed as we get a similar problem when my husband and I play same game in a tourney and submit it disqualifies and thinks we have played as I believe it to be an IP issue and confuses the code on where it should be submitting.

Actually, my users seem to be pretty competitive, and we somehow expect some might be willing to exploit this bug in order to boost their champion status.

I also had some users complain about playing a tourney and the arcade somehow not receiving the score, but I'm inclined to think that's the game, rather than the arcade.

Anyway, thanks for taking the time to look into this :)

doubleclick 12-06-2009 07:27 AM

this is a huge problem for me. Many users have more than one window open, and as a result are submitting scores to the wrong game. It's not that they are master gamers, they are just (in my opinion) sloppy surfers.

I thought there was a code fix in this forum, but it seems to have been deleted with the recent housecleaning that took place in this mod's forum.

I give actual prizes to the winners, so this is a huge problem for me. My son has figured out how to use this bug to his advantage, and although he doesn't capitalize on it, he isn't the only teenager to visit the site. It won't take them long to figure it out.

I wish Mr.Zeropage (or maybe stangger5 ?) would address this gaping hole that allows people to cheat so easily that many do it by accident.

Mahoni999 12-06-2009 09:02 AM

There is already a Fix for this 2 Window Problem out....

Go to vb.germany-org

It works fine on my Site and i never had that Problem again. Now when Users want to submit with 2 open Windows, they get a Error Message. I replaced this Error Message with a Note that they might have 2 open Windows and that this causes the Error. So they know for the Future :)

Plz note: If someone is using Tools to cheat, than this Step will not protect you. It is just to fix the 2 Window Bug.

doubleclick 12-06-2009 09:09 AM

Thanks for the reply, Mahoni

no sprechens the german. . .

The first two posts over there are probably the most helpful. Do you know if the second post corrects, adds, or replaces the first?

Also, does the subsequent discussion tell anything I should know about? There are 24 posts in the thread. Maybe some of them have useful info.

If you speak German, would you mind translating it here for us less wordly among us?

Thanks,
dc

ABOVE POST WAS EDITED BY MAHONI REMOVING URL TO RELEVANT POST ON THE GERMAN SITE.

Mahoni999 12-06-2009 09:47 AM

you got it fixed ???

doubleclick 12-09-2009 09:18 AM

I didn't get it fixed, for the reason I cited above. I don't want to bring all my games down because I missed something. It would be great if you would translate their solution for the rest of us. This problem has existed over the course of several version changes without being fixed, so this could be our only hope.

Thanks Mahoni

doubleclick 12-13-2009 02:38 PM

Please somebody. My arcade is useless as several people have caught on and have rediculous scores due to this cross-window score problem. It completely defeats any reason to keep score since they are all becoming bogus.

Mahoni999 12-13-2009 07:00 PM

Sorry doubleclick....

Here is the Link again: http://www.vbulletin-germany.org/showthread.php?t=6106

As you mentionted you can`t work with it i thought you might be right as it is german. But did you ever think of using Google Translator ? You can translate the hole Site with it.

Sorry but i am workin right now on some own Problems that i can`t get fixed. So plz use a Translator for it. Make the Changes as descriped in Post no. 2 and you should be fine!

Regards
Mahoni999

kh99 12-13-2009 07:05 PM

So how does this work exactly, someone can open a second window with a completely different game (not just another copy of the first game) and submit the score?

Mahoni999 12-13-2009 07:13 PM

it is like that:

Player plays in 1st Window Game A

while Game A is still running he opens a second WIndow and starts Playin Game B

He finishes Game B and submits Highscore of Game B

Now the Highscore of Game B gets transfered into Database for Game A

Reason: No Controlling in the Arcade via Game ID. So the Arcade doesn`t know that the Highscores comes from a different Game.

kh99 12-13-2009 07:24 PM

Hmm...so, I often start playing a game "In New Window", then if it's not going well I just close it and maybe play a different game. Could this happen to me by accident? I've never noticed it. But I have had users complain that their high scores occasionally weren't getting saved, maybe it's related somehow.

Mahoni999 12-13-2009 07:31 PM

For some Reason there seems to be a IE Conflict in the Arcade. At least it is on my Arcade. On my Site a lot Users had Problems with saving the Highscore. If they use FF, then the Highscore gets saved with no Problem. But it also could depend on the Game, i guess.

You might give it a Try with a different Browser

anyhow i recommend to fix the 2 Window Bug as you make your Arcade saver for Accidents like this.

kh99 12-13-2009 07:53 PM

Yes, I hope someone will post a fix in English.

Regarding the IE problem, I "fixed" (sort of) a problem where IE would often not save scores, I posted it here: https://vborg.vbsupport.ru/showpost....5&postcount=94 but I guess it wasn't really noticed. Also in the same post, I found that the "holdsession" thing does not work because of two separate problems.

doubleclick 12-14-2009 08:52 AM

After registering, and going to google translator, the code fix is this:

I am an unlicensed user.

Since I bought my licence from vbulletin.com and not vbulletin-Germany.com, I am considered an outsider over there.

Mr. Zeropage:

PLEASE fix this in YOUR OFFICIAL VERSION.

This is nuts bouncing around all over Germany, google translating every page, only to find I can't get the fix anyway.

This two-window scoring problem is a big one, and the fix has already been done for you in both cases outlined by Mahoni999: this one, and the holdsession one. Just copy and paste the fixes into your official release, and everyone's happy.

The alternative is our patching our own copies, which means every time you release an upgrade, we have to remember that we've patched it on the side, and redo your code every time. It would be much easier if you would fix your original code with a 5 minute copy/paste exercise and we (and our users) would all be very grateful.

Pretty please???

Mahoni999 12-14-2009 03:29 PM

Quote:

Originally Posted by kh99 (Post 1930123)
Regarding the IE problem, I "fixed" (sort of) a problem where IE would often not save scores, I posted it here: https://vborg.vbsupport.ru/showpost....5&postcount=94 but I guess it wasn't really noticed.

I checked this and in my Version i do not have a 0 in that Gametime- Line. So for me this won`t fix the Problem. May i ask which Version of Arcade you are talking about ? Maybe you have an older Version and this one is already changed in newer Versions...

kh99 12-14-2009 04:50 PM

Yes, sorry for the confusion, I have not upgraded from 2.6.8 yet or looked at the latest arcade.php, so maybe that problem had already been fixed. I did check the current holdsession.php and I don't think that's been fixed yet.


ETA: No, I don't think that fix is in 2.7.0. The original line reads:

PHP Code:

            $vs['start'] = $gametime


I added the " - 1.0". The way I described it probably wasn't clear. I should have just included the new code in my post, but that was my first post on this forum and I didn't know what I should or shouldn't at that time.

Here's what I found:

Code:

                if ((($vs['sessd']!=1) && ($vs['sessid']>0)) && ($FIXIE==1))
                {
                        // this score has NOT run through the verify() function!
                        // actual issue using IE7 and doing more than one play per game

                        // make it valid anyway ;)
                        list($usec, $sec) = explode(" ", microtime());
                        $gametime = ((float)$usec + (float)$sec);
                        $randomchar = rand(1, 10);
                        $randomchar2 = rand(1, 5);

                        $vs['sessd'] = 1;
                        $vs['start'] = $gametime;
                            .
                            .
                            .
                list($usec, $sec) = explode(" ", microtime());
                $time_end = ((float)$usec + (float)$sec);
                $timecheck = round($time_end - $vs['start'], 4);

                            .
                            .
                            .
                if( !$timecheck || $timecheck > $SCORETIMEOUT )
                {
                        $ERRORLEVEL = ($DEBUGMODE == 0) ? "Transmission Timeout (".$timecheck." sec)" : "Error #005";


I found that because of the parts in red above, the value of $timecheck ended up being 0. Now that I look at it again, maybe the problem is really with the "round" statement? Or else the two calls to microtime() are returning the same thing.

Mahoni999 12-14-2009 05:55 PM

Thank you for the Additional Info. So we both running same Version. It`s the 2.6.8

And i might give it a Try with your changed Gametime. Will let you know if it changes something for me in IE.

According to the Holdsession Problem:

I had same Issues when i started with the Arcade. I fxed it with a simple Setting.

Encrease the Cookie Timeout to 1800 and set all Members to be kept Logged in automaticly. So if they play a Game that takes a bit longer then they won`t get logged off automaticly.

Reason is: If the Member is playing in the Arcade, then it is for the vbulletin like he is not anymore active in the Forum. So after the Time you have set in your Cookie Timeout the Member gets logged out automaticly.

Just keep them logged in automaticly via Setting and you should be fine with the Holdsession Problem...

Only Besides Effect is: If you run the "Who is online" then it happens that Members who have already left the Board still showing up in the List until the Cookie Timeout wipes them off...

Regards
Mahoni999

doubleclick 12-15-2009 02:17 PM

Can someone provide the fix for the original issue outlined in the topic of this thread?

doubleclick 12-18-2009 08:10 AM

Here's the post from the German site as provided by mahoni. However, I am not a licenced user there, so I can't see the code.

Can someone who is licensed at the German site please login over there and provide the simple fix that they have come up with?


Quote:


OK, so wie es aussieht konnte ich den Bug bei uns fixen. Das Vorgehen im ersten Post ist soweit richtig. Ich hatte nicht bedacht, dass die v32 Spiele die Methode "save_score" nutzen. Diese wurde entweder vergessen upzudaten oder dort wird absichtlich anders agiert, was ich mir nicht vorstellen kann.

Jedenfalls nach dem ich die Zeile:
PHP-Code:
Der Inhalt dieses Abschnitts ist nur f?r Lizenznehmer sichtbar, Sie werden derzeit jedoch nicht als Lizenzinhaber erkannt.

Bitte ?ffnen Sie den <a href="http://members.vbulletin-germany.com/membersupport_priority.php">Kundenbereich</a>, tragen Sie Ihre E-Mail-Adresse ein, mit der Sie sich hier registriert haben und aktivieren Sie die Lizenz?berpr?fung f?r http://www.vbulletin-germany.org.
durch diese ersetzt habe:
PHP-Code:
Der Inhalt dieses Abschnitts ist nur f?r Lizenznehmer sichtbar, Sie werden derzeit jedoch nicht als Lizenzinhaber erkannt.

Bitte ?ffnen Sie den <a href="http://members.vbulletin-germany.com/membersupport_priority.php">Kundenbereich</a>, tragen Sie Ihre E-Mail-Adresse ein, mit der Sie sich hier registriert haben und aktivieren Sie die Lizenz?berpr?fung f?r http://www.vbulletin-germany.org.
scheint das Problem nicht mehr aufzutauchen.

Was mich wundert ist wieso ?berhaupt die GameID aus der Session mit der realen ID verglichen wird. Im Prinzip ist es doch v?llig egal wie viele Fenster ein User ge?ffnet hat, solange das Ergebnis dem Spiel eindeutig zugeordnet werden kann, was ja ?ber den gname geschieht. Oder ?bersehe ich dort etwas?

Jedenfalls ist man, wie es momentan aussieht, mit dieser ?nderung sicher gegen?ber Cheatern, die keine Tools einsetzten aber Tools sind eine andere Sache, die einen anderen Schutz ben?tigt.

W?rde mich ?ber Feedback freuen ob es funktioniert oder ob der Fehler weiterhin besteht. Bei uns zumindest ist er verschwunden.

Gr??e

P.S.: Die ?nderung bezieht sich auf die arcade.php

__________________

Mahoni999 12-18-2009 02:52 PM

Quote:

Originally Posted by doubleclick (Post 1930357)
After registering, and going to google translator, the code fix is this:

I am an unlicensed user.

Since I bought my licence from vbulletin.com and not vbulletin-Germany.com, I am considered an outsider over there.


You have to register and valid your Licencenumber. if you have a valid Licence than you are also allowed to participate overthere. I signed up on german vbulletin and also had to make a Validation here and it works. So defently same for you. Just registering is not enough. If you unsure, you should contact the Support or an Admin overthere. He will for sure answer and help you to validate.

Hint:

Got to http://members.vbulletin-germany.com

Login with your Userdetails that you got when you signed up for vbulletin -> There go to Cutsomerarea -> On the left Side you see: Licenseowner in other Supportforums ( http://members.vbulletin-germany.com...t_priority.php ) -> there mark all Forums and you will shortly be able to see Code on all Sites which are listed there (included the one you need) :(

doubleclick 12-21-2009 08:14 PM

My god What a freakin mess this has been.

So: I am a member everywhere in the US and Germany, and here is the fix. Imagine my surprise to find Mr. Zeropage belongs to the forum there, and thus has ready access to this fix.

Anyway, in case anyone else is interested in stopping this scoring bug, here is the results of joining both German forums, exchanging emails with everyone on both continents, and wearing out google translator. Below is the post that Mahoni said contains the fix.

Thanks to Arthur Spooner who provided the following fix via google translator:

<begin Arthur Spooner post>

OK, it looks like I could fix the bug with us. The approach in the first post has come true. I had not considered that use the v32 games, the method "save_score. This was to update either forgotten or there is intentionally acting differently, which I can not imagine.

In any case, after I the line:

Code:

$DB->query("SELECT * FROM ibf_games_list WHERE gid=".$userinfo['arcade_sess_gid']);
was replaced by this:

Code:

$DB->query("SELECT * FROM ibf_games_list WHERE gname='".$swfgname . "'");
the problem seems to appear no more.

What surprises me is why all the GameID is compared from the session with the real ID. In principle, it is not matter how many windows a user has opened, as long as the outcome of the game can be uniquely identified with what is happening even on the gname. Or do I overlook something here?

In any case, one is, as it currently looks like, certainly with this change from cheaters, which uses no tools, but tools are a different matter that requires a different protection.

'd Appreciate feedback if it works or whether the problem persists. At the very least, he is gone.

Regards

PS: The amendment refers to the arcade.php

<end Arthur Spooner post>

Haven't had a chance to try this out yet, but have my fingers crossed in both languages.

Good luck,
ze doubleclicken

Mahoni999 12-22-2009 05:28 AM

So what counts is that you finally made it :D

Don`t understand why it was a Mess for you :confused:

And yes Mr. Zeropage is german and the Support in the german Forum is just great!!! :)

Hope you got if fixed now :up:

Give it a Shot and let the english People know if it works for you...

doubleclick 12-28-2009 08:26 AM

Yes, it's good to have the solution.

Quote:

Don`t understand why it was a Mess for you
It's mess registering, confirming, etc. using a machine translator. Google or babelfish, are helpful to a point, but are often, well, funny if not wrong. Plus, when you try to translate a page that requires a login, the translater won't work. Plus getting the licence to work with support, etc., etc. If you want to try it yourself, find a vbulletin site in say, chinese, then try the process. You'll understand. ;)

Why, if Mr. Zeropage is German, and the fix has been on the German site for a long time, doesn't he add this correction to his code releases? They've already done the work for him, so he just has to copy/paste and everyone's script is good. Otherwise, as I said before, everyone has to remember to edit his code whenever there is an upgrade.

The fix works to a point. Now, when the two-window situation arises, it simply refuses to post a score. Great for stopping the problem, but it leaves the users confused and/or angry, since they think the script is broken.

It would be great if someone here takes this code fix a step further so an error message appears explaining why the score they earned is not being posted.

Now lest anyone misunderstand, I like this script, or I wouldn't spend so much time getting it to work right. I have a number of local business who provide prizes for game and tournament winners, which is why correct scores and error messages are so important to me.

Happy Holiday of Your Choice,
dc

Mahoni999 12-28-2009 12:30 PM

Quote:

Originally Posted by doubleclick (Post 1940174)
Why, if Mr. Zeropage is German, and the fix has been on the German site for a long time, doesn't he add this correction to his code releases?

The fix works to a point. Now, when the two-window situation arises, it simply refuses to post a score. Great for stopping the problem, but it leaves the users confused and/or angry, since they think the script is broken.

dc

Why he never changed that? Ask himself via PM....

btw: according to your Mess to register i just can tell you that: i made the full Progress and it was not difficult. :D

but now back to Topic as i`m getting offtopic.... :(

Well, anyhow you will receive a Error-Message if you want to proceed with this 2 open Windows. It won`t leave the Users confused if you edit this Error Message to your wished Letters. I simply changed the Text. Now it is telling the Player that he might have had opend a second Window of the Arcade and for Anti-Cheat Protection this Score was not saved!

Wish you all a happy New Year :)

doubleclick 12-29-2009 08:22 AM

Quote:

Originally Posted by Mahoni999 (Post 1940316)
Ask himself via PM....

Kinda defeats the purpose of this support forum. Others concerned with this issue would want the answer if the reason as well is it breaks something.[/QUOTE]


Quote:

Originally Posted by Mahoni999 (Post 1940316)
2 open Windows. It won`t leave the Users confused if you edit this Error Message to your wished Letters.

The error message is:

"This score was not submitted from the game. Your score will not be saved."

I searched in cp> Languages & Phrases > Search in Phrases, and in all the arcade files, and can't find this message. Do you happen to know where this lives?

stangger5 12-29-2009 09:06 AM

Quote:

Originally Posted by doubleclick (Post 1941319)
The error message is:

"This score was not submitted from the game. Your score will not be saved."

I searched in cp> Languages & Phrases > Search in Phrases, and in all the arcade files, and can't find this message. Do you happen to know where this lives?

Look in the arcade/lang/lang_Arcade_en.php file..
Code:

cheater                          => "This score was not submitted from the game.  Your score will not be saved.",
;)

doubleclick 12-29-2009 09:24 AM

that did it!

Thanks stangger5

Mahoni999 12-29-2009 06:30 PM

yes, as stangger already descriped. You will find all the Text of the Arcade that might need to be changed in this php-File.

Regards
Mahoni


All times are GMT. The time now is 05:25 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.03463 seconds
  • Memory Usage 1,848KB
  • 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
  • (1)bbcode_php_printable
  • (10)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (30)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