Setting a maximum karma limit

Started by Rix_, October 30, 2010, 09:25:43 PM

Previous topic - Next topic

Kays

Hi, the changes should be similar for 2.0. If you cant see what they are, could you please attach both files to to a post.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

Rix_

Quote from: Kays on October 30, 2010, 10:32:50 PM
Hi, the changes should be similar for 2.0. If you cant see what they are, could you please attach both files to to a post.
I'm sorry but can you rephrase what you said

Kays

Please attach Display.template.php for the theme you are using and Sources/Karma.php to a post.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

Rix_

Alright, I've attached them to this post

Kays


If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

Rix_

Thanks for that Kays, and sorry for the late reply. Do you have any idea how to make karma that is given to a user dependent on how much he has?

For example:
If person A has 30 karma, he is able to give 3 karma to person B.
If person A has 40 karma, he is able to give 4 karma to person B.

Something like karma given is how much karma you have divided by 10. :)

Edit: Sorry, but what are the changes in the Display template?

Kays

Look at the Advanced Reputation mod. I think it allows you to set a sliding scale.

In Display.template.php I added a "total" parameter to this line


<a href="', $scripturl, '?action=modifykarma;sa=applaud;uid=', $message['member']['id'], ';total=', $message['member']['karma']['good'] - $message['member']['karma']['bad'], ';topic=', $context['current_topic'], '.' . $context['start'], ';m=', $message['id'], ';', $context['session_var'], '=', $context['session_id'], '">', $modSettings['karmaApplaudLabel'], '</a>

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

Advertisement: