[CS 1.6] Plugins - Rank System [XP|Levels|Ranks]
OciXCrom's Rank System
- A fully optimized and easy to use rank system, containing tons of options and an API for creating sub-plugins. Unlike other plugins like this where in order to add/remove or change ranks and the required XP for them, the end-user has to make changes in the .sma file and recompile the plugin, this one does everything through a configuration file that doesn't require any scripting skills nor recompiling the plugin after a change has been made. The plugin has an option to set different XP rewards for different in-game events, such as killing a player, headshot, suicide, teamkill, planting/defusing the bomb and so on. You can even specify different rewards for any weapon in the game.
- The plugin can be used in a game different than Counter-Strike. Bear in mind that the chat messages won't be colored when using another game.
- It is also possible to have different settings for different maps. In order to do this, you need to write the map name between dashes on a new line in the configuration file (- de_dust2 -). This will make everything below this line be active only on that specific map. You can also use map prefixes (- de_* -). To go back to global settings, use - #all -.
- /xp, /level -- shows your XP amount, level and rank (changeable in the .ini file)
- /xplist -- opens a menu that shows online players' rank and XP (admins only)
- /hudinfo -- enables/disables HUD information
- crxranks_give_xp -- gives/takes XP to/from the player (admins only)
- crxranks_reset_xp -- resets the player's XP (admins only)
- CHAT_PREFIX -- prefix for chat messages
- SAVE_TYPE -- how to save the XP (nick/IP/SteamID)
- SAVE_INTERVAL -- when to save the XP (on disconnect/death/round end/XP update)
- USE_MYSQL -- if set to 1, the plugin will use MySQL to save the XP, otherwise it will use nVault
- SQL_HOST -- SQL address for use with MySQL
- SQL_USER -- SQL user for use with MySQL
- SQL_PASSWORD -- SQL password for use with MySQL
- SQL_DATABASE -- SQL database for use with MySQL
- SQL_TABLE -- SQL table for use with MySQL
- VAULT_NAME -- name of the vault file where the XP is saved when using nVault
- XP_COMMANDS -- commands that allow you to check your XP
- LEVELUP_MESSAGE_TYPE -- who will see the message when a player reaches a new level
- LEVELUP_SOUND -- sound when a player gains a level
- LEVELUP_SCREEN_FADE_ENABLED -- whether the screen fade effect when a player gains a level will be active
- LEVELUP_SCREEN_FADE_COLOR -- color for the screen fade effect when gaining a level
- LEVELDN_SOUND -- sound when a player loses a level
- LEVELDN_SCREEN_FADE_ENABLED -- whether the screen fade effect when a player loses a level will be active
- LEVELDN_SCREEN_FADE_COLOR -- color for the screen fade effect when losing a level
- FINAL_LEVEL_FLAGS -- here you can specify admin flags that players will receive when they reach the final level
- VIP_FLAGS -- players with these flags are considered VIP and can be set to receive more XP than regular players
- USE_COMBINED_EVENTS -- whether the plugin will use combined XP rewards for specific events
- TEAM_LOCK -- if non-zero, only players that are in thee team set here will be able to receive XP
- MINIMUM_PLAYERS -- if greater than 0, players won't be able to receive XP if there are less than X players in the server
- NOTIFY_ON_KILL -- if enabled, player will receive chat notifications about the XP they receive when killing a player, as well as when committing suicide if the plugin is set to take XP on suicide
- HUDINFO_ENABLED -- whether the HUD info that shows your XP will be enabled
- HUDINFO_VISIBILITY -- who and when is able to see the HUD info
- HUDINFO_TEAM_LOCK -- if the TEAM_LOCK option is enabled and this one is set to 1, players won't be able to see the HUD info if they're not on the team set in TEAM_LOCK, the same applies for the player they're spectating
- HUDINFO_OTHER_PLAYERS -- whether players will be able to see the HUD info of the player they're spectating while dead
- HUDINFO_COLOR -- color for the HUD info
- HUDINFO_POSITION -- coordinates for the HUD info for alive players
- HUDINFO_POSITION_DEAD -- coordinates for the HUD info for dead players
- HUDINFO_USE_DHUD -- whether the HUD info will use a DHUD message
- HUDINFO_FORMAT -- how the HUD info is going to look when the player is on any level except the last one
- HUDINFO_FORMAT_FINAL -- how the HUD info is going to look when the player is on the last level
- HUDINFO_INVALID_TEXT -- what is the HUD info going to display when an invalid value is given
- XP_NOTIFIER_ENABLED -- whether the plugin will show a separate HUD message when gaining/losing XP
- XP_NOTIFIER_COLOR_GET -- color for the XP notifier when gaining XP
- XP_NOTIFIER_COLOR_LOSE -- color for the XP notifier when losing XP
- XP_NOTIFIER_POSITION -- coordinates for the XP notifier
- XP_NOTIFIER_DURATION -- duration of the XP notifier
- XP_NOTIFIER_USE_DHUD -- whether the XP notifier will use a DHUD message
Configuring the ranks
- The ranks can be easily configured in the [Ranks] section in the .ini file.
- As you can see from the default ranks set in the file, each rank is added on a new line by writing its name and the required XP for it separated with the "=" symbol.
- The first rank must start from 0 XP.
- The number of ranks you can add is unlimited.
- The name of the ranks can't start with any of these symbols: "#", ";", "-" and "["
Configuring the XP rewards
- Unlike other plugins where there is a separate setting for each way of earning XP, this plugin has things set up quite differently and it's much easier to use.
- In the [XP Rewards] section you can configure all kinds of XP rewards depending on special keywords.
- For example, if you want players to receive 5 XP on a normal kill, you simply need to write "kill = 5" on a new line in the section, since the keyword "kill" tells the plugin that this reward should be given when you kill a player. For a kill with a headshot, simply use the keyword "headshot", and so on.
- You can even add a separate reward for each weapon in a game, e.g. "awp = 10".
- In order to make VIP users receive different amount of XP than the regular players, for example 10 XP for planting the bomb, while regular players receive 7 XP, you should write "bomb_planted = 7 10".
- Take a look at this link for all keywords available in the plugin.
Showing the ranks in chat
- Since this plugin mainly refers to XP, levels and ranks, and not the chat itself, it is necessary to download a separate plugin for the chat in order to show the ranks in it. Use the Chat Manager plugin for that purpose.
- I have added support in Chat Manager for this plugin, so you can easily activate the ranks in it.
- In order to activate them, you need to add the keyword $rank$ in the [Format Definition] section in the plugin's configuration file. You can make the ranks show only for regular players, along with the admin prefix, etc.
- If you don't know how and where to add it, follow these steps:
- Open the configuration file - configs/ChatManager.ini.
- Find the [Format Definitions] section and replace the 4 settings inside it with these ones:
format_admin = $dead_prefix$ &x04[$rank$] $admin_prefix$ &x03$custom_name$ &x01: $chat_color$$message$
format_admin_team = $dead_prefix$ ($team$) &x04[$rank$] $admin_prefix$ &x03$custom_name$ &x01: $chat_color$$message$
format_player = $dead_prefix$ &x04[$rank$] &x03$custom_name$ &x01: $chat_color$$message$
format_player_team = $dead_prefix$ ($team$) &x04[$rank$] &x03$custom_name$ &x01: $chat_color$$message$
If you don't want the rank to be displayed for the admins who already have an admin prefix, replace only the last two settings and leave the first ones unchanged.
Post a Comment