View Single Post
Author Message
MAGNET12
Member
Join Date: Dec 2017
Old 08-29-2018 , 03:36   AchievementsGO - easy-to-use developer tool for creating your own Achievements
Reply With Quote #1

<< This plugin is obsolete. New version can be found here >>




Description

It's a really easy-to-use plugin, which allows to create your own Achievements. Everything is based on SQLite and created in a very intuitive way.
All you have to do is upload it on the server and try to create some achievements on your own

Commands

Code:
!ac - opens engine's main menu

Example:
Code:
#include <sourcemod>
#include <AchievementsGO>
  
int AGO_Bomb;
  
public OnPluginStart()
{
	HookEvent("bomb_planted", Event_BombPlanted);
}
  
public void AGO_OnRegisterAchievements()
{
	AGO_Bomb = AGO_AddAchievement("Boom!", "Plant 5 bombs", "Pyro path", 5);
}
  
public Action Event_BombPlanted(Handle event, const char[] name, bool dontBroadcast)
{
	int attackerId = GetClientOfUserId(GetEventInt(event, "userid"));
	
	AGO_AddPoint(attackerId, AGO_Bomb);
}
The only requirement for creating Achievement is one native - AGO_AddAchievement. We pass respectively: Name of achievement, its description, catalog and value - that's it.

Achievement can be put on 'folders' - just give catalog's name in the 3rd argument. In game, catalog is marked by sign '>'. If we don't want our achievement in any folder, just leave this argument blank ("")
After you're done, just update a given achievement's status (ie add points), using for example: AGO_AddPoint

Plugin has a lot of natives and forwards to make your development even simpler:
https://github.com/MAGNET1/SourceMod...evementsGO.inc

The accomplished achievement information is shown in HintText and in the chat (chat: all the players)

Screens:






Download

https://github.com/MAGNET1/SourceMod

or attachment:
Attached Files
File Type: zip AchievementsGO.zip (96.5 KB, 299 views)
__________________

Last edited by MAGNET12; 05-17-2020 at 08:20.
MAGNET12 is offline