News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

[Mod] SMF Arcade SA Shop Integration 2.0

Started by 0mfg wtf man, March 29, 2012, 02:11:56 PM

Previous topic - Next topic

0mfg wtf man

Requires
- SMF Arcade 2.5 RC1 -  http://mods.simplemachines.org/index.php?mod=36
- SMFShop3.2 - http://mods.simplemachines.org/?mod=65

Description
This mod allows users to get money/cash for the shop after getting a high score in the game. This mod also has a arcade pass feature. Once mod is installed, every user needs to have a arcade pass in order to use arcade.

The default amount that a user receives after getting a high score is 25
If you wanna change how much each user gets when getting a high score. Open up /Sources/Subs-Arcade.php
// Give the user their points
$smcFunc['db_query']('', '
UPDATE {db_prefix}members
SET money = money + 25
WHERE id_member = {int:member}
LIMIT 1',
array(
'member' => $user_info['id'],
)
);

Search for this code and change the 25 to whatever number you want them to receive after getting a high score




Masterd

#1
There's no need for manual editing. You can just set it as another modification setting.

Biology Forums

Quote from: 0mfg wtf man on March 29, 2012, 02:11:56 PM

// Give the user their points
$smcFunc['db_query']('', '
UPDATE {db_prefix}members
SET money = money + 25
WHERE id_member = {int:member}
LIMIT 1',
array(
'member' => $user_info['id'],
)
);


This is exactly what I want (minus the arcade pass). I just want the champ to earn x number of points. But I need it for 1.x, could someone please convert this to 1.x coding :(

Kimmie



LadyAngel


Advertisement: