Page 1 of 1

Bonus Manager v1.2

Posted: 17 Sep 2021, 20:56
by z0h1r-LK
Bonus Manager
Screenshots:
01.jpg
Screenshot.
01.jpg (98.63 KiB) Viewed 12696 times
Screenshot.
Screenshot.
01.jpg (98.63 KiB) Viewed 12696 times
Description:
It's a bonus list, every bonus has have level, The player can get a bonus from menu, once round or after a cooldown time or once time in map.

How to create new bonus plugin:
1. Include <ze_bonus_manager> in your plugin.
2. Declare this in plugin_init()
  1. // Register new bonus in menu.
  2. ze_register_bonus("Frost Nade", "Handler_FrostNade", 30)
3. Create handler function located in ze_register_bonus(), Like it:
  1. public Handler_FrostNade(iPlayer, iBonus) {
  2.     // Player is not a alive
  3.     if (!is_user_alive(iPlayer)) {
  4.         ze_colored_print(iPlayer, "%L", LANG_PLAYER, "BONUS_NOTALIVE")
  5.         return;
  6.     }  
  7.    
  8.     // Give player frost nade.
  9.     rg_give_item(iPlayer, "weapon_flashbang")
  10. }
Requirements:
ze_levels - viewtopic.php?f=15&t=72

How to open menu:
  1. say /bonus
  2. say .bonus
  3. say !bonus
  4. say_team /bonus
  5. say_team .bonus
  6. say_team !bonus
Cvars:
  • ze_bonus_enable
    • 0 | Disable bonus menu.
    • 1 | Always players can get bonus from menu without limit.
    • 2 | Can players get bonus once time every cooldown time. Require: ze_bonus_cooldown.
    • 3 | Can players get bonus, But can't override max times. Require: ze_bonus_maxtimes.
    • 4 | Can players get bonus once time every round.
    • 5 | Can players get bonus once time every map.
  • ze_bonus_cooldown
    • 60 | Cooldown time before re-enable bonus menu for players. Require: ze_bonus_enable 2.
  • ze_bonus_maxtimes
    • 3 | Max times to disable menu for players. Require: ze_bonus_enable 3.
Configuration:
zombie_escape.txt
  1. [en]
  2. BONUS_DONE = You has get the bonus (%s).
  3. BONUS_COOLDOWN = The cooldown time is not over, Wait ^4%d^1 sec(s).
  4. BONUS_LEVEL_ENOUGH = You don't have level enough.
  5. BONUS_ONCETIME = You can get a bonus a once time in map.
  6. BONUS_ISZOMBIE = Bonus menu is not available for zombies.
  7. BONUS_MAXTIME = You have reached the maximum number of times.
  8. BONUS_REMTIMES = You can open bonus menu ^4%s^1 time(s).
  9. BONUS_NOTALIVE = You are not a alive!
  10.  
  11. MENU_TITLE_BONUS = Menu Bonus \r(Your level: %d)
  12. FREE = Free
  13. LVL = Lvl
  14. UNLOCKED = Unlocked!
ze_bonus.ini Copy this file in configs directory.
  1. [+10 HP]
  2. NAME = +10 HP
  3. LEVEL = 5
  4.  
  5. [+10 AR]
  6. NAME = +10 AR
  7. LEVEL = 10
  8.  
  9. [+10 EC]
  10. NAME = +10 EC
  11. LEVEL = 15
  12.  
  13. [Fire Nade]
  14. NAME = Fire Nade
  15. LEVEL = 20
  16.  
  17. [Frost Nade]
  18. NAME = Frost Nade
  19. LEVEL = 25
  20.  
  21. [+10 Speed]
  22. NAME = +10 Speed
  23. LEVEL = 30
  24.  
  25. [Damage x1.2]
  26. NAME = Damage x1.2
  27. LEVEL = 40
Change Logs:
  1. [Version 1.0]
  2.  - Release.
  3. [Version 1.1]
  4.  - Fixed some bugs
  5.  - Fixed display menu for zombies.
  6.  - Fixed level required in menu (Thanks. czirimbolo)
  7.  - Added new items in ze_bns_items.sma.
  8.  - Added new native ze_open_bonus_menu().
  9.  - Updated Cvar ze_bonus_enable.
  10. [Version 1.2]
  11.  - Added new item "Damage x1.2".
  12.  - Added file controlling bonus ze_bonus.ini.
  13.  - Updated Cvar "ze_bonus_enable" new property.
  14.  - Fixed enable bonus menu after player reconnect.
Download:
bonusmanager12.zip
Source Code + INC File + INI File
(5.75 KiB) Downloaded 261 times
bonusmanager12.zip
Source Code + INC File + INI File
(5.75 KiB) Downloaded 261 times

Re: Bonus Manager (1.0)

Posted: 19 Sep 2021, 11:34
by czirimbolo
tempsnip.png
tempsnip.png (96.48 KiB) Viewed 12701 times
tempsnip.png
tempsnip.png (96.48 KiB) Viewed 12701 times
its showing your current level but it should show required level to unlock.

Second thing:
with this cvar ze_bonus_enable 3 (once per map) you can use bonus again after reconnect

Can you fix these?

Re: Bonus Manager (1.0)

Posted: 19 Sep 2021, 16:50
by z0h1r-LK
czirimbolo wrote: 2 years ago tempsnip.png

its showing your current level but it should show required level to unlock.

Second thing:
with this cvar ze_bonus_enable 3 (once per map) you can use bonus again after reconnect

Can you fix these?
Thanks bro.
Updated 1.1, Copy new lang in zombie_escape.txt
Check from change logs

Re: Bonus Manager (1.0)

Posted: 19 Sep 2021, 19:17
by czirimbolo
Z0uha1r_LK wrote: 2 years ago
czirimbolo wrote: 2 years ago tempsnip.png

its showing your current level but it should show required level to unlock.

Second thing:
with this cvar ze_bonus_enable 3 (once per map) you can use bonus again after reconnect

Can you fix these?
Thanks bro.
Updated 1.1, Copy new lang in zombie_escape.txt
Check from change logs
nice, but I have small request:
bonus like HP, armor, speed etc work only for ONE round. Can you make it working on 1 map and resetting after change map? It would have sense then.

Speed bonus or armor for 1 round is a little bit poor

Re: Bonus Manager (1.0)

Posted: 20 Sep 2021, 15:23
by z0h1r-LK
czirimbolo wrote: 2 years ago
nice, but I have small request:
bonus like HP, armor, speed etc work only for ONE round. Can you make it working on 1 map and resetting after change map? It would have sense then.

Speed bonus or armor for 1 round is a little bit poor
I will add this features in next update.

Re: Bonus Manager (1.1)

Posted: 24 Sep 2021, 15:38
by czirimbolo
you can add max 6 bonuses because there is no second page. Please fix it and we can add more than 6 bonuses

Re: Bonus Manager (1.1)

Posted: 25 Sep 2021, 13:22
by z0h1r-LK
czirimbolo wrote: 2 years ago you can add max 6 bonuses because there is no second page. Please fix it and we can add more than 6 bonuses
ok

Re: Bonus Manager (1.1)

Posted: 12 Oct 2021, 21:06
by Raheem
Good job, approved tag added.

Re: Bonus Manager (1.1)

Posted: 13 Oct 2021, 05:05
by czirimbolo
It needs to be fixed bro

Re: Bonus Manager v1.2

Posted: 19 Oct 2021, 14:01
by z0h1r-LK
Update Fully. Version 1.2

Re: Bonus Manager v1.2

Posted: 10 Nov 2021, 12:04
by czirimbolo
Z0uha1r_LK wrote: 2 years ago Update Fully. Version 1.2
Did you fix speed and armor? Speed Bonus is for 1 round or for 1 map? It should be for 1 map

Re: Bonus Manager v1.2

Posted: 14 Nov 2021, 16:09
by z0h1r-LK
czirimbolo wrote: 2 years ago
Z0uha1r_LK wrote: 2 years ago Update Fully. Version 1.2
Did you fix speed and armor? Speed Bonus is for 1 round or for 1 map? It should be for 1 map
Of Course :!:

Re: Bonus Manager v1.2

Posted: 17 Nov 2021, 14:35
by czirimbolo
Z0uha1r_LK wrote: 2 years ago
czirimbolo wrote: 2 years ago
Z0uha1r_LK wrote: 2 years ago Update Fully. Version 1.2
Did you fix speed and armor? Speed Bonus is for 1 round or for 1 map? It should be for 1 map
Of Course :!:
you did NOT fixed it. Speed and armor are STILL only for 1 round, its useless. Make them for 1 MAP

Re: Bonus Manager v1.2

Posted: 17 Nov 2021, 21:55
by z0h1r-LK
So, Topic is will be removed!

Re: Bonus Manager v1.2

Posted: 18 Nov 2021, 12:19
by czirimbolo
Z0uha1r_LK wrote: 2 years ago So, Topic is will be removed!
why? you cant fix it? Its good idea about bonus plugin but must be fixed

Re: Bonus Manager v1.2

Posted: 18 Nov 2021, 12:29
by z0h1r-LK
czirimbolo wrote: 2 years ago why? you cant fix it? Its good idea about bonus plugin but must be fixed
I need time to fix that!

Re: Bonus Manager v1.2

Posted: 18 Nov 2021, 16:01
by Raheem
Trashed based on author request.