Raised This Month: $51 Target: $400
 12% 

OciXCrom's Rank System [XP|Levels|Ranks]


Post New Thread Reply   
 
Thread Tools Display Modes
Nito
Junior Member
Join Date: Jun 2017
Old 03-24-2021 , 04:34   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #611

Quote:
Originally Posted by OciXCrom View Post
Are you using AMXBans or some other admin privilege system?
Yes i use amxbans and SMS shop
Nito is offline
Nito
Junior Member
Join Date: Jun 2017
Old 03-25-2021 , 06:30   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #612

Anyone help? :c
Nito is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 03-25-2021 , 08:49   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #613

I'll add AMXBans support in the next update. As a temporary solution, try adding this in crx_ranksystem.sma:

Code:
#include <amxbans_core> public amxbans_admin_connect(id) {     if(g_ePlayerData[id][Level] == g_iMaxLevels && g_eSettings[FINAL_LEVEL_FLAGS])     {         set_user_flags(id, g_eSettings[FINAL_LEVEL_FLAGS_BIT])         remove_user_flags(id, g_iFlagZ)     } }
__________________

Last edited by OciXCrom; 03-25-2021 at 08:49.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
MihailoZ
Member
Join Date: Aug 2013
Old 03-25-2021 , 11:57   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #614

Is it possible to make a rank system, when you kill someone, you gain X points, with each point you can level up: speed, gravity, armor, health, chance to get AWP with only 1 bullet etc.?

Thanks.
__________________
mhvtnns
MihailoZ is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 03-25-2021 , 15:02   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #615

Yes and it already exists.

Health per Level - https://www.amxx-bg.info/viewtopic.php?f=21&t=4594
Examples of speed/gravity/armor/etc - https://www.amxx-bg.info/viewtopic.php?p=27442#p27442

Example of AWP with 1 bullet on X level:

Code:
#include <amxmodx> #include <crxranks> #include <cstrike> #include <fun> #include <hamsandwich> const AWP_LEVEL = 5 const AWP_CHANCE = 15 public plugin_init() {     register_plugin("CRXRanks: AWP Chance", "1.0", "OciXCrom")     RegisterHam(Ham_Spawn, "player", "OnPlayerSpawn", 1) } public OnPlayerSpawn(id) {     if(is_user_alive(id) && crxranks_get_user_level(id) >= AWP_LEVEL && random_num(1, 100) <= AWP_CHANCE)     {         cs_set_weapon_ammo(give_item(id, "weapon_awp"), 1)         cs_set_user_bpammo(id, CSW_AWP, 0)     } }

You can even get creative and make the chance go up depending on the level:

Code:
random_num(1, 100) <= AWP_CHANCE + 2 * crxranks_get_user_level(id)

Pretty much anything is possible.
__________________

Last edited by OciXCrom; 03-25-2021 at 15:02.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
karaulov
Senior Member
Join Date: Jul 2018
Old 03-27-2021 , 02:22   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #616

How to set minimum XP to -500 (for check activity), at now if player is noob, he have 0 XP. But player can be is active. I tried to mute all new players by checking XP. But any new players and noob players has 0 XP ))

I tried add new level in RankSystem.ini but it not works.

Ranks]
# Here you can add the ranks that players will get according to their XP.
# Start from the lowest with 0 XP to the highest. The number of ranks you can add is unlimited.
# Rank names cannot start with any of these symbols: "#", ";", "-" and "["
# Syntax: rank name = minimum XP needed
Noob = -500
New = 0
Player = 100

Last edited by karaulov; 03-27-2021 at 02:48.
karaulov is offline
karaulov
Senior Member
Join Date: Jul 2018
Old 03-27-2021 , 02:32   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #617

You can add crxranks_reset_xp command for users ? (it works only for admins)
karaulov is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 03-27-2021 , 15:00   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #618

Quote:
Originally Posted by karaulov View Post
How to set minimum XP to -500 (for check activity), at now if player is noob, he have 0 XP. But player can be is active. I tried to mute all new players by checking XP. But any new players and noob players has 0 XP ))

I tried add new level in RankSystem.ini but it not works.

Ranks]
# Here you can add the ranks that players will get according to their XP.
# Start from the lowest with 0 XP to the highest. The number of ranks you can add is unlimited.
# Rank names cannot start with any of these symbols: "#", ";", "-" and "["
# Syntax: rank name = minimum XP needed
Noob = -500
New = 0
Player = 100
The plugin is hardcoded to start from 0 XP for coding convenience. Don't see why it is important to go to negative numbers. Simply raise the XP for the first rank and change its name. The effect will be the same.

Quote:
Originally Posted by karaulov View Post
You can add crxranks_reset_xp command for users ? (it works only for admins)
configs/cmdaccess.ini -> remove flag
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 03-27-2021 , 15:34   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #619


  • The entire SQL code has been reworked and highly optimized. The entire procedure is now asynchronous which means that the server won't stall/lag with slower SQL servers, as well as when the connection fails on mapchange.
  • The SQL connection is now made only once when the map starts and closes when the map ends instead of opening/closing each time a player joins/leaves.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
karaulov
Senior Member
Join Date: Jul 2018
Old 03-27-2021 , 23:46   Re: OciXCrom's Rank System [XP|Levels|Ranks]
Reply With Quote #620

Quote:
Originally Posted by OciXCrom View Post
The plugin is hardcoded to start from 0 XP for coding convenience. Don't see why it is important to go to negative numbers. Simply raise the XP for the first rank and change its name. The effect will be the same.
If the player dies often, then he will have a zero (0) value.

How long time this player plays on the server? In any case, it will have '0' value....

If you add a value less than 0 then this can be used to detect player activity.

Last edited by karaulov; 03-27-2021 at 23:47.
karaulov is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 07:44.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode