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)

Castel 08-23-2002 11:01 PM

Quote:

Originally posted by john.eovie
Ok, when I run

Code:

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

in place of the standard leaderboard_q code, I get no records returned.

John I ran that query in PHPadmin and it works perfect. I used order by userid and no limit to check (after a checked there was multiple record for the same user) and the query returned only the highest score for each user. I think this is the ticket to your arcade hack with dual display mode, I had doctored up another way after out conversation earlier but this is much better.

John 08-23-2002 11:03 PM

I had already come up with this SQL earlier, but it didn't get me anywhere - just like it's not getting me anywhere now. I have no idea why this is not working in my code, but it is working in phpMyAdmin :\

futureal 08-23-2002 11:18 PM

So, let's see the rest of the code. :)

If you don't want to post it, feel free to PM it to me and I'll take a look at it.

John 08-23-2002 11:21 PM

I've come up with a solution - the code just didn't like the admin cp selection system I put in place to allow users to choose how they want their leaderboards to run.

Got the basis of something that works now tho, which can't be bad...

eXtremeTim 08-23-2002 11:32 PM

I can't wait to get it john. :)
This was one hack that i really wanted for vb. :)

Martin64 08-23-2002 11:55 PM

Quote:

Originally posted by Souly
I have try to add Levels. i can not test it, because i am an admin and i have no time to play much hours :D ... I have never work before yesterday with flash, plz. test it on your own risk :D

[Changes]
*16 Levels: 11-16 are new and i think they are very hard, but i don?t play tetris, i can?t test it :(

3 new tetris.swf:
--> plz make a backup of all your previous tetris.swf Files before you test my new version!

1 Version:
------------
english, 16 Levels (6 new) very hard! pause is disabled

2 Version:
------------
english, 16 Levels (6 new) very hard! pause is enabled

3 Version:
------------
german, gray background, 16 Levels (6 new) very hard! pause is disabled


Here are Number ONE:
(english, 16 Levels (6 new) very hard! pause is disabled)

[INSTALL]
Download the tetris.zip File, unpack it and copy the tetris.swf File in your forum root and let test your user the 6 new level!
.................................................. .................................................. ..

Cheers for that, I'm using your second version and let's see what the pro's say once they've finished the 10th level :)

Courage 08-24-2002 12:03 AM

Quote:

Originally posted by kypdurron
If Im using Ie6, after playing for awhile, I get a "access denied" error when the game is over...why is that and how can I disable it?
My users are complaining about the same thing. They are playing for a long time and when thy finish... Acces Denied :(

PHP Version v4.2.1
MySQL Version v3.23.51-log

John 08-24-2002 12:06 AM

Quote:

Originally posted by Courage


My users are complaining about the same thing. They are playing for a long time and when thy finish... Acces Denied :(

PHP Version v4.2.1
MySQL Version v3.23.51-log

Tetris version?

futureal 08-24-2002 12:08 AM

It is possible that because John's version has the timeout set to 60 minutes, the security check is failing after the game. An hour is a long time, though, so that might not be it. You could try increasing that value just for kicks.

Another option is to change where the calls to show_nopermission() are being made to see if that affects it. I use the following nopermission code:

PHP Code:

// access check
switch($action) {
  case 
"leaderboard":
    break;
  case 
"play":
  case 
"reg":
    if ((
$bbuserinfo[usergroupid] != 2) and
        (
$bbuserinfo[usergroupid] != 5) and
        (
$bbuserinfo[usergroupid] != 6) and
        (
$bbuserinfo[usergroupid] != 7)) {
      
show_nopermission();
    }
    break;
  default:
    if ((
$bbuserinfo[usergroupid] != 2) and
        (
$bbuserinfo[usergroupid] != 5) and
        (
$bbuserinfo[usergroupid] != 6) and
        (
$bbuserinfo[usergroupid] != 7)) {
      
show_nopermission();
    }
    
$action "play";
    break;


That code is near the top of the file and is only executed once. There are no further permission checks (aside from security stuff) and it seems to work great.

However, since I have moved pretty far away from the original hack, I wouldn't recommend trying that code out unless you know what you're doing. I don't want to screw anybody's thing up! :)

Ryangel 08-24-2002 12:09 AM

Latest one John. Its really weird as only some users get this. He told me he had Ie6 as well.

NexDog 08-24-2002 12:16 AM

Maybe it's VB cookie session timeout issue? :)

Courage 08-24-2002 12:23 AM

My Tetris version is the latest :o 2.5
I just uploaded yesterday... and now complains.. :o

See the screenshot atached

John 08-24-2002 12:34 AM

Since there are other security items in place, you could block out all no permission pages for the "reg" action with a simple if statement. Non members would be able to access that reg page, but they wouldn't be able to do anything...

Schorsch 08-24-2002 03:23 AM

Quote:

Originally posted by Souly
Here are Number THREE:
(german, gray background, 16 Levels (6 new) very hard! pause is disabled)

[INSTALL]
Download the tetris.zip File, unpack it and copy the tetris.swf File in your forum root and let test your user the 6 new level!
.................................................. .................................................. ..

great!! thanks!! but could you remove the cf.de and do a version with the backgroundcolor of the english tetris.swf and pause enabled ? would be great :banana:

thanks :)
Schorsch

lordofgun 08-24-2002 04:56 AM

Quote:

Originally posted by Souly
Here are Number TWO:
english, 16 Levels (6 new) very hard! pause is enabled

[INSTALL]
Download the tetris.zip File, unpack it and copy the tetris.swf File in your forum root and let test your user the 6 new level!
.................................................. .................................................. ..

I would like this version, but when i got to level 10, it still had 1000 levels. could you bring it down to 10 or 20 since you have 16 levels?

pstdgt 08-24-2002 05:47 AM

Quote:

Originally posted by john.eovie
Since there are other security items in place, you could block out all no permission pages for the "reg" action with a simple if statement. Non members would be able to access that reg page, but they wouldn't be able to do anything...

..could you please be a little more specific.. i didn't quite understand the method your are describing here.. i'm not asking for code but for a explanation of the method

Souly 08-24-2002 07:01 AM

I have found a very big BUG in my last Files, you MUST update! Sorry for it, but i was to tired last night :eek:

Here is my new file, includes all fla?s ,versions and german original bg color@schorsch ;)!

Plz give me feedback, if you have tested lvl 11 - 16 .. thx

Quote:

Originally posted by lordofgun


I would like this version, but when i got to level 10, it still had 1000 levels. could you bring it down to 10 or 20 since you have 16 levels?

Sorry, now you have 50 Lines on Lvl 10!

dreamerzrealm 08-24-2002 07:15 AM

I just installed it and its awesome!!! Good job man, hope you make some more games :)

http://www.dreamerzrealm.com w00t

lordofgun 08-24-2002 04:08 PM

thanks souly!

kypdurron 08-24-2002 04:50 PM

your last english with pause was actually english without pause

Martin64 08-24-2002 04:58 PM

Quote:

Originally posted by kypdurron
your last english with pause was actually english without pause
Nope :banana:

Ron ? DCS 08-24-2002 05:42 PM

Sorry if this has been posted before, but one of my (obviously) expert Tetris players on my site posted this message:

"After I complete level 10...the game takes me back to level 1, and it won't give me a chance to enter my name on the scoreboard.

Anyone else having the same problems?"

I really don't care one way or the other on this particular issue, and don't know if the problem is in tetris.swf or tetris.php (or whether it can fixed at all), I'm just pointing out a problem...

Thanks!

futureal 08-24-2002 05:56 PM

Somebody on my site reported the same issue. I still haven't touched the Tetris code; we have been working on a new game that is just about ready.

If anybody fixes the Tetris thing, post it here. :)

John 08-24-2002 06:01 PM

Quote:

Originally posted by futureal
Somebody on my site reported the same issue. I still haven't touched the Tetris code; we have been working on a new game that is just about ready.

If anybody fixes the Tetris thing, post it here. :)

Ooh, what game?!

BigJohnson 08-24-2002 06:10 PM

Quote:

Originally posted by john.eovie
I just thought people would prefer a store add on for the arcade hack, with more games - rather than just the tetris hack.

If there's enough demand, I'll do both.


The arcade is better. Sorry i was confused. The arcade is the way to go. Not just the tetris. I see now hahaha. Sory i am just dumb. Cant wait for the arcade version.

Will each game be able to have leader board or just the tetris one?

John 08-24-2002 06:11 PM

Quote:

Originally posted by BigJohnson



The arcade is better. Sorry i was confused. The arcade is the way to go. Not just the tetris. I see now hahaha. Sory i am just dumb. Cant wait for the arcade version.

Will each game be able to have leader board or just the tetris one?

All of them, of course ;)

