Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Masterhand

Pages: [1]
1
General SMFShop Discussion / SMF Shop Ideas..:Job Lottery Auctions..
« on: November 18, 2006, 04:30:16 am »
Well, i would think that it would be cool if SMF shop had more included with it..

Right now it has something like this: cash/bank/shop, so why don't you add a few things too it?

cash/shop/bank/jobs/lottery/auctions

---Jobs---
Users can get jobs, then when the person who got 'hired' for the job does it, (ex.: Mod, Ranks, Post Fixer, Snitch) hits the 'Done' button,
the person who created the jobs clicks confirm, and the hired user gets a certain amounts or credits

--Lottery--
Users would bet a certain amount of credits , then set the minimum amount of credits to put down for a "ticket" then set the date it goes off, it would randomly pick a winner and the winner would get the set credit amount.

--Auctions--
This is like the Lottery, but only people place bids, and the person puts down a item for the winner.

Iwould love to see these things implanted...
That would make more people want SMF shop, and it would make it cooler....What do you think?..

2
Items / New items: Red Balls
« on: November 17, 2006, 09:49:19 am »
Here are the 2 files for the Redball items - There fun,
I had fun making them too.

Redball
Code: [Select]
<?php
/**********************************************\
| SMFSHOP (Shop MOD for Simple Machines Forum) |
|         (c) 2006 DanSoft Australia           |
|      http://www.dansoftaustralia.net/        |
\**********************************************/

//File: RedBall.php
//      Item

// VERSION: 2.3 (Build 11)
// $Date: 2006-10-21 13:34:18 +1000 (Sat, 21 Oct 2006) $
// $Id: RedBall.php 24 2006-10-21 03:34:18Z MH $

class item_RedBall extends itemTemplate {
    function 
getItemDetails() {
$this->authorName "Masterhand";
$this->authorWeb "GAC";
$this->authorEmail "austin.r.tanay@gmail.com";

        
$this->name "RedBall";
        
$this->desc "Bounce It And See What it Does!";
        
$this->price 200;
    }

    function 
getUseInput() {
global $context$scripturl$settings$txt;
        return 
"Bounce to: <input type='text' name='username' />
        <a href='
{$scripturl}?action=findmember;input=username;quote=0;sesc={$context['session_id']}' onclick='return reqWin(this.href, 350, 400);'><img src='{$settings['images_url']}/icons/assist.gif' border='0' alt='{$txt['find_members']}' /> Find Member</a><br />";
    }

    function 
onUse() {
        global 
$db_prefix$ID_MEMBER;

if (!isset($_POST['username']) || $_POST['username'] == '') die("ERROR: Please enter a username!");

        
$result db_query("UPDATE {$db_prefix}members
                            SET posts = posts - 100
                            WHERE memberName = '
{$_POST['username']}'",
                            
__FILE____LINE__);
        return 
"Uh-Oh, The Ball Bounced around, and {$_POST['username']}Missed it and it knocked him out, and he lost some of his post count by 100..Whoops..";
    }

}

?>

Redball 2
Code: [Select]
<?php

/**********************************************\
| SMFSHOP (Shop MOD for Simple Machines Forum) |
|         (c) 2006 DanSoft Australia           |
|      http://www.dansoftaustralia.net/        |
\**********************************************/

//File: Redball2.php

// VERSION: 2.3 (Build 11)
// $Date: 2006-11-17 13:34:18 +1000 (Fri, 17 Nov 2006) $
// $Id: Redball2.php 24 2006-10-21 03:34:18Z Mh $
global $sourcedir;
require_once(
$sourcedir '/Subs-Post.php');
class 
item_Redball2 extends itemTemplate {
    
    function 
getItemDetails() {

$this->authorName "Masterhand";
                
$this->authorWeb "http://www.gameandcoders.uni.cc";
$this->authorEmail "austin.r.tanay@gmail.com";

          
$this->name "RedBall2";
          
          
$this->desc "Redball 2";
          
// The item's price
          
$this->price 100;

       
   
          
$this->require_input true;
         
          
$this->can_use_item true;
    }

    
      function 
getAddInput() {
        return 
"Max amount to give: <input type='text' name='info1' value='100'><br>
               Max amount to take: <input type='text' name='info2' value='-100'>"
;
    
}  


       function 
getUseInput() {
       
global 
$context$scripturl$settings$txt;
        return 
"Bounce To: <input type='text' name='stealfrom' size='50'>
         <a href='
{$scripturl}?action=findmember;input=stealfrom;quote=0;sesc={$context['session_id']}' onclick='return reqWin(this.href, 350, 400);'><img src='{$settings['images_url']}/icons/assist.gif' border='0' alt='{$txt['find_members']}' /> Find Member</a>";
    }
    
    function 
onUse() {
        global 
$db_prefix$ID_MEMBER$user$item_info;
   
$pmfrom = array(
            
'id' => 1,
            
'name' => 'Admin',
            
'username' => 'Admin'
        
);
        
        
$pmto = array(
            
'to' => array($_POST['stealfrom']),
            
'bcc' => array()
        );
     
$result db_query("SELECT realName
                                FROM 
{$db_prefix}members
                                WHERE ID_MEMBER = 
{$ID_MEMBER}"__FILE____LINE__);
     
$row mysql_fetch_array($resultMYSQL_ASSOC);
$user $row["realName"];

       if (
$user == $_POST['stealfrom']) {
return 
"You cant throw it too yourself!";
die();
  }

else {
$amount mt_rand($item_info[2], $item_info[1]);

$result db_query("UPDATE {$db_prefix}members
                                SET money = money + 
{$amount}
                                WHERE realName = '
{$_POST['stealfrom']}'"__FILE____LINE__);
                                
sendpm($pmto'Heres a redball?'"<b>{$user}</b> Bounces The Ball To You And You Lose/Win ".formatMoney($amount)."! [i] You do not need to reply to this automated message"0$pmfrom); ;
                                return 
"You've thrown the ball to {$_POST['stealfrom']} if he catches it he'll gain money, else he'll lose it!!!";

       
$result db_query("SELECT ID_MEMBER
       FROM 
{$db_prefix}members
       WHERE realName = '
{$_POST['stealfrom']}'"__FILE____LINE__);
       
$row mysql_fetch_array($resultMYSQL_ASSOC);


            }

  }
  }

?>


Pages: [1]