Author Topic: Cookie  (Read 9582 times)

Offline xfollowthereaperx

Cookie
« on: February 19, 2007, 06:13:13 am »
It's pretty much a rock, it doesn't do anything but instead you can use it, when you use it, it just says "You eatted the cookie" and it disappears without any advantages

Why would you want this? You could tell someone "Congratulations, have a cookie  O0 "
Then give them this item




Cookie.php

Code: [Select]
<?php
/**********************************************************************************
* SMFShop item                                                                    *
***********************************************************************************
* SMFShop: Shop MOD for Simple Machines Forum                                     *
* =============================================================================== *
* Software Version:           SMFShop 3.0 (Build 12)                              *
* $Date:: 2007-01-18 19:26:55 +1100 (Thu, 18 Jan 2007)                          $ *
* $Id:: Cookie.php            79 2007-01-18 08:26:55Z daniel15                  $ *
* Software by:                DanSoft Australia (http://www.dansoftaustralia.net/)*
* 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)             *
**********************************************************************************/

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

class 
item_Cookie extends itemTemplate
{

// When this function is called, you should set all the item's
function getItemDetails()
{

// The author of the item
$this->authorName 'xfollowthereaperx';
// The author's website
$this->authorWeb '';
// And their email address
$this->authorEmail 'xfollowthereaperx@hotmail.com';


// VALUES CHANGEABLE FROM WITHIN ADMIN PANEL:
  // The name of the item
  $this->name 'Cookie';
  // The item's description
  $this->desc 'Here, have a Cookie';
  // The item's price
  $this->price 10;
  
//UNCHANGEABLE VALUES:
  // Whether the item requires input or not.
  $this->require_input false;
  // Useable?
  $this->can_use_item true;
}

// Since this item requires no input, we don't need to have a getUseInput function
// here (see the testitem2.php file if you want to make an item that needs input)

function onUse()
{
return 'You eatted the cookie';
}

}
?>

« Last Edit: March 07, 2007, 07:32:35 am by xfollowthereaperx »

Offline HavoK XL

Re: Cookie item
« Reply #1 on: February 19, 2007, 04:52:26 pm »
Lol, thanks I will use this to give to my members when I feel they should be *greatly* rewarded..

Offline perplexed

Re: Cookie
« Reply #2 on: March 01, 2007, 12:38:47 am »
do you need to add a cookie image to this ?
Estne volumen in toga, an solum tibi libet me videre?

Offline xfollowthereaperx

Re: Cookie
« Reply #3 on: March 01, 2007, 04:05:23 am »
do you need to add a cookie image to this ?
You mean as an Icon? That would be nice, I've been looking for one.

Offline perplexed

Re: Cookie
« Reply #4 on: March 01, 2007, 06:58:00 am »
I think I have one somewhere,  I know I have a really big donut lol

*goes to browse files*
Estne volumen in toga, an solum tibi libet me videre?

Offline perplexed

Re: Cookie
« Reply #5 on: March 01, 2007, 11:52:32 pm »
chocolate chip cookie image attached

« Last Edit: March 26, 2007, 07:08:18 pm by perplexed »
Estne volumen in toga, an solum tibi libet me videre?

Offline Daniel15

Re: Cookie
« Reply #6 on: March 02, 2007, 05:16:38 pm »
Quote
You eatted the cookie
Ate! You ate the cookie! :D

Offline perplexed

Re: Cookie
« Reply #7 on: March 05, 2007, 02:56:34 am »
lol I changed it on my site :)
Estne volumen in toga, an solum tibi libet me videre?

Offline xfollowthereaperx

Re: Cookie
« Reply #8 on: March 05, 2007, 10:25:48 am »
Quote
You eatted the cookie
Ate! You ate the cookie! :D
I did that on purpose ^_~

Offline Masterhand

Re: Cookie
« Reply #9 on: March 06, 2007, 01:14:30 am »
Cookies are sweet right? Adding a query to update points +1 for each cookie, would be easy. I'll try that out.
~If at first you don't succed, hide all evidence that you tried.~ - Homer Simpson

Offline swali

Re: Cookie
« Reply #10 on: July 14, 2007, 12:28:03 am »
Here a little cookie  :P
Thank you for this ITEM !!!


Offline mike dijital

Re: Cookie
« Reply #11 on: October 17, 2008, 06:53:56 am »
works great on 1.1.6 with other mods

Offline Argentin

Re: Cookie
« Reply #12 on: November 13, 2008, 06:48:16 am »