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.


Messages - Coolgem

Pages: 1 [2]
16
Modifications / Re: SMF Lottery Mod
« on: March 29, 2013, 08:09:48 am »
Links broken. Anyone have a working link? That would help.

17
Items / SMFShop Pets ~~ Adds Dogs and Cats to SMFShop!
« on: March 29, 2013, 03:57:40 am »
Before I start, no, this is NOT SMFPets by Basil Beard. That's a real modification. This is just a package that installs two items to SMFShop. Simple. Oh, and another thing: It does not change anything in your SMF or SMFShop installation or do anything to the databases. I promise.

Okay, now, let me introduce you to this package for SMFShop:

SMFShop Pets is a package that adds dogs and cats to SMFShop. The items are based on my fortune cookie item that I made earlier this month. Everytime you use the pet, the site tells you what happened, like this message:
Quote
You took the dog for a walk, when it met another dog and 'talked' to eachother.

This is how you install it:

You download the zip file below, and you go to your package manager in the administration center, and then upload it and then install it. Easy as pie! :D

LINK: http://www.4shared.com/zip/oJFOsYXW/SMFShop_Pets.html

Tell me if there is a problem. This package was tested on SMF 2.0.4 with SMFShop 3.2 installed and worked with no problem.

18
General SMFShop Discussion / Re: Problem in Default Theme!
« on: March 27, 2013, 10:56:25 am »
Strange. It seems you might have to use a custom tab smf software like this one at http://custom.simplemachines.org/mods/index.php?mod=2657 and configure one of those tabs to go to the SMFShop page. I hope I helped you!  :)

19
General SMFShop Discussion / Re: How can I install SMF Pets?
« on: March 27, 2013, 10:52:36 am »
I'm sorry to say but the creator of SMFShop (Basil Beard) has not updated SMF Pets in a really long time, so I think you might have to downgrade to a lower version of SMF to install it correctly. Sorry about that. :(

20
Items / Fortune Cookie item!
« on: March 27, 2013, 10:44:01 am »
This one's different then my previous items. This one does not require any input from the admin. It is a fortune cookie that tells users their fortune. Makes sense.  :D Let me know what you think.

Save as fortune.php

Code:
Code: [Select]
<?php
// This is just to make sure that the item is used through SMF, and people aren't accessing it directly
// Additionally, this is used elsewhere in SMF (in almost all the files)
if (!defined('SMF'))
   die(
'Hacking attempt...');