futureal 08-24-2002 07:03 PM

Quote:

Originally posted by john.eovie
Ooh, what game?!
Breakout (a.k.a. Arkanoid, or at least I think that was how it was spelled).

Right now we are mainly just debating whether or not to include music in the game or not. Unfortunately, Flash does not support MIDIs, only WAV/MP3 music (at least in version 5, the one we have) which limits us a bit since we don't want the filesize to go nuts.

jbear6 08-24-2002 07:18 PM

Music? Yes!
That was my going to be my question. Is there an easy way to add music, even if it is a separate program, not part of the games code?

Thanks
Jbear

John 08-24-2002 07:19 PM

Could always embed a MIDI file.. :\

Castel 08-24-2002 07:21 PM

Quote:

Originally posted by Souly
I have found a very big BUG in my last Files, you MUST update! Sorry for it, but i was to tired last night :eek:

Here is my new file, includes all fla?s ,versions and german original bg color@schorsch ;)!

Plz give me feedback, if you have tested lvl 11 - 16 .. thx


Excellent, thanks for including the fla files. Nice job figuring out how to add and contruct levels. I'm a total flash newbie as well but now that I have the fla files I see how it's done and I will add my own custom levels.
BTW the english with pause has a glitch in lvl 13 (there are no blocks displayed at the beginning of the the lvl, looking at the code it think the problem is:

PHP Code:

     liv13[maxrig-2][12]=random(7)+100+1;
     
liv13[maxrig-7][12]=random(7)+100+1

The maximum value allowed for where you have [12] is [9] I believe.

futureal 08-24-2002 07:25 PM

Yea, that was one option, to just get a midi file running on the same page as the game. However, I was hoping to get level-by-level music going for a game like Tetris or Breakout. Without MIDI, that pretty much becomes impossible using Flash, because of the filesize restrictions. However, we still got sound effects working, and added a single loop of background music, and it sounds reasonably good with a filesize of around 140K.

Lanigironu 08-24-2002 07:33 PM

I'm pretty sure you can use MIDIs in Flash 6 and MX.

John 08-24-2002 07:34 PM

Quote:

Originally posted by Lanigironu
I'm pretty sure you can use MIDIs in Flash 6 and MX.
I had a good look, couldn't figure out how to... :(

N9ne 08-24-2002 07:56 PM

There's too many pages in here to read, I was wondering, have any leaderboard and king addons been released for any other games apart from tetris?

John 08-24-2002 07:58 PM

Well, there's the arcade hack which has space invaders, tetris, snake and pacman - each with a leaderboard system :)

Martin64 08-24-2002 08:00 PM

Quote:

Originally posted by john.eovie
Well, there's the arcade hack which has space invaders, tetris, snake and pacman - each with a leaderboard system :)
Please...release...now.

:D

John 08-24-2002 08:01 PM

Soon to post a screenshot, and start testing ;)

futureal 08-24-2002 08:20 PM

John, if you'd like to exchange Flash games with me that will work with the arcade, I can provide you with the fully functional Breakout, and we're in the process of working on a few others. I, too, would like to get some more scireboard-compatible games running to test out my system.

John 08-24-2002 08:24 PM

Quote:

Originally posted by futureal
John, if you'd like to exchange Flash games with me that will work with the arcade, I can provide you with the fully functional Breakout, and we're in the process of working on a few others. I, too, would like to get some more scireboard-compatible games running to test out my system.
Catch me on:

MSN: John@eovie.com
AIM: Billiam03k
ICQ: 40863144

Martin64 08-24-2002 10:57 PM

Quote:

Originally posted by Ron ? DCS
Sorry if this has been posted before, but one of my (obviously) expert Tetris players on my site posted this message:

"After I complete level 10...the game takes me back to level 1, and it won't give me a chance to enter my name on the scoreboard.

Anyone else having the same problems?"

I really don't care one way or the other on this particular issue, and don't know if the problem is in tetris.swf or tetris.php (or whether it can fixed at all), I'm just pointing out a problem...

Thanks!

Yeah, here too. From my board a user commented:

"Now wait a minute, I just beat DJ Unreals top score and it didnt add me to the leader board.

EDIT: Correction I was just below DJ Unreals Top Score, but I still should be second."


All times are GMT. The time now is 11:48 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.02101 seconds
  • Memory Usage 1,849KB
  • 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
  • (1)bbcode_code_printable
  • (2)bbcode_php_printable
  • (18)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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