Promocionar servidor

CSB Buy HP v1.0.0

CSB Buy HP is a self-contained shop item: type /buyhp to trade credits for health. Credits are earned by killing (csb_buyhp_reward per frag), each purchase adds csb_buyhp_amount HP up to the cap in csb_buyhp_maxhp, and you can only buy it csb_buyhp_limit times per round.

It needs no external shop core to work, but it also exposes a public callable, csb_hp_give(id, amount), so a larger shop or VIP system can grant capped HP through the same code path.

Features

  • /buyhp and /credits from chat.
  • Health cap so buying never exceeds a sane maximum.
  • Per-round purchase limit.
  • HUD confirmation showing HP added and credits spent.
  • Refuses the purchase when you are already at the cap or short on credits.

Installation

  1. Make sure the fun module is enabled in modules.ini.
  2. Compile, copy csb_buy_hp.amxx into addons/amxmodx/plugins/ and add it to plugins.ini.
  3. Tune the cost/reward/limit cvars in amxx.cfg, then change the map.

Notes

Credits are kept in memory for the duration of a connection; they are not saved to a database. If you want persistent, account-wide credits, feed this plugin from your own store through csb_hp_give().

Instalación
1. Enable the fun module in modules.ini
2. Put csb_buy_hp.amxx in addons/amxmodx/plugins/ and add it to plugins.ini
3. Tune the csb_buyhp_* cvars, change map
Cvars6
CVARDefaultDescription
csb_buyhp_enabled1Enable or disable the buy-HP item.
csb_buyhp_cost10Credit cost of one purchase.
csb_buyhp_amount25HP granted per purchase.
csb_buyhp_maxhp150Maximum HP a player can reach through the shop.
csb_buyhp_limit3Purchases allowed per round (0 = unlimited).
csb_buyhp_reward2Credits earned per kill.
Comandos2
CommandAccessDescription
say /buyhpBuy extra health with credits.
say /creditsShow your current credit balance.
Valoración
Aún sin valoraciones