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
/buyhpand/creditsfrom 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
- Make sure the
funmodule is enabled inmodules.ini. - Compile, copy
csb_buy_hp.amxxintoaddons/amxmodx/plugins/and add it toplugins.ini. - 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().
Installation
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
| CVAR | Default | Description |
|---|---|---|
csb_buyhp_enabled | 1 | Enable or disable the buy-HP item. |
csb_buyhp_cost | 10 | Credit cost of one purchase. |
csb_buyhp_amount | 25 | HP granted per purchase. |
csb_buyhp_maxhp | 150 | Maximum HP a player can reach through the shop. |
csb_buyhp_limit | 3 | Purchases allowed per round (0 = unlimited). |
csb_buyhp_reward | 2 | Credits earned per kill. |
Commandes2
| Command | Access | Description |
|---|---|---|
say /buyhp | | Buy extra health with credits. |
say /credits | | Show your current credit balance. |
Note
Pas encore de notes









