Unlimited Money Mode 1.0.0 (olds.ro)
====================================
For fun servers where buying is not the point. Players keep a fixed amount
of money (16000 by default): it is set when they spawn and put back right
after every purchase. In mode 2 the money line is also hidden from their HUD,
while buying works as usual. You choose which team gets it; the other team
keeps the normal economy.
Requirements
- ReHLDS, ReGameDLL_CS, Metamod-R, ReAPI
- AMX Mod X 1.10 or newer (written and tested on 1.10.0.5490)
Install
1. Compile scripting/olds_umoney.sma and copy olds_umoney.amxx to
addons/amxmodx/plugins/. The compiler needs ReAPI's include files
(reapi.inc and the reapi_*.inc files from the ReAPI release) next to the
stock AMX Mod X includes.
2. Copy data/lang/olds_umoney.txt to addons/amxmodx/data/lang/.
3. Copy configs/plugins/olds_umoney.cfg to addons/amxmodx/configs/plugins/
(if it is missing, the plugin writes it with the default values).
4. Add olds_umoney.amxx to addons/amxmodx/configs/plugins.ini.
How it works
- When a player of a chosen team spawns, the account is set to
olds_umoney_amount.
- Every purchase (weapons, ammo, armour, grenades, defuse kit, night
vision, shield; from the buy menu, a buy command, autobuy or rebuy) is
paid as usual, and on the very next server frame the account is set back
to olds_umoney_amount.
- Players with the fixed money get no kill reward (olds_umoney_kill 0), and
lose nothing to the game's penalties: killing a teammate, hurting or
killing a hostage.
- Mode 2 hides the money line by adding the money flag (32) to the
HideWeapon message the client gets. The game's own HUD updates (spawn,
death, spectating) keep the flag, so the money line stays hidden. Changing
olds_umoney_mode or olds_umoney_team shows or hides it at once.
- The game never gives more than mp_maxmoney (16000 by default). If
olds_umoney_amount is higher, the server console says so at map start;
raise mp_maxmoney to give more.
- Money the game adds between two spawns, such as the round-end bonus, is
not taken away: the account goes back to the fixed amount at the next
spawn or purchase.
Settings (addons/amxmodx/configs/plugins/olds_umoney.cfg)
olds_umoney_mode 1 0 = off (normal economy), 1 = fixed money,
2 = fixed money and the money line hidden
olds_umoney_amount 16000 the fixed amount (0 - 999999, capped by mp_maxmoney)
olds_umoney_team 3 1 = Terrorists, 2 = Counter-Terrorists, 3 = both teams
olds_umoney_kill 0 1 = kill rewards are still paid, 0 = no kill reward
Commands
None.
Tested on ReHLDS 3.15.0.896, ReGameDLL_CS 5.30.0.814, Metamod-R 1.3.0.149,
AMX Mod X 1.10.0-git5490, ReAPI 5.29.0.358, with bots: the account at 16000
after the spawn and again on the next frame after buying an AWP, a rifle and
armour; no kill reward with olds_umoney_kill 0 and +300 with 1; no -3300 for
killing a teammate; the money flag on every HideWeapon message in mode 2,
also on the game's own updates and after a new round, and removed again in
mode 1; with olds_umoney_team 2 only Counter-Terrorists keep 16000 while
Terrorists pay as usual and lose 3300 for a teammate kill.
No sounds, models or sprites are added.
Credits and licence
Written from scratch by alexit (olds.ro workshop) for workshop card LIB-2005.
Licence: GNU GPL version 3 or later (GPL-3.0-or-later).