vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   ibProArcade Archive (https://vborg.vbsupport.ru/forumdisplay.php?f=174)
-   -   Can not submit score with 4.1.1 (https://vborg.vbsupport.ru/showthread.php?t=257055)

nguyentrongphuc 01-13-2011 11:19 AM

Can not submit score with 4.1.1
 
Done!
Thank all :P

Digital Jedi 01-13-2011 11:38 PM

Well, that was easy. :)

orillia 01-14-2011 04:12 PM

I only wish I knew what he did... the one on my site won't post scores and I haven't found anything that looks wrong yet. :(

Okay, entered the code in this post and it works now. Sorry; gotta start lookin' before I leap.

Digital Jedi 01-14-2011 06:16 PM

We should note that this information is also located in ZIP file with ibProArcade.

orillia 01-14-2011 08:08 PM

Quote:

Originally Posted by Digital Jedi (Post 2149096)
We should note that this information is also located in ZIP file with ibProArcade.

Ahhh, you see... I didn't originally install the hack. I like to read; anything called 'readme' gets my attention immediately. The site's former admins have all disappeared across the horizon.

This thread showed up in the search before the one that said 'do this'. Ba-da-bing, ba-da-boom. I am having my second shot at n00b-ism. :LOL

Hippy 01-15-2011 12:39 AM

did you figure it out orillia..
if not here is the fix

Code:

If you are using vbAdvanced Portal and your /index.php is not the original one from vBulletin,
you have to edit your alternate index.php:

open index.php

At the very beginning of the File, right after:
----------------------------------------------------------
<?php
----------------------------------------------------------

you have to insert:
----------------------------------------------------------
// ibProArcade
if($_POST['module'] == "pnFlashGames")
{
        require_once('./global.php');

        switch($_POST['func'])
        {
                case "storeScore":
                $_GET['act'] = "Arcade";
                $_GET['module'] = "arcade";
                $_GET['do'] = "pnFStoreScore";
                break;

                case "saveGame":
                $_GET['do'] = "pnFSaveGame";
                break;

                case "loadGame":
                $_GET['do'] = "pnFLoadGame";
                break;

                case "loadGameScores":
                $gid = $vbulletin->input->clean_gpc('p', 'gid', TYPE_INT);
                $uid= $vbulletin->userinfo['userid'];
                $game = $db->query_first("SELECT * FROM " . TABLE_PREFIX . "games_scores WHERE mid=$uid AND gid = $gid ORDER BY score DESC LIMIT 0,1");
                $scores = $game[score];

                if($scores != false)
                {
                        //Return true
                        print "&opSuccess=true&gameScores=$scores&endvar=1"; //send endvar to keep opSuccess separate from all other output from PostNuke
                }
                else
                {
                        print "&opSuccess=false&error=Error&endvar=1";
                }
                break;
        }
}

$act = $_GET[act];
$autocom = $_GET[autocom];
$showuser= $_GET[showuser];
if($act == "Arcade" || $autocom=="arcade") {
include "arcade.php";
exit();
}
if(!empty($showuser) && $showuser >= 1) {
$u = $showuser;
$_GET[u] = $showuser;
include "member.php";
exit();
}

// end of ibProArcade
----------------------------------------------------------


Otherwise your scores won't be recorded :)


orillia 01-15-2011 01:58 AM

Yes, I did, but thanks very much.

just77me 01-20-2011 02:52 PM

same problem with vbulletin 4.11 cant save the score and use the vbulletin cms do i have to integrate that code anywhere in the header or where else?

thank you.

Edrondol 01-20-2011 06:00 PM

This above fix did not work for me.

orillia 01-20-2011 06:21 PM

Read these two posts:

https://vborg.vbsupport.ru/showpost....71&postcount=2

https://vborg.vbsupport.ru/showpost....37&postcount=8

These will solve the problem.

Edrondol 01-20-2011 11:32 PM

Thanks, I just went with V3Arcade, worked right out of the box.

--------------- Added [DATE]1295615371[/DATE] at [TIME]1295615371[/TIME] ---------------

Well, I decided to try again, and when the code is added to my index.php, when I launch it, I get 500 errors.

Grrr.

just77me 01-21-2011 02:24 PM

any help please?

Das Ergebnis wurde offenbar nicht vom zugehörigen Spiel übermittelt. Es wird kein Ergebnis gespeichert.

Hippy 01-21-2011 10:37 PM

Quote:

Originally Posted by Edrondol (Post 2152176)
Thanks, I just went with V3Arcade, worked right out of the box.

--------------- Added [DATE]1295615371[/DATE] at [TIME]1295615371[/TIME] ---------------

Well, I decided to try again, and when the code is added to my index.php, when I launch it, I get 500 errors.

Grrr.

right after <?php
add

Code:

// ibProArcade
if($_POST['module'] == "pnFlashGames")
{
        require_once('./global.php');

        switch($_POST['func'])
        {
                case "storeScore":
                $_GET['act'] = "Arcade";
                $_GET['module'] = "arcade";
                $_GET['do'] = "pnFStoreScore";
                break;

                case "saveGame":
                $_GET['do'] = "pnFSaveGame";
                break;

                case "loadGame":
                $_GET['do'] = "pnFLoadGame";
                break;

                case "loadGameScores":
                $gid = $vbulletin->input->clean_gpc('p', 'gid', TYPE_INT);
                $uid= $vbulletin->userinfo['userid'];
                $game = $db->query_first("SELECT * FROM " . TABLE_PREFIX . "games_scores WHERE mid=$uid AND gid = $gid ORDER BY score DESC LIMIT 0,1");
                $scores = $game[score];

                if($scores != false)
                {
                        //Return true
                        print "&opSuccess=true&gameScores=$scores&endvar=1"; //send endvar to keep opSuccess separate from all other output from PostNuke
                }
                else
                {
                        print "&opSuccess=false&error=Error&endvar=1";
                }
                break;
        }
}

$act = $_GET[act];
$autocom = $_GET[autocom];
$showuser= $_GET[showuser];
if($act == "Arcade" || $autocom=="arcade") {
include "arcade.php";
exit();
}
if(!empty($showuser) && $showuser >= 1) {
$u = $showuser;
$_GET[u] = $showuser;
include "member.php";
exit();
}

// end of ibProArcade


drgonzo3000 05-05-2011 02:34 AM

:mad: Edited the index.php page and added the code and got the following error:

Parse error: syntax error, unexpected T_STRING in /home/gonzoin1/public_html/co3s/index.php on line 11


Had to roll back the changes to get the forum back online. Below is the code I was using:

PHP Code:

<?php
// ibProArcade
if($_POST['module'] == "pnFlashGames")
{
    require_once(
'./global.php');

    switch(
$_POST['func'])
    {
        case 
"storeScore":
        
$_GET['act'] = "Arcade";
        
$_GET['module'] = "arcade";
        
$_GET['do'] = "pnFStoreScore";
        break;

        case 
"saveGame":
        
$_GET['do'] = "pnFSaveGame";
        break;

        case 
"loadGame":
        
$_GET['do'] = "pnFLoadGame";
        break;

        case 
"loadGameScores":
        
$gid $vbulletin->input->clean_gpc('p''gid'TYPE_INT);
        
$uid$vbulletin->userinfo['userid'];
        
$game $db->query_first("SELECT * FROM " TABLE_PREFIX "games_scores WHERE mid=$uid AND gid = $gid ORDER BY score DESC LIMIT 0,1");
        
$scores $game[score];

        if(
$scores != false)
        {
            
//Return true
            
print "&opSuccess=true&gameScores=$scores&endvar=1"//send endvar to keep opSuccess separate from all other output from PostNuke
        
}
        else
        {
            print 
"&opSuccess=false&error=Error&endvar=1";
        }
        break;
    }
}

$act $_GET[act];
$autocom $_GET[autocom];
$showuser$_GET[showuser];
if(
$act == "Arcade" || $autocom=="arcade") {
include 
"arcade.php";
exit();
}
if(!empty(
$showuser) && $showuser >= 1) {
$u $showuser;
$_GET[u] = $showuser;
include 
"member.php";
exit();
}

// end of ibProArcade

// ++=========================================================================++

// || vBadvanced CMPS v4.0.1 (vB 4.0) - 115999

// || ? 2003-2011 vBadvanced.com - All Rights Reserved

// || This file may not be redistributed in whole or significant part.

// || http://vbadvanced.com

// || Downloaded 08:10, Thu Jan 6th 2011

// || 450115999_404217057982

// ++ ========================================================================++



error_reporting(E_ALL & ~E_NOTICE & ~8192);

define('THIS_SCRIPT''adv_index');

define('VBA_PORTAL'true);

define('VBA_SCRIPT''CMPS');



// ============================================

// Enter the full path to your forum here

// Example: /home/vbadvanced/public_html/forum

// ============================================



$forumpath '';



// ============================================

// No Further Editing Necessary!

// ============================================



if ($forumpath)

{

    if (!
is_dir($forumpath))

    {

        echo 
'Invalid forum path specified! Please edit this file and be sure to include the correct path for your $forumpath variable.';

        exit;

    }



    
chdir($forumpath);

}



$phrasegroups = array();

$globaltemplates = array();

$actiontemplates = array();

$specialtemplates = array();



require_once(
'./includes/vba_cmps_include_template.php');

require_once(
'./global.php');



print_portal_output($home);



?>


Any Ideas???


All times are GMT. The time now is 04:55 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.01188 seconds
  • Memory Usage 1,793KB
  • 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_code_printable
  • (1)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (14)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