Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: JohnWayne999 on December 20, 2011, 01:02:25 PM

Title: Auto Award
Post by: JohnWayne999 on December 20, 2011, 01:02:25 PM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=3239)

Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=3239)

Sixteen medals in total and are awarded automatically based on post count. Takes effect right away and also retrospectively. For example some members may have made many posts already prior to introduction of this mod. Not to worry. As soon as this mod is installed, all members will be awarded all medals they deserve.

TURN ON/OFF
This mod piggy backs on total number of posts and display of it. So make sure your forum has display for total number of posts enabled in order for this mod to work. By default this should be on anyway (already on), so you shouldn't need to worry too much.

DISPLAY OF MEDALS
Medals will be displayed under the poster's name in the posts, currently not displaying in profile page.

DIRECTORY WHERE MEDALS ARE STORED
Medals are stored in /Theme/default/images/medals
Feel free to add more or remove medals. I find 35 x 60 pixels a good size, but you are free to change that ratio as you please. HTML tables can be implemented easily to accommodate for varied sizes. This might be a feature of future version.

Please keep your medal filenames to medal1.png, medal2.png, medal3.png,.. in sequence because that's how they will be fetched in that order. I have included /Themes/default/medal1.png - medal16.png for you. You can change pictures or use different file extensions (eg. medal1.jpg, medal2.jpg...) but as long as the first part of filename sticks to sequential medal1, medal2 etc. Note also if you are using .gif then all files are .gif. If you want to use .png, then all files are .png, no mixing around please. For example medal1.gif, medal2.jpg, medal3.png will not work.

SETTING POST COUNTS FOR AWARDS
To specify how many posts deserves the next medal, simply go into /Themes/default/Display.template.php and change the numbers in $medalscore = array (10,20,30,40,50,100,150,200,300,400,600,800,1000,1300,1600,2000);
For example the way this array is set up by default now says there are 16 medals in total (16 elements in the array). To be awarded the first medal, you need to have posted a total of 10 posts. Not too hard. To be awarded the next medal, you need to post another 10 posts (absolute total of 20 posts). To get the final 16th medal, you need to post in total 2000 posts (can be new topics and/or replies, as long as they add up to 2000 from the time you registered to this forum). If you wish to add an additional medal to the reservoir, just lengthen the array, and don't forget to also place your medal#.png in /Theme/default/images/medals where # is sequential natural number. For example, obviously the next file in line will be medal17.png

Just a few quick clarifications:
Note 1: The numbers in the array are absolute number of posts not incremental posts.
Note 2: Person who receives current award, is also automatically awarded all awards below it if not already done so. For example if a member has been with this forum for some time, has posted 100 posts before this mod was installed. Now you install this mod, he is automatically awarded 6 medals all at once (for 10,20,30,40,50,100 posts check points).
Note 3: Obviously the numbers in the array need to be getting larger towards the right. For example it makes no sense setting up an array of 50,10,60,30,70,5,100,...
Note 4: If you see next to the medals an error message that says someone "has no influence", that means your array is longer than there are actually images for medals. To solve this problem is simple: either shorten your array, or add a few more images into /Theme/default/images/medals

USING IMAGES OTHER THAN PNG
Currently the engine searches for .png automatically. If you prefer .jpg or something else, just go into the file /Themes/default/Display.template.php and scroll down to this line
echo '<img src="', '/Themes/default/images/medals', '/medal', $mc++, '.png" />';

Change the .png in there to dot whatever extension you like. For example .jpg or .gif

BASE AWARD ON OTHER THAN POST COUNT
If you want the medals to be awarded based on something like how much money the user has, karma, or how long since he/she registered, it's pretty straightforward also. Just replace the variable $message['member']['posts'] with whatever variable you have in mind, as long as you know what those exact variables are.

FORWARD & BACKWARD COMPATIBILITY
This mod was developed and tested fine on SMF 2.0.1. NOTE: THIS MOD HAS NOT BEEN TESTED BY MYSELF ON ANY VERSION AFTER 1.1.15 or 2.0.1. The actual code is very small and straightforward. Please test at your own risk. If it works on a recent different version, I would love to know. For all upgrades, please firstly uninstall existing version of AutoAward then install the new version. Alternatively you can just look at the code for minor changes and DIY. Please always backup your data before trying any new mod. That will save you hours of debugging or re-installing. Just back up and copy back to last save point if need be, is the fastest and safest way.

BUGS
This mod will execute on any theme now, best against light themes. Earlier versions had poorly processed medals which showed unclean edges against dark backgrounds. You might still see examples of them in sample snapshots. The tools I used were InstantMask and iaza.com to make the medals' background transparent. These are free but rather basic tools. ARG very kindly polished up the medals nicely. So now most themes (even dark themes) should do fine.  You may still find occasional gray themes problematic.

FUTURE CONSIDERATIONS
1. Autoscale, so admin can just throw medals of any size into the directory, and medals will automatically be scaled to equal size on display.
2. Might add descriptions to individual medals.
3. Have the medals show up in personal profile page.
4. Would be interesting to make some sort of game out of the rankings. For example allow people to trade medals or sell them for non-real money on the forum.

OTHER RECOMMENDATIONS
If you enjoy this mod, then maybe you would be interested in SMF Shop by vbgamer45 and Member Awards by Spuds also. SMF Shop lets users buy things using credits earned from posts. You can reserve special edition medals for people to purchase or swap around. Member Awards is straight forward. Moderators can award individual members things (eg. trophies or limited edition medals) which will stick to their profile and album indefinitely.

UPDATE LOG
Amendment 1: Removed excess variable $medalmax
Amendment 2: Added alt="" for XHTML 
Amendment 3: Internalised if (!isset($context['disabled_fields']['posts']))
Amendment 4: Fixed <install for="2.0 - 2.0.99">
Amendment 5: Corrected HTML bug - excess comma in front of alt="" (thanks to beta tester Bugo)
Amendment 6: Corrected vertical alignment.
Amendment 7: Special thanks for ARG for polishing up medal edges and backgrounds which now work well against most dark themes


That's about it in a nutshell. Thanks for using Auto Award! All comments, suggestions including feature requests are welcome at http://www.simplemachines.org/community/index.php?topic=462876.msg3232239#msg3232239 . Check out some of the posts there as people have posted ways of fine tuning and adding features to this mod DIY, for example adding comments to icons, or setting number of icons per row.

Lastly but importantly, please remember to backup first before trying this mod.
Title: Re: Auto Award
Post by: Bugo on December 21, 2011, 07:14:36 AM
HTML code is not valid. Look at:

, alt="" /></li>';

Please, remove a comma before alt.
Title: Re: Auto Award
Post by: JohnWayne999 on December 21, 2011, 09:12:31 AM
Ah well spotted. What was I thinking. Thanks. Corrected and uploaded as amendment5 now.

If there are any more issues, would appreciate people reporting them and I'll try fixing asap.

(If it works for you, I'd love to hear about it too.)
Title: Re: Auto Award
Post by: chinaren on December 31, 2011, 03:26:25 AM

OMFG!!!  I could kiss you for this mod.  :-*  I've been looking for something like it for ever


Many blessing rain down upon you.  I've installed it and it works perfectly, though I'm going to adjust the medals an d counts a bit, as it takes up rather a lot of room as is. 


Now, I just need one for years of membership (that can go alongside this one).   :laugh:
Again, thank you for this!!
Title: Re: Auto Award
Post by: keyboard on January 03, 2012, 10:25:52 AM
Thank you for this awesome mod.  It is a nice addition for any Board.  :) :)

My site has thousands of posts and I would like to increase the totals from:
$medalscore = array (10,20,30,40,50,100,150,200,300,400,600,800,1000,1300,1600,2000);

To:
$medalscore = array (10,20,30,40,50,100,250,500,750,1000,1500,2500,5000,7500,10000,20000);

So All I need to do, is to go to   /Themes/default/Display.template.php   and change the numbers?

Thanks
Ron
Title: Re: Auto Award
Post by: thecoo1est on January 04, 2012, 06:35:16 PM
aww yessss! Been waiting so long, wont you tell me if Im coming on to strong, this heart of mine has been hurt before, this time I want to be sure.

Been waiting for a mod like this to come into my life, it looks so simple to and yet everything it needs to be, thanks!
Title: Re: Auto Award
Post by: JohnWayne999 on January 04, 2012, 09:53:12 PM
Quote from: keyboard on January 03, 2012, 10:25:52 AM
My site has thousands of posts and I would like to increase the totals from:
$medalscore = array (10,20,30,40,50,100,150,200,300,400,600,800,1000,1300,1600,2000);

To:
$medalscore = array (10,20,30,40,50,100,250,500,750,1000,1500,2500,5000,7500,10000,20000);

So All I need to do, is to go to   /Themes/default/Display.template.php   and change the numbers?

Keyboard, yes.

Chinaren, years of membership sounds nice. I probably won't have time to do it in the near future. Do you know what the variable for that is (years of membership)?

Thanks guys for the feedback. I share your pain and joy.

One pending problem for this mod is the medals are not very well polished. They work fine with light themes. If you try dark theme the edges get ugly. Someone just needs to edit those medal edges pixel by pixel to smooth them out. I personally won't have the time to do this until end of 2012. If anyone is able to help out that'll be excellent (bear in mind the background of medal needs to remain transparent). Otherwise I might do it myself in 12 months time :D

Happy new year and may all your resolutions come true.
Title: Re: Auto Award
Post by: thecoo1est on January 04, 2012, 11:15:00 PM
****** this is perfect I changed my icons already with png's, but I would like to name the icon if possible, so when a user hovers over with mouse a text popup will say what the award name is, would that be possible, not that its a big deal, Im super happy as is and thanks again, the mod is SWEEEET!
Title: Re: Auto Award
Post by: JohnWayne999 on January 05, 2012, 12:33:22 AM
Quote from: thecoo1est on January 04, 2012, 11:15:00 PM
****** this is perfect I changed my icons already with png's, but I would like to name the icon if possible, so when a user hovers over with mouse a text popup will say what the award name is, would that be possible, not that its a big deal, Im super happy as is and thanks again, the mod is SWEEEET!

Hi Cool1est

That's a good suggestion and not too hard to implement.

Many ways to do it. I'll outline one approach, see if you or anyone wants to DIY. Otherwise I can throw it in the upgrade (may be months from now).

Look for alt"" part of the code.
Insert whatever text you like in there and it will show up when the user hovers mouse next to medal.

What you want though is each medal to show up a different description.
So you will need to set up a separate array that corresponds each icon with its own description. Once that correlation is set up, you can just retrieve that description accordingly by having the the alt= point to appropriate part of the array.

So something like this

Add after this code: foreach($medalscore as $ms){
this line:    foreach($medaldesc as $md);

Add after this code: $medalscore = array (10,20,30,40,50,100,150,200,300,400,600,800,1000,1300,1600,2000);
this line:       $medaldesc = array ('Newbie', 'Medal2 Desc', 'Medal3 Desc', .., .., 'God');
      
Replace this line: echo '<img src="', $imagesURL, '/medal', $mc++, '.gif" alt="" />';
With this line: echo '<img src="', $imagesURL, '/medal', $mc++, '.gif" alt="$md" />';

So overall it should look something like this:
// Start of AutoAward
if (!isset($context['disabled_fields']['posts'])){
$imagesURL = $settings['default_images_url'] . '/medals';
$medalscore = array (10,20,30,40,50,100,150,200,300,400,600,800,1000,1300,1600,2000);
$medaldesc = array ('Newbie', 'Medal2 Desc', 'Medal3 Desc', .., .., 'God');

$mc=1;
foreach($medalscore as $ms){
foreach($medaldesc as $md);

if($message['member']['posts']>=$ms)
echo '<img src="', $imagesURL, '/medal', $mc++, '.gif" alt="$md" />';
} // end of ms foreach
} //end isset disabled fields if
// End of AutoAward.


I haven't tested it yet. See if that works for you. You might get a bug from alt="$md". The foreach might give you grief. Or maybe not and you get lucky, everything works first go :D

Addendum: Actually on second look, this code won't work. You best use two dimensional array which I can't remember how to do :D The problem with coding is it's like an addiction. You code some, want to fix it more, fix more, want to code more. Before you know it a weekend has gone.
Title: Re: Auto Award
Post by: keyboard on January 09, 2012, 08:44:35 PM
Hi

I am not a seasoned user of SMF and need to clarify something with you.....I have over 70 users.  I have added them all by registering them myself,  I did not assign a group to them,  so right now, they all have the  "no primary membergroup "..There have been a lot of posts and a lot of medals earned,  and now,  I would like to move all of them to a new Member Group called "Regular Members ".

Now after setting the permissions for a group called  "Regular Members", and if I assign all the Users from  "no primary member group " to this new Group,  will they lose all their hard earned medals ?
Title: Re: Auto Award
Post by: chinaren on January 09, 2012, 08:50:17 PM
Usually the 'regular member' group is 'no primary member group' by default.  Usually.


If that's not clear:  Users with 'no primary membergroup' are all members of the 'Regular Members' group.  If you change their primary member group to something else, they're (if I understand this right) still members of 'regular members' but the new primary group settings take precedence.
That's probably more confusing.  I've muddled myself now.  ???
Title: Re: Auto Award
Post by: JohnWayne999 on January 10, 2012, 11:52:00 AM
Quote from: keyboard on January 09, 2012, 08:44:35 PM
I have over 70 users.  I have added them all by registering them myself,  I did not assign a group to them,  so right now, they all have the  "no primary membergroup "..There have been a lot of posts and a lot of medals earned,  and now,  I would like to move all of them to a new Member Group called "Regular Members ".

Now after setting the permissions for a group called  "Regular Members", and if I assign all the Users from  "no primary member group " to this new Group,  will they lose all their hard earned medals ?

Hello keyboard. Interesting question. I haven't used membergroups myself so can't tell you definitely.

The way this mod works is it basically takes your total post count, and displays appropriate number of medals accordingly.
Whenever you see post count (displayed as "Posts:" under your avatar), that's the number the mod takes.

I think changing groups (from "no primary group" to "regular") does not affect your post count. For example if I started off as "no primary group" user and I posted 100 posts. Then I was upgraded to regular, and I post 50 more posts. Now I have a total of 150 posts in my "Posts: 150" display. I will get the right number of medals accordingly (ie. medals for 150 posts, not just 50 posts). Changing group/permission should not affect medal system as long as post count is not disturbed.
The assumption is: post count is not disturbed when you change group (which I think is the case).
If the post count goes back to 0 when you change group  (which I don't think is the case), then medal will go back to 0 medals.

I don't think you have anything to worry about. To be certain, why don't you test it? Just use a dummy user, make some posts to earn a few medals, then upgrade him to another group/permission and see if the medals are still there. Most likely they are still there.

Hope this answers your question. Let me know if there is abnormal behaviour. Thanks.

(By the way the algorithm used is actually not very efficient, but I haven't got time to fix it. If anyone has suggestions I am happy to consider it, thanks)
Title: Re: Auto Award
Post by: keyboard on January 10, 2012, 07:29:50 PM
Thanks JohnWayne999

I can confirm that I had no problems with assigning User Member Groups.. :) :) :)   

This is a nice and functional Mod  :D
Title: Re: Auto Award
Post by: David Blyth on January 22, 2012, 06:05:40 PM
Downloaded and install this Mod and it works perfectly well and the medals are stunning, I successfully changed the number of posts required to win each award however I am trying to base the medals awarded on the karma of a member so I changed the $message['member']['posts'] to $message['member']['karma'] but it still uses the number of posts, can you give me any advice on this matter.
Title: Re: Auto Award
Post by: JohnWayne999 on January 24, 2012, 07:14:47 AM
Quote from: David Blyth on January 22, 2012, 06:05:40 PM
Downloaded and install this Mod and it works perfectly well and the medals are stunning, I successfully changed the number of posts required to win each award however I am trying to base the medals awarded on the karma of a member so I changed the $message['member']['posts'] to $message['member']['karma'] but it still uses the number of posts, can you give me any advice on this matter.

Hi there.

I haven't tested this yet, but try

using this

$message['member']['karma']['good'] - $message['member']['karma']['bad']

instead of your

$message['member']['karma']


(Just in case I'm not clear. What I mean is, you said you altered my code from $message['member']['posts'] to $message['member']['karma']. I am suggesting you alter my code from its original $message['member']['posts'] to $message['member']['karma']['good'] - $message['member']['karma']['bad']. Don't touch $message['member']['posts'] and $message['member']['karma'] that's outside of my code. To tell where my code starts and end, you should be able to find comments that say something like "// AutoAward starts here" and "// AutoAward ends here". Anything in between is my code. Anything outside is SMF's own stuff)


Also, a less important point, consider changing

this

if (!isset($context['disabled_fields']['posts'])){

to this

if ($modSettings['karmaMode'] == '1'){


Good luck. Let us know how you go.
Title: Re: Auto Award
Post by: keyboard on February 02, 2012, 10:47:13 AM
Great Mod !!!!

I am moving things around and deleting messages , the total count gets less and less, to the point where some Users are losing medals ...Yikes !!!!!

Is there anyway where I can manual add to their total so they do not lose their hard earned medals ?


Thanks again for this awesome mod
Ron
Title: Re: Auto Award
Post by: JohnWayne999 on February 04, 2012, 12:25:24 AM
Quote from: keyboard on February 02, 2012, 10:47:13 AM
I am moving things around and deleting messages , the total count gets less and less, to the point where some Users are losing medals ...Yikes !!!!!

Is there anyway where I can manual add to their total so they do not lose their hard earned medals ?

Hi there keyboard. Thanks for the feedback. This mod feeds on total post count. So if total post count comes down far enough, then yes people will start to lose medals.

I didn't know erasing posts can lead to people losing their post count. If this is the case, then it's an SMF issue which needs to be solved from their end.

You should be able to manually edit the SQL database and turn up individual user's post count. Then their medals will also return, once post count is back up. (Make sure to back up your database first before making changes manually).

Good luck!
Title: Re: Auto Award
Post by: pixeleyes on April 07, 2012, 12:58:25 AM
Actually I want to keep one award.

I want that when user reach next level post

so previous award automatically be removed or converted to next award.

e.g.
100 posts : 200 posts
on 200posts previous award of 100posts should not be shown.
Title: Re: Auto Award
Post by: JohnWayne999 on April 09, 2012, 05:10:52 AM
Quote from: pixeleyes on April 07, 2012, 12:58:25 AM
Actually I want to keep one award.

I want that when user reach next level post

so previous award automatically be removed or converted to next award.

e.g.
100 posts : 200 posts
on 200posts previous award of 100posts should not be shown.

Hi.

A good request. In summary you want to display only the single highest medal at all times.

However I am quite busy at the moment. If you don't mind experimenting, please edit this file /Themes/default/Display.template.php, try replacing this bit of the original code


$mc=1;
foreach($medalscore as $ms){
if($message['member']['posts']>=$ms)
echo '<img src="', $imagesURL, '/medal', $mc++, '.png" alt="" />';
} // end of ms foreach



with this new section of code

$mc=1; $printedonce=0;
foreach($medalscore as $ms){
if($message['member']['posts']>=$ms) $mc++;

if($message['member']['posts']<$ms && $printedonce==0){
if($mc>=1) echo '<img src="', $imagesURL, '/medal', $mc, '.png" alt="" />';
$printedonce=1; $mc++;
}
                                } // end of ms foreach


Please note this is something I made up spontaneously and have not tested. Normally my code needs about 5 debugs before it's good to release. So this one may or may not work.

Good luck.
Title: Re: Auto Award
Post by: pixeleyes on April 09, 2012, 02:23:08 PM
Thank you so much JohnWayne999
ThumbsUP This is exactly what I wanted.

I would like to request one more feature but whenever you have free time.  :)

1) Want to add text before Award e.g. "Achievement"
2) Under Award in second line I want that "left posts to next achievement"
e.g.  200 Posts to Next Achievement
Title: Re: Auto Award
Post by: JohnWayne999 on April 10, 2012, 06:39:05 AM
Quote from: pixeleyes on April 09, 2012, 02:23:08 PM
1) Want to add text before Award e.g. "Achievement"
2) Under Award in second line I want that "left posts to next achievement"
e.g.  200 Posts to Next Achievement

You make good requests.

Continuing from the new code supplied to you on 9/4/2012. Try replacing this:

if($mc>=1) echo '<img src="', $imagesURL, '/medal', $mc, '.png" alt="" />';

with this


if($mc>=1){
echo '<br>Achievement<br>';
echo '<img src="', $imagesURL, '/medal', $mc, '.png" alt="" />';
echo '<br>',$ms-$message['member']['posts'],' posts to Next Achievement<br>';
} // endif mc greater or equal to one


Hope that works. My code usually requires serious debugging. So don't be surprised if it doesn't work first go. Good luck.

Just out of curiosity, for people who do not have any medal yet, how would you like the display? Just "Achievement:" then nothing (no medal showing), then "200 posts to Next Achievement"? That kind of looks weird. Currently you need to have at least 1 medal, in order to see the "Achievement:", medal, and "200 posts to Next Achievement". If you'd like something to be displayed for people without any medal ie. total newbies, it should be quite simple also. For example, don't show "Achievement:", and no medal, but just show how many posts to next achievement (to 1st medal). Let me know if you got problems.
Title: Re: Auto Award
Post by: Biology Forums on April 10, 2012, 05:00:27 PM
Could they be posted in one's profile?
Title: Re: Auto Award
Post by: pixeleyes on April 11, 2012, 05:20:57 AM
Quote from: JohnWayne999 on April 10, 2012, 06:39:05 AM
Just out of curiosity, for people who do not have any medal yet, how would you like the display? Just "Achievement:" then nothing (no medal showing), then "200 posts to Next Achievement"? That kind of looks weird. Currently you need to have at least 1 medal, in order to see the "Achievement:", medal, and "200 posts to Next Achievement". If you'd like something to be displayed for people without any medal ie. total newbies, it should be quite simple also. For example, don't show "Achievement:", and no medal, but just show how many posts to next achievement (to 1st medal). Let me know if you got problems.


So far you codes are working perfet for me :)

Regarding newbie you are absoultely right. So I just made little change in your below code.

First option:
Find:
$mc=1; $printedonce=0;

Repalce with:
$mc=0; $printedonce=0;

Now all text including award will hide from newbie until they reach certain level.

Second option:
Without changing anything just upload an empty award for newbie (only outline) I think that will also look nice.


Before I request for text under award e.g. 200 posts to next achievment.
Now I want more update  :P
I would like that Text (under award) should also change with award.

e.g.
200 posts to Star Award
500 posts to Uniqie Member Award etc.
Title: Re: Auto Award
Post by: JohnWayne999 on April 11, 2012, 07:08:37 AM
Good on you pixeleyes. I'm glad you found a easy way to solve the problem.
With your latest request, try using another array or a 2 dimensional array. It's not hard, just need to know how to declare and access those elements in the array(s).

Quote from: Liam_michael on April 10, 2012, 05:00:27 PM
Could they be posted in one's profile?

Good suggestion. I would be happy to implement that next time I am free. But to make things easier for me, someone needs to tell me which file to edit. What's the file that handles display of people's profile please? (exact location of the file and file name please).

Have fun guys.

By the way, if anyone has the expertise, see if you can polish up the medals so they display well on grayish and black background. You'll see currently some of the medals still don't have perfect edges on darker themes. I think it's just a matter of using PhotoShop to make individual pixels on the edges transparent, or something like that. That's a be a great help for me and thanks.


Title: Re: Auto Award
Post by: pixeleyes on April 11, 2012, 07:14:18 AM
Quote from: JohnWayne999 on April 11, 2012, 07:08:37 AM
Good on you pixeleyes. I'm glad you found a easy way to solve the problem.
With your latest request, try using another array or a 2 dimensional array. It's not hard, just need to know how to declare and access those elements in the array(s).

Thanks JohnWayne
Problem is I know nothing about PHP, so don't know the coding.
Title: Re: Auto Award
Post by: pixeleyes on April 11, 2012, 09:13:53 AM
Quote from: JohnWayne999 on April 11, 2012, 07:08:37 AM
Good suggestion. I would be happy to implement that next time I am free. But to make things easier for me, someone needs to tell me which file to edit. What's the file that handles display of people's profile please? (exact location of the file and file name please).

themes/default/profile.template.php

After that code
<dd>', $context['member']['location'], '</dd>';
Title: Re: Auto Award
Post by: pixeleyes on April 11, 2012, 01:31:43 PM
Medal icons.

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.imagedost.com%2Fimages%2Fhl6g8vj4c6vl147zmye.gif&hash=baf1704fa13c8c52e3c690f2cdf28aa27e7434c4)
Title: Re: Auto Award
Post by: Biology Forums on April 17, 2012, 11:04:58 PM
Neat mod, finally got around to it 8)

Take a look at my rendition...
Title: Re: Auto Award
Post by: JohnWayne999 on April 21, 2012, 09:24:52 AM
Quote from: Liam_michael on April 17, 2012, 11:04:58 PM
Neat mod, finally got around to it 8)

Take a look at my rendition...

Good stuff.

Wanna share the code? I'll include it in the next update and make credit towards you.
Title: Re: Auto Award
Post by: Biology Forums on April 21, 2012, 12:09:21 PM
Quote from: JohnWayne999 on April 21, 2012, 09:24:52 AM
Quote from: Liam_michael on April 17, 2012, 11:04:58 PM
Neat mod, finally got around to it 8)

Take a look at my rendition...

Good stuff.

Wanna share the code? I'll include it in the next update and make credit towards you.

Yes, I will, but it's for only individuals with the ultimate profile mod installed... is that okay?
Title: Re: Auto Award
Post by: JohnWayne999 on April 21, 2012, 10:25:21 PM
Quote from: Liam_michael on April 21, 2012, 12:09:21 PM
Quote from: JohnWayne999 on April 21, 2012, 09:24:52 AM
Quote from: Liam_michael on April 17, 2012, 11:04:58 PM
Neat mod, finally got around to it 8)

Take a look at my rendition...

Good stuff.

Wanna share the code? I'll include it in the next update and make credit towards you.

Yes, I will, but it's for only individuals with the ultimate profile mod installed... is that okay?

Yea that's fine. Thanks for your generosity.
Just quote/paste your part of code (and specify exact location and name of file to edit, and where to insert your code in that file) in this thread if you are okay with it. That way other people can see it early (before I eventually get to add it to next release).
Thanks!

Quote from: pixeleyes on April 11, 2012, 09:13:53 AM
Quote from: JohnWayne999 on April 11, 2012, 07:08:37 AM
Good suggestion. I would be happy to implement that next time I am free. But to make things easier for me, someone needs to tell me which file to edit. What's the file that handles display of people's profile please? (exact location of the file and file name please).

themes/default/profile.template.php

After that code
<dd>', $context['member']['location'], '</dd>';

Thanks pixeleyes for the filename & path.

Your medals look cute. If you want to use them, just cut them up (I think the ideal ratio was 35 x 50 pixels or thereabout) and throw into the medals directory.
Title: Re: Auto Award
Post by: dimspace on May 18, 2012, 09:16:33 PM
If anyone has any use for them, heres a set of 39 very tiny images that can be used for a post count bar with above mod.
Basically creates a colour bar running from pink to blue as in the image..
Title: Re: Auto Award
Post by: dimspace on May 18, 2012, 09:29:30 PM
Oh and if anybody uses the Thank O Matic  Mod the code for that is as follows

// Start of AutoAward
if (!isset($context['disabled_fields']['posts'])){
$imagesURL = $settings['default_images_url'] . '/medals';
$medalscore = array (30,50,75,100,150,200,250,300,400,500,600,700,800,900,1000,1100);

$mc=1;
foreach($medalscore as $ms){
if($message['member']['thank_you_post']['became']>=$ms)
echo '<img src="', $imagesURL, '/medal', $mc++, '.png" alt="" />';
} // end of ms foreach
} //end isset disabled fields if
// End of AutoAward.


obviously with your own limits. I use the medals system (which is great btw) in conjuntion with the thank you mod so it awards medals based on the number of thanks a poster has recieved.

link to mod http://custom.simplemachines.org/mods/index.php?mod=710
Title: Re: Auto Award
Post by: HecticZA on July 01, 2012, 09:21:24 AM
Hi thx for the mod, but need some help please?

When I installed the mod it picked up the posts and awarded the medals as per your initial mod.
I changed the post counts, but it does not reduce the medals that was issued.
My posts at the time of the mod installation was just under 1000 and I was issued 11 medals, but with my changes to medalscore it should show 9, but it still shows 11.
Can you help me pls?
Title: Re: Auto Award
Post by: themegenius on July 21, 2012, 05:57:23 AM
Quote from: JohnWayne999 on April 10, 2012, 06:39:05 AM
Quote from: pixeleyes on April 09, 2012, 02:23:08 PM
1) Want to add text before Award e.g. "Achievement"
2) Under Award in second line I want that "left posts to next achievement"
e.g.  200 Posts to Next Achievement

You make good requests.

Continuing from the new code supplied to you on 9/4/2012. Try replacing this:

if($mc>=1) echo '<img src="', $imagesURL, '/medal', $mc, '.png" alt="" />';

with this


if($mc>=1){
echo '<br>Achievement<br>';
echo '<img src="', $imagesURL, '/medal', $mc, '.png" alt="" />';
echo '<br>',$ms-$message['member']['posts'],' posts to Next Achievement<br>';
} // endif mc greater or equal to one


Hope that works. My code usually requires serious debugging. So don't be surprised if it doesn't work first go. Good luck.

Just out of curiosity, for people who do not have any medal yet, how would you like the display? Just "Achievement:" then nothing (no medal showing), then "200 posts to Next Achievement"? That kind of looks weird. Currently you need to have at least 1 medal, in order to see the "Achievement:", medal, and "200 posts to Next Achievement". If you'd like something to be displayed for people without any medal ie. total newbies, it should be quite simple also. For example, don't show "Achievement:", and no medal, but just show how many posts to next achievement (to 1st medal). Let me know if you got problems.

hi i cant find this code

if($mc>=1) echo '<img src="', $imagesURL, '/medal', $mc, '.png" alt="" />'; any were in my display template as i would like to have the achievement text show up.
Title: Re: Auto Award
Post by: TrickyRicky on July 28, 2012, 10:19:28 AM
Fantastic mod thanks ever so much
Title: Re: Auto Award
Post by: T3CHN0 on September 21, 2012, 02:57:41 AM
Nice mod, Cheers

I cropped and downsized the images by 50% so they don't take up allot of space
anyone wanting them can download them, just replace the ones you have with these ones
Title: Re: Auto Award
Post by: humbleworld on October 29, 2012, 12:28:43 AM
where can i access the admin area for this MOD?

thank you so so much for creating this MOD. thank you.
Title: Re: Auto Award
Post by: humbleworld on October 29, 2012, 01:32:26 AM
to the MOD creator, i'd like to donate you a very small amount as my token of appreciation. what is your paypal address? if in win the lotto, il donate you more. i bet on the lotto everyday.
Title: Re: Auto Award
Post by: JohnWayne999 on October 30, 2012, 02:10:26 AM
Quote from: humbleworld on October 29, 2012, 12:28:43 AM
where can i access the admin area for this MOD?

thank you so so much for creating this MOD. thank you.

Hey Humbleworld thanks for the offer. That's very nice of you.

This is a free MOD for anyone to use. Many people have also contributed along this thread to its improvement.

Just sit back and enjoy the code, there's no need to donate to me. Alternatively please select any charity or beggar on the street of your choice and donate any amount to them will make me equally happy.

Thanks again.
Title: Re: Auto Award
Post by: humbleworld on October 30, 2012, 07:37:27 AM
That's very generous of you, JohnWayne. In real practice, I've been donating to charitable organizations in many small ways I can.

Anyhow, our forum of more than half a million posts has just embraced your MOD. All our members just love it.
Title: Re: Auto Award
Post by: humbleworld on November 14, 2012, 09:20:10 PM
Hello JohnWayne,

I have a couple of questions: How can I modify the number of medals? One member has six medals already. In the first line, there are 4 medals and the other 2 medals are in the next line. I want to make 3 medals only per line so that the medals won't overflow beyond the avatar size.

Another question is: how can I reduce the sizes of the medals? Here's a sample post (http://tubagbohol.mikeligalig.com/index.php?topic=56799.0) with six medals of a member.
Title: Re: Auto Award
Post by: JohnWayne999 on November 30, 2012, 10:29:26 PM
Quote from: humbleworld on November 14, 2012, 09:20:10 PM
How can I modify the number of medals? One member has six medals already. In the first line, there are 4 medals and the other 2 medals are in the next line. I want to make 3 medals only per line so that the medals won't overflow beyond the avatar size.

Another question is: how can I reduce the sizes of the medals? Here's a sample post (http://tubagbohol.mikeligalig.com/index.php?topic=56799.0) with six medals of a member.

Hello Humbleworld

For question 1 what you want is modulus of 3. Whenever $mc is fully divisible by 3, send a new line. See if this does the trick. I actually don't have simplemachine anymore, so just doing this blind :D Hope it works for you.

Try replacing the original code of:

$mc=1;
foreach($medalscore as $ms){
if($message['member']['posts']>=$ms)
echo '<img src="', $imagesURL, '/medal', $mc++, '.png" alt="" />';
} // end of ms foreach


with this new section of code


$mc=1;
foreach($medalscore as $ms){
if($message['member']['posts']>=$ms) {

echo '<img src="', $imagesURL, '/medal', $mc++, '.png" alt="" />';

if($mc % 3 == 0) echo '<br>';  // Send a new line everytime count reaches 3 ie. remainder of 0 when divided by 3

} // end of if_message_member_posts_greater_or_equal_to_ms

} // end of ms foreach


If it doesn't work, try changing the 3 to a 2 and see if that helps. I always seem to miscount things by 1.

About question 2, reducing size of icons. Try googling image resizer. There should be some free software or websites out there that shrink things for you. Another more flexible way is to set up HTML tables and scale things in to the rows and columns. I might give that a go when I get really bored.

Good luck.
Title: Re: Auto Award
Post by: His_Shadow on February 01, 2013, 01:04:16 AM
Something for future consideration:

Option for making the awarding of the medals manual instead of based on a db value.
Title: Auto Award jsut won't go away
Post by: joeyjojoshabadoo on February 20, 2013, 09:56:52 PM
Hi guys, im having some big problems with this mod. It is causing a huge amount of server errors.
Despite having uninstalled it the mod is still listed in 'installed packages'. when i try to uninstall it there i get ' unable to find package file'. ( this is because i already uninstalled it)

I thought the problem might be residual mentions of 'medals' and 'medal score' that i can find in the default theme's display.template.php. The error logs were leading back to the default theme aswell. So i went into the default display template and the backup and removed any mention of autoaward ( there was still some there)

Yet, it's still kicking out errors every time someone posts, like this

File does not exist: ********************************** /Themes/default/images/medals referrer : ( URL of a new post)

Can you help me out here guys?
Title: Re: Auto Award
Post by: mexinspain on May 11, 2013, 06:16:52 PM
It's been a long time since I returned to SMF  ;)   can someone please let me know where to set this

QuoteSo make sure your forum has display for total number of posts enabled inorder for this mod to work.

Thanks..
Title: Re: Auto Award
Post by: CheeseHead05 on May 16, 2013, 12:52:15 AM
Hi,

As I am new to SMF, I would like to know how can I make the medals visible, I installed the mod but what's next? where are the medals located?

Thanks in advance!
Title: Re: Auto Award
Post by: TheListener on May 16, 2013, 12:59:53 AM
Quote from: CheeseHead05 on May 16, 2013, 12:52:15 AM
Hi,

As I am new to SMF, I would like to know how can I make the medals visible, I installed the mod but what's next? where are the medals located?

Thanks in advance!

As per the other mods post.

If images are shown in the default theme then they will need to be copied over to the theme you are using.
Title: Re: Auto Award
Post by: CheeseHead05 on May 16, 2013, 10:02:53 AM
Old Fossil,

But the thing is even in default I cant get them to show. What do u mean be copied? So, would I go to my themes/images/post and what's next? copy the files over to my theme?

P.S.

This is my very first time with web developing, im enjoying the learning process but it can become frustrating at times when things dont work or appear as they should.

Thanks!
Title: Re: Auto Award
Post by: CheeseHead05 on May 20, 2013, 12:21:09 AM
I have an issue on hand,

I recently installed Auto Award using the 2.0.4 forum version but when I go to install GP/BP I get "The package you are trying to download or install is either corrupt or not compatible with this version of SMF.". So I delete the entire forum and re-install. I install GP/BP first using the forum version 2.0.4 and it goes thru so then I attempted to install Auto Award and I get "The package you are trying to download or install is either corrupt or not compatible with this version of SMF." Where is the problem with the two because obviously they are not compatible. And Im using SMF 2.0.4.
Title: Re: Auto Award
Post by: TheListener on May 20, 2013, 12:25:13 AM
Read the mod emulate link in my signature.

;)
Title: Re: Auto Award
Post by: CheeseHead05 on May 20, 2013, 12:38:55 AM
Matter of fact, ever since I installed that GP/BP, none of my other mods are installing. But when I uninstall that mod, then everything installs back again..
Title: Re: Auto Award
Post by: CheeseHead05 on May 20, 2013, 12:43:49 AM
Old Fossil,

Ok... :)
Title: Re: Auto Award
Post by: CheeseHead05 on May 20, 2013, 01:05:32 AM
Old Fossil,

Ive read the link, but what do I do when I have a custom theme? Do I go into the index.template.php?
Title: Re: Auto Award
Post by: TheListener on May 20, 2013, 01:09:38 AM
With all mods if the mod uses a file which is available on the default theme the the theme you are using will also require the same edit.
Title: Re: Auto Award
Post by: CheeseHead05 on May 20, 2013, 01:36:52 AM
Old Fossil,

Is there a shortcut so that I dont have to find the lines to replace being that there are 1000 LINES! I mean too many blinks could make me miss the line. There has to be a browser add on. There's is no way that I can go thru all those lines and find it!
Title: Re: Auto Award
Post by: CheeseHead05 on May 20, 2013, 01:38:58 AM
And that is in reference to the FTP directory.
Title: Re: Auto Award
Post by: TheListener on May 20, 2013, 01:40:30 AM
Use Notepad##

Will make life a lot easier  ;)
Title: Re: Auto Award
Post by: CheeseHead05 on May 22, 2013, 01:34:56 PM
Hi,

I recently reinstall my custom theme, meaning that I removed the AutoAward medals from the default/image folder and moved them into my new custom theme/images/posts folder but when I go to see them in the actual forum, I dont see them. Are there permissions in the Admin panel in reference to AutoAward? What am I doing wrong?
Title: Re: Auto Award
Post by: CheeseHead05 on May 31, 2013, 11:24:28 PM
I recently switched my theme and my medals are not showing up. The theme's folder shows up in my FTP and I relocated the medals to the image folder as well as post folder under the theme but its not showing up in the post..

Please Help! :-\
Title: Re: Auto Award
Post by: Mortuum on June 03, 2013, 06:47:56 AM
Hello, i would like to auto award according the member groupe (ex : Author, Bloggeur etc).
I already try some modification with [membrergroups][id] and change numbrer of post by id number. But it didnt succeed, i actually didnt know what to change for what.
So do you know who to do it please ?
Title: Re: Auto Award
Post by: JohnWayne999 on July 28, 2013, 03:28:11 AM
Hi guys,

Sorry I am busy with other things at work. Won't have time to answer every post.

Just wish to clarify one thing though: are most people running SMF 2.0.4 finding this mod (Autoaward) ok? I see some posts saying the mod scr3wed up their 2.0.4 system. Just wish to verify this is a recurrent issue on other people also running 2.0.4 and not just on one or two individuals. Thanks. For now I have taken 2.0.4 off the compatible list.

Regarding suggestion for manually awarding medals, I think there already is a mod out there doing this. You can award trophies or something like that.

Motuum, I think you are on the right track. Just need to find the variable responsible, make sure its value is communicated across eg. make sure it's not some local variable or if so, figure out a way to transport it across. See if that helps. Good luck.
Title: Re: Auto Award
Post by: JohnWayne999 on October 05, 2013, 05:35:36 AM
Hi guys,

Here's a response I gave to someone explaining how to install the mod manually. See if it helps anyone else also:

I haven't used SMF for a couple of years now. Assuming the basic underlying structure hasn't changed, give this approach a go. You install it manually .

There are 3 steps: step 0, step 1, and step 2:

Step 0:


Backup everything .


Step 1:


Find a directory (folder) called

/Themes/default

Inside that directory there should be a file called

Display.template.php

Open that file.

Look for a line that looks like:

<![CDATA[// Is karma display enabled?]]>

Once you found that line (the line shown above), add after it the following:

<![CDATA[


// Start of AutoAward
if (!isset($context['disabled_fields']['posts'])){
$imagesURL = $settings['default_images_url'] . '/medals';
$medalscore = array (10,20,30,40,50,100,150,200,300,400,600,800,1000,1300,1600,2000);

$mc=1;
foreach($medalscore as $ms){
if($message['member']['posts']>=$ms)
echo '<img src="', $imagesURL, '/medal', $mc++, '.png" alt="" />';
} // end of ms foreach
} //end isset disabled fields if
// End of AutoAward.


]]>




STEP 2:


That's part 1 done. Now Part 2:  you need to copy the medals onto the server. As follows:

Find the folder /Themes/default again.
Inside /Themes/default folder you should see a folder called images. If not, make it yourself.

Next, go into the images folder. Make another folder inside it. Call the folder medals.

Copy all the picture files into that folder.


You are done. If everything works the way they are supposed to, you should see the mod up and running.



Title: Re: Auto Award
Post by: rumblecloud on November 01, 2013, 04:56:17 PM
Hi JohnWayne999  ;D

I have your mod up and running on 2.0.6. The members like it. So do I.

But like everyone else, I want to change it  :laugh:

So a question forms:
You mention in your instructions that the awards can be based other than post count, but be sure what you want that to be. "just replace the variable $message['member']['posts'] with whatever variable you have in mind, as long as you know what those exact variables are. "

I want to give out small badges based it on request or just because I want to give one out. So I am assuming I would replace ['posts'] with a variable. Would it be as simple as making it say ['requests'] or what?

Thanks for the great mod.

r

Title: Re: Auto Award
Post by: JohnWayne999 on November 20, 2013, 10:03:16 AM
Quote from: rumblecloud on November 01, 2013, 04:56:17 PM
Hi JohnWayne999  ;D

I have your mod up and running on 2.0.6. The members like it. So do I.
But like everyone else, I want to change it  :laugh:

So a question forms:
You mention in your instructions that the awards can be based other than post count, but be sure what you want that to be. "just replace the variable $message['member']['posts'] with whatever variable you have in mind, as long as you know what those exact variables are. "

I want to give out small badges based it on request or just because I want to give one out. So I am assuming I would replace ['posts'] with a variable. Would it be as simple as making it say ['requests'] or what?

Thanks for the great mod.

r

Hey there, thanks for the feedback. I'm glad it worked on 2.0.6. If anyone finds it working on simplemachine 1.x please let me know also.

I get what you are asking. You want to assign medals as you like, based on just anyone who asks and that you approve. In simplemachine there is no innate variable for that. You'd need to construct some sort of table file to store which member has been manually assigned what medal. It's a bit too complicated for me for the time being.

Good news is someone actually has already made a mod to do what you want. Just look around in the mods repository, you can award trophies or something as you please. Maybe it's this one:
http://custom.simplemachines.org/mods/index.php?mod=313
Have a look see if it fulfills your desire :D
Title: Re: Auto Award
Post by: kingkingston on November 23, 2013, 05:41:26 AM
here are some other medals you could use
http://www.iconarchive.com/search?q=medals
Title: Re: Auto Award
Post by: tjbalon on January 08, 2014, 12:35:55 AM
I was wondering if anyone has made this for member groups yet? I know what variable to add, but a bit confused on how I would go about editing the whole system if I wanted to declare certain awards per certain member group.
Title: Re: Auto Award
Post by: TheListener on January 08, 2014, 12:44:21 AM
Quote from: JohnWayne999 on November 20, 2013, 10:03:16 AM
Quote from: rumblecloud on November 01, 2013, 04:56:17 PM
Hi JohnWayne999  ;D

I have your mod up and running on 2.0.6. The members like it. So do I.
But like everyone else, I want to change it  :laugh:

So a question forms:
You mention in your instructions that the awards can be based other than post count, but be sure what you want that to be. "just replace the variable $message['member']['posts'] with whatever variable you have in mind, as long as you know what those exact variables are. "

I want to give out small badges based it on request or just because I want to give one out. So I am assuming I would replace ['posts'] with a variable. Would it be as simple as making it say ['requests'] or what?

Thanks for the great mod.

r

Hey there, thanks for the feedback. I'm glad it worked on 2.0.6. If anyone finds it working on simplemachine 1.x please let me know also.

I get what you are asking. You want to assign medals as you like, based on just anyone who asks and that you approve. In simplemachine there is no innate variable for that. You'd need to construct some sort of table file to store which member has been manually assigned what medal. It's a bit too complicated for me for the time being.

Good news is someone actually has already made a mod to do what you want. Just look around in the mods repository, you can award trophies or something as you please. Maybe it's this one:
http://custom.simplemachines.org/mods/index.php?mod=313
Have a look see if it fulfills your desire :D

Johnwayne the link you gave is NOT for 2.0.x series it is for 1.1.x
Title: Re: Auto Award
Post by: PuckinNutz on January 30, 2014, 05:01:17 PM
I want to be able to assign members awards based on succes they had in a game. We run a NHL league for xbox and I want to be able to setup trophies at the end of each season, like most goals in a season to an individual , or allstar , a trophie for winning the stanley cup and so on. Any ideas?
Title: Re: Auto Award
Post by: vladok on June 18, 2014, 06:12:46 AM
Somebody solved problem with addition "title=someting" from array to awards?
Title: Re: Auto Award
Post by: meemzo on October 17, 2014, 06:27:39 PM
I would like to know if it's possible to hide awards on admins and moderators.  Also is it possible to link awards to "likes" instead of posts.
Title: Re: Auto Award
Post by: Worldwide7477 on February 13, 2015, 12:07:58 AM
Hey JohnWayne999,

I love that i have found you, i was on a forum that is running this mod and thought it was there making lol and was about to ask for the medals, but long and behold i just added 2.09 to my sight and was browsing around the sight for some extras and here you are with what i'm looking for  ;)

I am a very new newbie to all of this so if you can point me in the right direction or any other member can let me know how to install this that would be great, i'm no newbie to coding but newbie to smf in the installs but it coming along.

Thank you once again for I think one of the best mods out there

"I Like It Allot" in my forest gump voice
Title: Re: Auto Award
Post by: Dragon41673 on April 21, 2015, 03:41:13 PM
I tried searching, but could not find the needed answer.

Is there a way to make the medals display after the post count? Currently (image attached), my avatar is under almost everything else...but the medals are near the top.

What I'd like to do is swap where the medals & avatar are at. Any help would be appreciated. I'm still learning all this, so I will apologize in advance if the solution is simple!

Thank you!
Title: Re: Auto Award
Post by: Dragon41673 on April 30, 2015, 11:15:08 PM
Can anyone help with this?
Title: Re: Auto Award
Post by: Gluz on May 01, 2015, 01:19:14 AM
For that you can edit /Themes/yourtheme/Display.template.php

Then search for the sections of the Poster and move to wherever you want, or if you explain where you want each thing in detail and attach that file I can do the edits for you.
Title: Re: Auto Award
Post by: Dragon41673 on May 01, 2015, 01:58:55 PM
Awesome...thanks for the direction. That helped me fix a couple issues at the same time that I haven't posted about yet! Very much appreciated!
Title: Re: Auto Award
Post by: Dragon41673 on May 31, 2015, 04:55:02 PM
I just hit 1,000 posts, and my awards disappeared. I do have the count of 1000 listed I. The proper file, but they aren't showing. Any thoughts?

EDIT - I think I just found the issue...here's what is listed in my display.template.php file...


// Start of AutoAward
if (!isset($context['disabled_fields']['posts'])){
$imagesURL = $settings['default_images_url'] . '/medals';
$medalscore = array (10,20,30,40,50,100,150,200,300,400,600,800,1000,1300,1600,2000);

$mc=1;
foreach($medalscore as $ms){
if($message['member']['posts']>=$ms)
echo '<img src="', $imagesURL, '/medal', $mc++, '.png" alt="" />';
} // end of ms foreach
} //end isset disabled fields if
// End of AutoAward.


Shouldn't the listing for where it pulls the images point to the default theme folder? I ask because I'm not using the default template, I'm personally using a different one, yet all medals until I hit 1000 were showing properly & increased while I posted more.
Title: Re: Auto Award
Post by: Dragon41673 on June 06, 2015, 04:10:26 PM
JohnWayne999...can you please help out with my issue above? I'm still waiting for a response.

Thanks!
Title: Re: Auto Award
Post by: Dragon41673 on June 10, 2015, 09:06:05 PM
Ok, can anyone help with this? I've checked on all installed Theme's and my personal awards do not show up now that I've hit 1000+ posts. I checked & 1000 is listed in the display template for the awards...but they aren't showing. No one else is having this issue...but I'm the only one past 1000 at this time.

Thanks
Title: Re: Auto Award
Post by: JohnWayne999 on July 25, 2015, 12:16:49 PM
Hey Dragon4 (and everybody else infact), my profuse apologies for not replying.
I've just been incredibly busy all these years and only more so these coming 2 years.

Dragon4 I had a quick look back at the code and can't understand why past 1000 won't work.
Sorry man I got a couple of pretty damn important exams to study for and don't have spare time to dig into this problem right now.

How about post your problem up https://www.elance.com/
Pay someone $10 to solve your issue. Some people will try to flog hundreds of dollars off you, especially programming companies, just decline those. Generally programmers from India or Asia or latin America are cheaper. You shouldn't need to spend more than $10 tops to have this issue solved.
Make sure ask them to explain to you what was the problem, and how they overcome it. So you don't need to re-ask them again when similar problem comes up. Tell them you want to test run the code yourself before you will pay, or some people take your payment and run.

Good luck. And tell us what the problem is if you find out please.
Title: Re: Auto Award
Post by: Dragon41673 on July 27, 2015, 11:02:41 PM
JohnWayne,

I completely understand being busy, that's perfectly fine, but telling me to pay someone else to fix something that isn't working in your program...seems pretty out of line. Not to be rude, but I didn't reply until now because your response really ticked me off. If there's a problem with the add on you've provided, that you are supposed to be supporting, why should I pay someone to fix something that is you as the creator should be responsible to fix?

I will wait for you to hopefully look in to this issue, as there's no reason as to why it shouldn't be working on my site since all awards were working up until I hit 1000. I've even gone so far as to uninstall it, removed all files afterwards, cleared the cache from the server I am on...and reinstalled a new version. Still...same issue.

If for some reason you no longer want to support your mod, you may want to have it removed from this site or notify SMF that you're no longer willing or capable of supporting it so they can mark it as such.
Title: Re: Auto Award
Post by: JohnWayne999 on July 28, 2015, 02:51:51 AM
Hey Dragon4, thanks for the honest feedback. I'm sorry you feel this way. My apologies if you feel insulted. Never intended.

I provide help when I can as evidenced in many previous pages. When I cannot, I point people in a direction which I personally would take if it were me. That's all. Feel free not to ask for help elsewhere pay or not pay. I totally respect it. Just to be clear though not just to you but everybody, legally and morally I am not bound to provide after service any time all times. This is just a hobby, nothing more nothing less.

My apologies again if you found anything rude from me. I was just trying to help you overcome a problem that seems to have been stuck for months, that's all. Take it easy mate. Hope you find a solution soon enough. Do let us know if you find out what the problem was, be it my code or your system.

If you find anything that happens on this board that is not in keeping with expected regulations, please kindly also raise your concerns to the moderator so they can better assist you also. Thanks.
Title: Re: Auto Award
Post by: outwork on September 28, 2015, 06:06:39 PM
Hi. I am using the latest version of SMF with the latest version of Auto Awards plugin. I tried to use this awesome plugin, but it is not working well. If the plugin gives the badges based on the posts number than everything is ok, but if I am trying to give badges based on the karma than did not working on the proper way (it displays all the badges, even those which milestone is not reached - for an user which has 15 karma it displays the badge which requires 2000 karma points)

Here is the Display.template.php file, which - i think - was modified on the right way, as it is described on plugin description page:
pastebin . com / Z5eapNEj
(Pls remove the spaces from the link - sorry I cant post urls)

Thank you
Title: Re: Auto Award
Post by: Uardo on November 12, 2015, 03:38:32 AM
I want to make it so it will display one medal after a user completes one year since he/she registered his/her account and when their account has 2 years since it was registered it will display two medals and so on year after year, is that possible please?

Thanks in advance!
Title: Re: Auto Award
Post by: TSF666 on February 09, 2016, 10:59:13 AM
I got a question, how to change in Auto Award mode how many medals should be visible??
Please, help.
Title: Re: Auto Award
Post by: Jacek666 on February 10, 2016, 02:39:59 PM

Just how to do appearing one medal and it was changing from time to time just as theses and 4 medals intyeresujÄ… me knows someone something?
Title: Re: Auto Award
Post by: desiamerican26 on May 21, 2016, 10:46:15 AM
Hello John,

I just installed this Mod on my SMF Forum. I really like this one. The only issue I am encountering is that it's only showing for 1 or 2 users. Well I have seen only one user so far. It's not showing for any other users. Can you please help me out with that?

My Site: desi-american.com

Thank You
Nik
Title: Re: Auto Award
Post by: Dragon41673 on May 21, 2016, 10:50:39 AM
I took a quick peek at your forum, and it's possible you're having the same issue I am...which isn't being resolved after numerous requests. Anything over 1,000 posts...and Awards stop working.

Check the few that are showing, see how many posts they have, then compare that to the ones that don't show. You may have the same issue.
Title: Re: Auto Award
Post by: desiamerican26 on May 21, 2016, 02:19:36 PM
Yup u r ryt Dragon....I do see of around 3 users who have medals showing.....they have posts less than 100....but then there are other ppl who are less than 100 posts....but now showing the medals.

I want to also show medals accordingly....I am not sure if we can control that.
Title: Re: Auto Award
Post by: Dragon41673 on May 21, 2016, 02:21:36 PM
Not sure about your issue if they aren't showing under 1000. That's where my issue begins.
Title: Re: Auto Award
Post by: desiamerican26 on May 21, 2016, 02:50:06 PM
No Clue Frend....some ppl have medals with 20 posts....and some with same post count doesn't....but lot of users aren't showing medals at all.....
Title: Re: Auto Award
Post by: Dragon41673 on May 21, 2016, 03:00:27 PM
Interesting...try uninstalling and reinstalling
Title: Re: Auto Award
Post by: desiamerican26 on May 21, 2016, 08:38:21 PM
No Luck  :(... I don't even see anywhere if I need to make changes or anything. I also wanted to make it like a Newbie will get 1 Medal, and then upto 100 Posts or 200 Posts, they get the 2nd one.....

But doesn't seen like anything is working here  :o
Title: Re: Auto Award
Post by: Dragon41673 on May 21, 2016, 09:03:37 PM
To change who gets medals per post count, you have to edit the files included. Sorry...I'm not sure why it's not working for you the way it should.
Title: Re: Auto Award
Post by: desiamerican26 on May 22, 2016, 08:35:24 AM
Well this is kinda weird now. I changed the settings of post count. below is the code I changed with # of posts:

$medalscore = array (1,500,800,1000,1200,1675,1970,2350,3000,4000,6000,8000,10000,13000,16000,20000); and so on..... As the first code I set up as for Newbies which is 1 post, i do see most of the members having 1 post have 1 medal, there is a member who have 600+ post, I do see his medals as 2 of them according to my settings.

But Users who have over 2000 or 3000 or 5000 posts doesn't have medals as what they should be having as per my # settings. They are showing 1 Medal. Any clue why is that happening?
Title: Re: Auto Award
Post by: Dragon41673 on May 22, 2016, 09:48:59 AM
Not sure, but even though you changed when people get medals...that's very close in amount of medals where mine stops. I think there is a coding problem but the maker doesn't want to take the time to fix it.
Title: Re: Auto Award
Post by: underc0de on July 22, 2016, 02:03:38 PM
Hi, I have a little question. It is possible from the admin panel add medals manually?
Because in my community we have games and I would like give medals to the winners.

Regards and nice mod!
Title: Re: Auto Award
Post by: aodio on November 14, 2016, 12:57:50 AM
Reading the posts... Wouldn't medals awarded be governed by the amount of awards available of file?...otherwise wouldn't you just be doubling up on medal jpg's?
Title: Re: Auto Award
Post by: aodio on November 14, 2016, 04:18:48 AM
Has someone cleaned up these medal jpg's as yet... would love to give it a try .. but have a black background

cheers
Title: Re: Auto Award
Post by: bod22 on February 05, 2020, 03:44:15 AM
Is it possible to use this mod so that it shows medals only for belonging to different groups on forum, not the numer of written posts?

I mean to set one medal for each group and when a user belongs to three or more groups it has three or more different medals in his profile that represents each group. Is it possible?
Title: Re: Auto Award
Post by: Strannik64 on January 30, 2022, 03:20:19 AM
upgrade to 2.1 RC4  :'(
Title: Re: Auto Award
Post by: Gratrix23 on October 29, 2023, 12:28:07 PM
I always loved this mod but sad I can't use it on my new forum. Will it ever be updated to be compatible with 2.1?

Appreciate your work.
Title: Re: Auto Award
Post by: Doug Heffernan on October 29, 2023, 01:00:24 PM
Quote from: Gratrix23 on October 29, 2023, 12:28:07 PMI always loved this mod but sad I can't use it on my new forum. Will it ever be updated to be compatible with 2.1?

Seen the fact that the mod author hasn't been logged in for almost 7 years I doubt that this mod will be upgraded to 2.1.x. You are better off either requesting a new mod coded for you at our  Mod Requests (https://www.simplemachines.org/community/index.php?board=79.0) board or putting a free and/or paid upgrade request for this mod at our Help Wanted (not for support) (https://www.simplemachines.org/community/index.php?board=50.0) board.