vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   vB Tetris v2.5 | Leaderboard, Comments and High Score System v2.5 :) (https://vborg.vbsupport.ru/showthread.php?t=42293)

John 08-26-2002 03:15 PM

Quote:

Originally posted by NuclioN
Yahooo, now it's become "open source" :D
Has it?

NuclioN 08-26-2002 03:19 PM

Well no, just teasing John. ;)

Martin64 08-26-2002 03:19 PM

Quote:

Originally posted by john.eovie


Hey - I'm open to other people's help. Make it secure and post it back up here if you have the time.

Afraid I don't have the skills. :(

[high]* Martin64 looks at Lesane
[/high]
[high]* Martin64 looks at Stuwee[/high]

Schorsch 08-26-2002 03:31 PM

Quote:

Originally posted by LightBringer
John, I installed the new arcade hack and I'm now experiencing issues with not being able to reach the comment section after a game is played.

*this was with tetris...trying the other games now*
I'm coming up with a request to login/permission denied.

http://www.brainphreeze.com/forums/arcade.php

Ok, tested all games and this is what I come up after finishing any of the games.


what did you change that it works now ?

John 08-26-2002 03:32 PM

Just make a small change to compensate for the fact that he has reigster_globals turned off. :)

John 08-26-2002 03:36 PM

If the arcade hack gives you the same no permission error, just get in touch and I'll send you the other version of the file :)

Schorsch 08-26-2002 03:47 PM

If somebody needs an arcade button (standard vB style), please look here.

trilOByte 08-26-2002 03:48 PM

With regard to making *only* each users best score show up on the leaderboard......

Quote:

Originally posted by futureal


This can be done. Here's an example:

http://www.shadowsofnamek.com/forum/...game=tetris&s=

Or another, from a different game:

http://www.shadowsofnamek.com/forum/...me=breakout&s=

Only each user's best score is shown. To accomplish this, you need to alter the query used in tetris.php for the "leaderboard" action.

From the original tetris.php file, you will want to replace this:

PHP Code:

$leaderboard_q $DB_site->query("SELECT * FROM arcade WHERE game='tetris' ORDER BY score DESC LIMIT 10"); 

with this:

PHP Code:

  $leaderboard_q $DB_site->query("SELECT game,userid,comment,max(score) as maxscore
                                    FROM arcade
                                    WHERE game='tetris'
                                    GROUP BY userid
                                    ORDER BY maxscore DESC
                                    LIMIT 10"
); 

That should achieve the result you're looking for.

Well I tried this, but no luck I'm afraid. There are two instances of the code you said to look for. When I replaced both instances with your replacement code, it did list the users only once, but i lost the comments and the actual score.

I think this is very close, but i dont know enough about drawing info from SQL DB's to work it out myself - any ideas anyone?

Thanks.

John 08-26-2002 03:50 PM

Quote:

Originally posted by Schorsch
If somebody needs an arcade button (standard vB style), please look here.
Sweet, shame we have to sign up to vBGermany to get the file :(

Schorsch 08-26-2002 04:00 PM

Quote:

Originally posted by john.eovie


Sweet, shame we have to sign up to vBGermany to get the file :(

ok, full credit to Anke123 from the vBulletin-germany.com forum!!

I hope she has nothing against it that I attach here button here.


All times are GMT. The time now is 11:03 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.02009 seconds
  • Memory Usage 1,746KB
  • 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
  • (2)bbcode_php_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete