![]() |
Display extra 'Golden' pips when members have large reputations
This modification is no longer available or supported. This simple modification extends the existing reputation display system into three flexible groups - dark green & light green pips (similar to the default) followed by 'golden' pips. The number and value of the pips in each group is defined by six variables in the code. The defaults in the hack make the first 5 pips worth 100, followed by 5 pips worth 200, followed by the golden pips worth 1000 (max 10) - so ; 1 - 100 = 1 Dark green 101 - 200 = 2 Dark green 401 - 500 = 5 Dark green 501 - 700 = 5 Dark green, 1 Light green 701 - 900 = 5 Dark green, 2 Light green 501 - 1500 = 5 Dark green, 5 Light green 1501 - 2500 = 5 Dark green, 5 Light green, 1 Gold 2501 - 3500 = 5 Dark green, 5 Light green, 2 Gold 10501 - onwards = 5 Dark green, 5 Light green, 10 Gold Negative reputations are similarly displayed in red (no gold). If your reputation is zero then the neutral grey pip is displayed. A screenshot of someone with 5000 points is attached (note: the word "Reputation:" has been removed from our postbit display, so only pips are shown). v1.1 Minor update: Added missing code for people who disable the display of their reputation. If you don't use or allow members to disable their display then you have nothing to worry about, otherwise just apply the modified hack. Also made the 'golden ball' slightly less dark. v1.21 Added another level for people who exceed all the pips set in the main three levels - this displays a larger 'star' for each time they have passed the maximum allowed by the three pip levels - and then resets the pips to start again. Another star will be displayed each time they "Lap" the main levels. |
Nice.
Will install when I get time. |
nice i'll be adding this later as well.
|
Hi, installed it, very nice ;)
My users say they look more brown then gold, one even said they look like excrement but.... cant please everyone Thanks for the kewl hack |
Quote:
|
thanks!
such an easy, yet fun hack ;) [high]* turbidblue clicks install :)[/high] |
Great!
|
Thats a good idea. Golden for more :)
|
...call me crazy but where is functions_reputation o_O
|
Quote:
|
O_o its not there..I don't have it.
|
Probably because you are not using vB 3.0.3
|
Meh, I'm not about to upgrade to vB 3.0.3, it is *WAY* too much work to do so.
Any chance of seeing vB3.0.0 compatible hack? |
Wow I suggested this in the other reputation mod and here it is!! Sweet!!
|
Great idea! :)
|
Great mod. Can you make it so that it would reset the pip and start over with 1 gold instead of adding it to the light green?
|
Quote:
I would imagine the same (or very similar) block of code is just located in a different file, so you just need to find and replace it. |
Quote:
Edit; Under ; $repval = $post['reputation']; Add ; $cutoff = ($repval > (($band_a_val * $band_a_count) + ($band_b_val * $band_b_count))) ; Change the Band a & b eval statements to ; if (!$cutoff) { eval('$post[\'reputationdisplay\'] .= "' . fetch_template('postbit_reputation') . '";'); } Be warned that this will make larger negative reputations look a bit odd as they don't have a third colour equivelent to 'gold'. |
Thank you for answering my request. I'm a bit slow so...could you please tell me what you mean by
Quote:
|
Quote:
$posneg = $repa; replace the next line with ; if (!$cutoff) { eval('$post[\'reputationdisplay\'] .= "' . fetch_template('postbit_reputation') . '";'); } and again, find ; $posneg = $repb; and replace the next line with ; if (!$cutoff) { eval('$post[\'reputationdisplay\'] .= "' . fetch_template('postbit_reputation') . '";'); } :D |
Thank you very much. Works great!
|
working as a charm! Thanks!
|
Quote:
|
Yes, I and my members much prefer this to the normal rep. The gold adds an extra sense of accomplishment :D (even though my site is a major repping site, and thus most people have gold pips, lol)
|
Quote:
|
Quote:
One question - this small mod to the code I have quoted, is that supposed to remove all the green pips to display the gold pips only - when the users rep gets that high? if so, it doesn't seem to be working for me. I tested it, got all the green one happening, then eventually got the gold to show up next to the green as was written in the original hack. However, I have modified the line under the $repa and $repb section to reflect the change outlinedi n the quoted text above. When the user now gets to the lvel of a gold pip it keeps going right next to the green. Have I done something wrong or does that modification not do what I thought it would? I was hoping it would completely remove all the green (say 5 dark green and 5 light green) with one gold pip, then again as the users rep build more gold pip's are added. Essentially making it look like the user has gone above that of "ordinary" user rep and now has a line of gold instead of a line of green and gold. Thank you |
I think you missed this bit, which is also required as part of that mod.
Quote:
|
Quote:
BRILLIANT it all works. This mod is great! Thank you so much for making it. |
Oh another thought. okay so say you wanted to go beyond gold to say plantinum.
The user starts out in dark green then after 5 pips goes to light green. After 10 green pip the user then goes to one gold pip. Moving along the user gets to 5 gold pips, what would be needed to add a different coloured pip after that (eg platinum)? So the user then has 5 gold and one platinum up to 5 gold and 5 platinum. Essentially after the user gets to that next level beyond green it becomes like the two green's but with gold and another colour. Is that possible/hard? Would that be a matter of adding a $repd? Also (sorry) does this hack over-ride the reputation settings in the admincp? I notice in the code to add into the functions_reputation.php code you have written that a value is 100 posts b value is 200 posts c value is 1000, where in the admincp you can set different levels for different post counts. |
Quote:
Quote:
|
Thank you kindly
|
Awesome hack.. And so simple.. Thanks
|
Having a problem, no matter how high a reputation is it only shows greens/light greens, no gold ones.
It shows 5 dark greens and 6 light greens, and thats all, no gold. I followed the easy instructions, but no worky :disappointed: |
Quote:
|
Quote:
Maaan, after installing 9 hacks including some major ones like uCS/v3arcade/vbacmps/vBaGallery etc etc one would guess i wouldnt screw this up :rolleyes: It's working fine now :p Thanks, nice hack. |
Quote:
|
I run 3.0.6 anf this is how my function.reputation lookes like; :surprised:
Soo, where should i put the replacement? // ###################### Start getreputationimage ####################### function fetch_reputation_image(&$post, &$perms) { global $vboptions, $stylevar, $vbphrase; if (!$vboptions['reputationenable']) { return true; } $reputation_value = $post['reputation']; if ($post['reputation'] == 0) { $reputationgif = 'balance'; $reputation_value = $post['reputation'] * -1; } else if ($post['reputation'] < 0) { $reputationgif = 'neg'; $reputationhighgif = 'highneg'; $reputation_value = $post['reputation'] * -1; } else { $reputationgif = 'pos'; $reputationhighgif = 'highpos'; } if ($reputation_value > 500) { // bright green bars take 200 pts not the normal 100 $reputation_value = ($reputation_value - ($reputation_value - 500)) + (($reputation_value - 500) / 2); } $reputationbars = intval($reputation_value / 100); // award 1 reputation bar for every 100 points if ($reputationbars > 10) { $reputationbars = 10; } if (!$post['showreputation'] AND $perms['genericpermissions'] & CANHIDEREP) { $posneg = 'off'; $post['level'] = $vbphrase['reputation_disabled']; eval('$post[\'reputationdisplay\'] = "' . fetch_template('postbit_reputation') . '";'); } else { if (!$post['reputationlevelid']) { $post['level'] = $vboptions['reputationundefined']; } for ($i = 0; $i <= $reputationbars; $i++) { if ($i >= 5) { $posneg = $reputationhighgif; } else { $posneg = $reputationgif; } eval('$post[\'reputationdisplay\'] .= "' . fetch_template('postbit_reputation') . '";'); } } return true; } |
You replace the code you just posted, just like the instructions say. :)
|
Find ;
// ###################### Start getreputationimage ####################### <current block of code> /*================================================= =====================*\ || ################################################## ################## This is not the same. ;) Ore is it? :blush: |
Yes it is ;)
It's you current block of code as you mentioned further up :D |
All times are GMT. The time now is 04:47 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|