Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > Premium Archives > ibProArcade Archive
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Scoring bug when the user has two open game windows Details »»
Scoring bug when the user has two open game windows
Version: , by AfterWorldForum AfterWorldForum is offline
Developer Last Online: Aug 2014 Show Printable Version Email this Page

Version: Unknown Rating:
Released: 10-28-2009 Last Update: Never Installs: 0
 
No support by the author.

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

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 12-13-2009, 07:05 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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?
Reply With Quote
  #13  
Old 12-13-2009, 07:13 PM
Mahoni999 Mahoni999 is offline
 
Join Date: Apr 2009
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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.
Reply With Quote
  #14  
Old 12-13-2009, 07:24 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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.
Reply With Quote
  #15  
Old 12-13-2009, 07:31 PM
Mahoni999 Mahoni999 is offline
 
Join Date: Apr 2009
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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.
Reply With Quote
  #16  
Old 12-13-2009, 07:53 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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.
Reply With Quote
  #17  
Old 12-14-2009, 08:52 AM
doubleclick doubleclick is offline
 
Join Date: Jul 2004
Posts: 218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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???
Reply With Quote
  #18  
Old 12-14-2009, 03:29 PM
Mahoni999 Mahoni999 is offline
 
Join Date: Apr 2009
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by kh99 View Post
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...
Reply With Quote
  #19  
Old 12-14-2009, 04:50 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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.
Reply With Quote
  #20  
Old 12-14-2009, 05:55 PM
Mahoni999 Mahoni999 is offline
 
Join Date: Apr 2009
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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
Reply With Quote
  #21  
Old 12-15-2009, 02:17 PM
doubleclick doubleclick is offline
 
Join Date: Jul 2004
Posts: 218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

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


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. The time now is 10:20 AM.


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.04564 seconds
  • Memory Usage 2,305KB
  • Queries Executed 27 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (1)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete