I've been thinking of including achievement system to one of my maps, but I've found that there is no suitable library. So, I decided to create one myself. Here is what I've came up with. I hope you will find it useful in any way.
If you have any comments or tips for improvement, you're most welcome.
This library allow designers to incorporate achievements into their maps.
It is free to use, you can download, modify, do whatever you want. Putting me in the credits would be nice tho.
Interface for library
Basic functionality and visuals
How to use
Add AchievementLib mod from BN to your map, or download mod files and insert the code directly. Remember about copying or importing custom *.tga files used for achievement dialogs.
Set Achievement Sound - specifies sound played when achievement is awarded.
Set Achievement Timers - specifies timers, f.e. how long achievement should be visible for player.
Set Achievement Max Number - specifies number of awarded achievement that can be displayed on the screen at the same time.
Create Achievement - creates new achievement, specifying it's ID number, image, points, and name.
Award Achievement - awards previously created achievement to specified player.
See example maps for reference.
Library is published on EU. If you want to publish it on other servers - feel free to do so, just let me know.
This is very nice, and it's very easy to use. But there's one small thing, in the function ''Award Achievement'' the ''race'' parameter list is empty. And I can't use id 0? Because that's the default value.