class 
item_fortune extends itemTemplate
{
   
// When this function is called, you should set all the item's
   // variables (see inside this example)
   
function getItemDetails() {

      
// The author's name
      
$this->authorName 'coolgem923';
      
// The author's email address
      
$this->authorEmail 'private';
      
      
// --- Values changeable from within the SMFShop admin panel ---
      // The name of the item
      
$this->name "Fortune Cookie";
      
// The item's description
      
$this->desc "What's your fortune?";
      
// The item's price
      
$this->price 50;

      
// --- Unchangeable values ---
      // These values can not be changed when adding the item, they are stuck on what you set them to here.
      
      // Whether inputs are required by this item. In this case, we get no inputs.
      
$this->require_input false;
      
      
$this->can_use_item true;
   }
   
   function 
onUse()
   {
      
$result Rand (1,8); 

if ($result ==1

Return "You may be rich."


if ($result ==2

Return "Evil things are coming your way..."


if ($result ==3

Return "You will find a little suprise from your friend."


if ($result ==4

Return "Your long-lost friend will see you again."


if ($result ==5

Return "Your favorite thing may fall off a cliff and you will never see it again."


if ($result ==6

Return "You will win the lottery."


if ($result ==7

Return "You will turn into a humble king."


if ($result ==8

Return "You will journey to a land far away of peace and quiet."

}
}
?>

21
Items / 'Game Console' Item
« on: March 27, 2013, 10:41:33 am »
Another item. This is my second. It displays a message saying "You booted up your console and played a very fun game." with console being replaced with the game console the admin specifies. Let me know what you think.  ;)

Save as gameconsole.php
Code:
Code: [Select]
<?php
/**********************************************************************************
* SMFShop item                                                                    *
***********************************************************************************
* SMFShop: Shop MOD for Simple Machines Forum                                     *
* =============================================================================== *
* Software Version:           SMFShop 3.1 (Build 14)                              *
* Software by:                DanSoft Australia (http://www.dansoftaustralia.net/)*
* Copyright 2009 by:          vbgamer45 (http://www.smfhacks.com)                 *
* Copyright 2005-2007 by:     DanSoft Australia (http://www.dansoftaustralia.net/)*
* Support, News, Updates at:  http://www.dansoftaustralia.net/                    *
*                                                                                 *
* Forum software by:          Simple Machines (http://www.simplemachines.org)     *
* Copyright 2006-2007 by:     Simple Machines LLC (http://www.simplemachines.org) *
*           2001-2006 by:     Lewis Media (http://www.lewismedia.com)             *
***********************************************************************************
* This program is free software; you may redistribute it and/or modify it under   *
* the terms of the provided license as published by Simple Machines LLC.          *
*                                                                                 *
* This program is distributed in the hope that it is and will be useful, but      *
* WITHOUT ANY WARRANTIES; without even any implied warranty of MERCHANTABILITY    *
* or FITNESS FOR A PARTICULAR PURPOSE.                                            *
*                                                                                 *
* See the "license.txt" file for details of the Simple Machines license.          *
* The latest version of the license can always be found at                        *
* http://www.simplemachines.org.                                                  *
***********************************************************************************/

if (!defined('SMF'))
die('Hacking attempt...');

class 
item_gameconsole extends itemTemplate 
{
function getItemDetails() 
{
$this->authorName 'coolgem923';
$this->authorWeb 'none';
$this->authorEmail 'private';

$this->name 'Game Console';
$this->desc 'Game Console for users to use.';
$this->price 50;

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

function getAddInput() 
{

global $item_info;
if ($item_info[1] == 0$item_info[1] = '';

return '
Name of game console (you may use BBCode here): 
<textarea name="info1" rows="1" style="width: 100%">' 
$item_info[1] . '</textarea>';

}

function onUse() 
{
global $item_info;

// What the site says when the game is 'played'.
return parse_bbc("You booted up your $item_info[1] and played a very fun game.");;
return parse_bbc($item_info[1]);

}

}

?>

22
Items / Food Item! (NOT SMFPets)
« on: March 27, 2013, 10:37:57 am »
This is my very first SMFShop item and I hope all of you like it. What this item does is shows the user this message "You ate a food.", replacing food with the name of the food the admin specifies. It is a simple item but that is no surprise because its my first. Tell me what you think!  :D


Save file as fooditem.php in order for this to work properly!

Here's the code:

Code: [Select]
<?php
/**********************************************************************************
* SMFShop item                                                                    *
***********************************************************************************
* SMFShop: Shop MOD for Simple Machines Forum                                     *
* =============================================================================== *
* Software Version:           SMFShop 3.1 (Build 14)                              *
* Software by:                DanSoft Australia (http://www.dansoftaustralia.net/)*
* Copyright 2009 by:          vbgamer45 (http://www.smfhacks.com)                 *
* Copyright 2005-2007 by:     DanSoft Australia (http://www.dansoftaustralia.net/)*
* Support, News, Updates at:  http://www.dansoftaustralia.net/                    *
*                                                                                 *
* Forum software by:          Simple Machines (http://www.simplemachines.org)     *
* Copyright 2006-2007 by:     Simple Machines LLC (http://www.simplemachines.org) *
*           2001-2006 by:     Lewis Media (http://www.lewismedia.com)             *
***********************************************************************************
* This program is free software; you may redistribute it and/or modify it under   *
* the terms of the provided license as published by Simple Machines LLC.          *
*                                                                                 *
* This program is distributed in the hope that it is and will be useful, but      *
* WITHOUT ANY WARRANTIES; without even any implied warranty of MERCHANTABILITY    *
* or FITNESS FOR A PARTICULAR PURPOSE.                                            *
*                                                                                 *
* See the "license.txt" file for details of the Simple Machines license.          *
* The latest version of the license can always be found at                        *
* http://www.simplemachines.org.                                                  *
***********************************************************************************/

if (!defined('SMF'))
die('Hacking attempt...');

class 
item_fooditem extends itemTemplate 
{
function getItemDetails() 
{
$this->authorName 'coolgem923';
$this->authorWeb 'none';
$this->authorEmail 'private';

$this->name 'Food';
$this->desc 'Food for users to eat.';
$this->price 1;

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

function getAddInput() 
{

global $item_info;
if ($item_info[1] == 0$item_info[1] = '';

return '
Name of food (you may use BBCode here): 
<textarea name="info1" rows="1" style="width: 100%">' 
$item_info[1] . '</textarea>';
}

function onUse() 
{
global $item_info;

// What the site says when the food is eaten.
return parse_bbc("You ate a $item_info[1].");;
return parse_bbc($item_info[1]);

}

}

?>

Pages: 1 [2]