Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Gold Hack (currency hack) Details »»
Gold Hack (currency hack)
Version: 1.00, by g-force2k2 g-force2k2 is offline
Developer Last Online: May 2008 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 08-25-2002 Last Update: Never Installs: 14
 
No support by the author.

well it was requested (asked) whatever you may call it... to create a currency hack that is more optimizeable... well here's my version of a currency hack (i just use gold because that's what i call my currency)

What is more optimizeable? You can configure which forums that you want gold(currency) to be gained in... and you can also configure different amounts... so for instance if you're a gaming forum place less emphasis on general forums by giving less gold and on gaming forums give more emphasis by giving more gold(currency)

hope that just about explains it all Enjoy...

g-force2k2

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 08-26-2002, 07:53 AM
[D]Vincent's Avatar
[D]Vincent [D]Vincent is offline
 
Join Date: Jun 2002
Location: In my own little world?
Posts: 411
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Right well I made an easy add-on for this. Okay what this add-on does is makes it to where you can set a different ammount for new threads than the ammount for replys, because we me I like to give the members more for threads. Anyways do the following:
First run this query:

ALTER TABLE forum ADD goldppt int(5) NOT NULL

Next open admin/forum.php and find:

makeinputcode("Gold recieved for posting? (forum gold must be enabled)","goldpp",0);

Replace that with:

makeinputcode("Gold recieved for posting a reply? (forum gold must be enabled)","goldpp",0);
makeinputcode("Gold recieved for posting a thread? (forum gold must be enabled)","goldppt",0);

Next find:

$DB_site->query("INSERT INTO forum
(forumid,styleid,title,description,active,displayo rder,parentid,
parentlist,allowposting,cancontainthreads,daysprun e,newpostemail,newthreademail,
moderatenew,allowhtml,allowbbcode,allowimages,allo wsmilies,allowicons,
styleoverride,allowratings,countposts,moderateatta ch,countgold,goldpp)
VALUES
(NULL,'$styleset','".addslashes($title)."','".adds lashes($description)."','$isac tive','$displayorder','$parentid',
'','$allowposting','$cancontainthreads','$daysprun e','".addslashes($newpostemail )."','".addslashes($newthreademail)."',
'$moderatenew','$aallowhtmlcode','$aallowbbcode',' $aallowimgcode','$aallowsmilie s','$aallowicons',
'$styleoverride','$allowratings','$countposts','$m oderateattach','$countgold','$ goldpp')");

Replace that with:

$DB_site->query("INSERT INTO forum
(forumid,styleid,title,description,active,displayo rder,parentid,
parentlist,allowposting,cancontainthreads,daysprun e,newpostemail,newthreademail,
moderatenew,allowhtml,allowbbcode,allowimages,allo wsmilies,allowicons,
styleoverride,allowratings,countposts,moderateatta ch,countgold,goldpp,goldppt)
VALUES
(NULL,'$styleset','".addslashes($title)."','".adds lashes($description)."','$isac tive','$displayorder','$parentid',
'','$allowposting','$cancontainthreads','$daysprun e','".addslashes($newpostemail )."','".addslashes($newthreademail)."',
'$moderatenew','$aallowhtmlcode','$aallowbbcode',' $aallowimgcode','$aallowsmilie s','$aallowicons',
'$styleoverride','$allowratings','$countposts','$m oderateattach','$countgold','$ goldpp','$goldppt')");

Next find:

makeinputcode("Gold recieved for posting? (forum gold must be enabled)","goldpp",$forum[goldpp]);

Replace that with:

makeinputcode("Gold recieved for posting a reply? (forum gold must be enabled)","goldpp",$forum[goldpp]);
makeinputcode("Gold recieved for posting a thread? (forum gold must be enabled)","goldppt",$forum[goldppt]);

Next find:

styleoverride='$styleoverride', allowratings='$allowratings', countposts='$countposts',
moderateattach='$moderateattach', countgold='$countgold', goldpp='$goldpp'
WHERE forumid='$forumid'");

Replace that with:

styleoverride='$styleoverride', allowratings='$allowratings', countposts='$countposts',
moderateattach='$moderateattach', countgold='$countgold', goldpp='$goldpp', goldppt='$goldppt'
WHERE forumid='$forumid'");

open newthread.php and find:

// +++++++ Gold Hack g-force2k2 +++++++
$DB_site->query("UPDATE user SET
".iif ($foruminfo[countposts],"posts=posts+1,","")."
$dotitle"."lastpost='".time()."' ".iif($foruminfo[countgold],",gold=gold+$foruminfo[goldpp]","")." WHERE userid='$bbuserinfo[userid]'");
}
// +++++++ Gold Hack g-force2k2 +++++++

Replace that with:

// +++++++ Gold Hack g-force2k2 +++++++
$DB_site->query("UPDATE user SET
".iif ($foruminfo[countposts],"posts=posts+1,","")."
$dotitle"."lastpost='".time()."' ".iif($foruminfo[countgold],",gold=gold+$foruminfo[goldppt]","")." WHERE userid='$bbuserinfo[userid]'");
}
// +++++++ Gold Hack g-force2k2 +++++++

And you're done I believe. Haven't tested it out yet though =\ I'm not actually installing this hack until tomorrow because I'm letting my memebrs write down how much gold they have(lol I use gold on FFL also).

BTW if you want to set a defualt one run this query:

UPDATE forum SET goldppt='[ Default Value Here ]' WHERE forumid != 0

and replace [ Default Value Here ] with the number.
Reply With Quote
  #13  
Old 08-26-2002, 08:55 AM
FFMania FFMania is offline
 
Join Date: Mar 2002
Posts: 46
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can I replace the current Lesane Store hack money system with this? And am I able to keep the current gil counts too?
Reply With Quote
  #14  
Old 08-26-2002, 10:19 AM
[D]Vincent's Avatar
[D]Vincent [D]Vincent is offline
 
Join Date: Jun 2002
Location: In my own little world?
Posts: 411
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I think to replace the Store one would take more coding and If you write them down you can.
Reply With Quote
  #15  
Old 08-26-2002, 11:01 AM
[D]Vincent's Avatar
[D]Vincent [D]Vincent is offline
 
Join Date: Jun 2002
Location: In my own little world?
Posts: 411
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Vincent][high]* [D]Vincent cough
[/high]

Okay well I went ahead and made two of the features for the points hack for this and I DO NOT TAKE CREDIT FOR ANYTHING IN THIS FOLLOWING ZIP, I repeat, I DO NOT TAKE CREDIT FOR ANYTHING IN THIS FOLLOWING ZIP.

Anyways what I did was made the donation hack and made the thing with admins/mods can give them gold from postbit work with this hack. All instructions are included in the zip, everything is tested and works. For a demo go to: http://www.fflounge.com not that it will really show out any. Anyways enjoy these add-ons. If you find any errors then just report them too many.


And once again, I DO NOT TAKE CREDIT FOR ANYTHING IN THE FOLLOWING ZIP!!!!!!
ALL CREDIT FOR THE DONATE ADD-ON GOES TO GameZilla!!!!
ALL CREDIT FOR THE ADMINS/SMS CAN GIVE MEMBERS POINTS FROM POSTBIT GOES TO Palmer of the Turks!!!!
ALL CREDIT FOR THE DIFFERENT AMOUNT RECIEVED FOR POSTING A NEW THREAD GOES TO g-force2k2!!!!
Reply With Quote
  #16  
Old 08-26-2002, 12:15 PM
Ninth Dimension's Avatar
Ninth Dimension Ninth Dimension is offline
 
Join Date: Oct 2001
Location: London, England.
Posts: 739
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I like the idea of this hack, I've just removed the itemshop from my forum because of the extra queries it was generating.

Now i'm looking for a points system for my forum, I was going to go for the Karma hack, but I think I prefer this one because I can provide more points for my games based forums.

The only problem I've got is, what will the users we working towards? I can understand that gaining more points that other forum members in itself is an achievement, but I'd still prefer to be able to offer a reward for it.

Can anyone offer any suggestions? (PS, i'm not interested in installing the store hack, I don't feel that it would really fit in with my site)
Reply With Quote
  #17  
Old 08-26-2002, 12:43 PM
g-force2k2 g-force2k2 is offline
 
Join Date: Mar 2002
Location: Everywhere you wanna be..
Posts: 1,608
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ninth Dimension just use the store hack... [D]Vincent its is very compatible with the store hack... just where it says in the changes for newreply and newthread... just change:

PHP Code:
gold=gold
to:

PHP Code:
storep=storep
in both the newreply.php and newthread.php... its that configurable easy enough

g-force2k2
Reply With Quote
  #18  
Old 08-26-2002, 03:05 PM
[D]Vincent's Avatar
[D]Vincent [D]Vincent is offline
 
Join Date: Jun 2002
Location: In my own little world?
Posts: 411
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Vincent]lol sorry I haven't used the store hack so I didn't know how easy it would be lol anyways do you think you can make it to where admins can edit the ammount of gold they have in admin cp? If I don't figure it out myself before you post that is since I've done that with the past things lmao.

-Edit-
I got figured it out myself lmao.


Anyways I have another request, do you think you could make it to where admins can subtract gold from a user like it has the add gold? Like instead of having the link of gold take you to giving them gold it could take you too a selection between giving them gold or removing gold from them. That would make things much easier ^^
-edit 2-
I'm on a roll I figured that last one out myself also very simple though lmao.
Reply With Quote
  #19  
Old 08-26-2002, 03:24 PM
N9ne N9ne is offline
 
Join Date: Feb 2002
Posts: 1,495
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I really like this hack because it's so simple! I'm going to install it on my test board once I request these things:

Right now there's a feature where you need a certain amount of posts for getting a Custom Avatar and/or Custom Title.

Can this be integrated with that so you need a certain amount of gold AND/OR posts [boolean] are required for either/both?

Also, can there be a system not unlike Lesane's Lottery Hack just for this? So users can buy a lottery ticket from somewhere, preferably on forumhome, where you could have:

Lottery: Buy your ticket now by clicking here!<br>
Current Jackpot: 3000 Points [or whatever you set as your currency]

Hope i'm not asking too much
Reply With Quote
  #20  
Old 08-26-2002, 03:31 PM
g-force2k2 g-force2k2 is offline
 
Join Date: Mar 2002
Location: Everywhere you wanna be..
Posts: 1,608
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Tha Rock the store hack is compatible with this hack if you search the thread you will see the simple mod edit to this...

btw [D]Vincent can't you just use the store donation on the admincp? (that is if you're using the store hack) if not i can code something fast for you if you like?

regards...

g-force2k2
Reply With Quote
  #21  
Old 08-26-2002, 03:35 PM
N9ne N9ne is offline
 
Join Date: Feb 2002
Posts: 1,495
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by g-force2k2
Tha Rock the store hack is compatible with this hack if you search the thread you will see the simple mod edit to this...

btw [D]Vincent can't you just use the store donation on the admincp? (that is if you're using the store hack) if not i can code something fast for you if you like?

regards...

g-force2k2
Well I dont want to use the store hack but would I be able to make the lottery hack work with this?
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:43 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04716 seconds
  • Memory Usage 2,324KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete