The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
![]()
Very Simple I presume
Just how do I do it ? I dont want to add any reward things or anything like that, just simple give users +10 posts if they post a thread. Thanks ![]() PS: also when i delete the thread it needs to -10 postcounts from the user that started it. I am using VB 2.3.0 |
#2
|
||||
|
||||
![]()
Open root/newthread.php
Find: Code:
$DB_site->query("UPDATE user SET ".iif ($foruminfo[countposts],"posts=posts+1,","")." $dotitle"."lastpost='".time()."' WHERE userid='$bbuserinfo[userid]'"); } Code:
$DB_site->query("UPDATE user SET ".iif ($foruminfo[countposts],"posts=posts+10,","")." $dotitle"."lastpost='".time()."' WHERE userid='$bbuserinfo[userid]'"); } Find: Code:
if (is_array($userpostcount)) { while(list($postuserid,$subtract)=each($userpostcount)) { $DB_site->query("UPDATE user SET posts=posts$subtract WHERE userid='$postuserid'"); } } Code:
if (!empty($userpostcount)) { $DB_site->query("UPDATE user SET posts=posts-9 WHERE userid='$postuserid'"); } ![]() It says [high]-9[/high], as the query above it will reduce the user's post count for the amount of posts in that thread that they made, so the first post will be counted as 1 post, so to make it remove 10 you have to subtract the 1 which was already removed, leaving you with 9 to remove afterwards ![]() It should all work ![]() Satan |
#3
|
||||
|
||||
![]()
Satan thanks alot
![]() |
#4
|
||||
|
||||
![]()
Works
![]() |
#5
|
||||
|
||||
![]()
No problemos
![]() Satan |
![]() |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|