make sure the spacing is exactly the same. some programs when you copy and paste auto create spaces and the verify looks for the exact code.mistycat wrote:Just done a new install of forum, and have added the arcade, but when verifying am told some files not edited? But I have made the edits on these files, any ideas?
The following files seem to not be edited:
phpbb_root_path/styles/prosilver/template/overall_header.html
<!-- IF S_ARCADE_FB -->
<meta property="og:site_name" content="{SITENAME}" />
<meta property="og:title" content="{ARCADE_FB_GN}" />
<meta property="og:image" content="{ARCADE_FB_GI}" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver/template/overall_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver/template/simple_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver_se/template/overall_header.html
<!-- IF S_ARCADE_FB -->
<meta property="og:site_name" content="{SITENAME}" />
<meta property="og:title" content="{ARCADE_FB_GN}" />
<meta property="og:image" content="{ARCADE_FB_GI}" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver_se/template/overall_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver_se/template/simple_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->Checking if all modules exist:All modules found
and i am told to add<!-- IF S_ARCADE_FB -->
<meta property="og:site_name" content="{SITENAME}" />
<meta property="og:title" content="{ARCADE_FB_GN}" />
<meta property="og:image" content="{ARCADE_FB_GI}" />
<!-- ENDIF -->
{META}
before meta<!-- IF S_ARCADE_FB -->
<meta property="og:site_name" content="{SITENAME}" />
<meta property="og:title" content="{ARCADE_FB_GN}" />
<meta property="og:image" content="{ARCADE_FB_GI}" />
<!-- ENDIF -->
I think the bad files line endings format.mistycat wrote:Just done a new install of forum, and have added the arcade, but when verifying am told some files not edited? But I have made the edits on these files, any ideas?
The following files seem to not be edited:
phpbb_root_path/styles/prosilver/template/overall_header.html
<!-- IF S_ARCADE_FB -->
<meta property="og:site_name" content="{SITENAME}" />
<meta property="og:title" content="{ARCADE_FB_GN}" />
<meta property="og:image" content="{ARCADE_FB_GI}" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver/template/overall_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver/template/simple_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver_se/template/overall_header.html
<!-- IF S_ARCADE_FB -->
<meta property="og:site_name" content="{SITENAME}" />
<meta property="og:title" content="{ARCADE_FB_GN}" />
<meta property="og:image" content="{ARCADE_FB_GI}" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver_se/template/overall_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->
phpbb_root_path/styles/prosilver_se/template/simple_header.html
<!-- IF S_IN_ARCADE -->
<link href="{T_THEME_PATH}/arcade.css" rel="stylesheet" type="text/css" media="screen, projection" />
<!-- ENDIF -->Checking if all modules exist:All modules found
when i open the html file in notepadEdit/Eol conversion/convert to UNIX format
If you change so you can be restored.mistycat wrote:no conversion necessary
Code: Select all
$sql = "SELECT game_reward
FROM " . ARCADE_GAMES_TABLE . " u ORDER BY u.game_reward";
$result = $db->sql_query($sql);
$row = $db->sql_fetchrow($result);
$game_reward = $row['game_reward'];
// Grant points on submit
$sql = 'UPDATE ' . USERS_TABLE . '
SET user_points = user_points + ' . $game_reward . '
WHERE user_id = ' . (int) $user->data['user_id'];
$db->sql_query($sql);
This code contains more errors.vipaka wrote:Which file (and where) would I need to insert this code to successfully submit the "game reward" value to all players who submit a score? (not just high score)
Edit: Figured it out. Needed to put this into the score.php file.
Code: Select all
$sql = "SELECT game_reward FROM " . ARCADE_GAMES_TABLE . " u ORDER BY u.game_reward"; $result = $db->sql_query($sql); $row = $db->sql_fetchrow($result); $game_reward = $row['game_reward']; // Grant points on submit $sql = 'UPDATE ' . USERS_TABLE . ' SET user_points = user_points + ' . $game_reward . ' WHERE user_id = ' . (int) $user->data['user_id']; $db->sql_query($sql);
http://phpbbarcade.origon.dk/viewtopic.php?p=821#p821Tony´S wrote:yet there is still the tournament addons?
No, the original code is intact so that high scores get double game_reward. What's buggy about it, it worked perfectly when I tested it in scores.php...KillBill. wrote:This code contains more errors.vipaka wrote:Which file (and where) would I need to insert this code to successfully submit the "game reward" value to all players who submit a score? (not just high score)
Edit: Figured it out. Needed to put this into the score.php file.
Code: Select all
$sql = "SELECT game_reward FROM " . ARCADE_GAMES_TABLE . " u ORDER BY u.game_reward"; $result = $db->sql_query($sql); $row = $db->sql_fetchrow($result); $game_reward = $row['game_reward']; // Grant points on submit $sql = 'UPDATE ' . USERS_TABLE . ' SET user_points = user_points + ' . $game_reward . ' WHERE user_id = ' . (int) $user->data['user_id']; $db->sql_query($sql);
The original code was deleted?
Or, high score case double get reward the user?
vipaka wrote: No, the original code is intact so that high scores get double game_reward. What's buggy about it, it worked perfectly when I tested it in scores.php...
Code: Select all
$sql = "SELECT game_reward
FROM " . ARCADE_GAMES_TABLE . " u
ORDER BY u.game_reward";
$result = $db->sql_query($sql);
$row = $db->sql_fetchrow($result);
$game_reward = $row['game_reward'];
// Grant points on submit
$sql = 'UPDATE ' . USERS_TABLE . '
SET user_points = user_points + ' . $game_reward . '
WHERE user_id = ' . (int) $user->data['user_id'];
$db->sql_query($sql);
FROM " . ARCADE_GAMES_TABLE . " u
-> FROM " . ARCADE_GAMES_TABLE . "
ORDER BY u.game_reward";
-> ORDER BY game_reward";
$row = $db->sql_fetchrow($result);
add after $db->sql_freeresult($result);
$game_reward = $row['game_reward'];
-> $game_reward = (float) $row['game_reward'];
Code: Select all
if ($arcade->points['show'] && $reward)
Code: Select all
if ($arcade->points['show'])
{
$playing_reward = ($reward === false) ? $arcade->get_reward($game_data) : $reward;
if ($playing_reward > 0)
{
$arcade->set_points('add', $user->data['user_id'], $playing_reward);
$reward = (float) ($reward + $playing_reward);
}
else
{
$reward = false;
}
}
I do not see zero.vipaka wrote:Ah, I like that even better, thanks. Except that it says "you've recieved 0 gold" on the confirmation page. *will fix it*