Hello, there! In this thread I want to presetn you one shop plugin, which I'm making from long time ago. Тhere are some more things o add, so I'll update the new features regularly. This plugin is suitable for Respawn servers, because I used a check for the player spawn, instead of the round start check. The shop is payed by the money from the game and there are some cvars for convenience.
Shop items:
1. + <num> HP
/Adds some amount of HP on the player/
2. + <num> Armor
/Adds some amount of Armor on the player/
3. + <num> HP and Armor
/Adds some amount of Armor and HP on the player/
4. AWP
/gives AWP to the player/
5. Chameleon
/gives model from the other team to the player/
6. Speed
/increases the speed of the player/
7. G3SG1
/gives G3SG1 to the player/
8. Invisibility (70%)
/makes the player 70% invisible/
9. All Grenades
/gives all grenades to the player/
New Items ( v4.7 ):
10. М249 + Deagle
/gives M249 and Deagle to the player/
11. Gravity 60%
/makes the gravity of the player 60%/
12. Gravity 35%
/makes the gravity of the player 35%/
New Items ( v4.8 ):
13. Zombie Models
/sets a Zombie Model to the player/
New Items ( v5.3 ):
14. Silent Walk
/makes the footsteps of the player silent/
15. No Recoil
/no recoil on user/
16. Full Ammo
/fills the ammo of the current weapon of the player/
17. Double Damage
/the player makes double damage with any weapon/
These are the items for now, I'm going to add some more later and update the plugin.
CVARs:
1. Define the amount of HP and Armor items:
shop_hp_amount <num> (default: 200)
/Amount of HP for item №1/
shop_armor_amount <num> (default: 200)
/Amount of Armor for item №2/
shop_hp_and_armor_amount <num> (default: 255)
/Amount of HP and Armor for item №3/
2. Define if the No Recoil, Gravity and Speed items are for time, and if so - define the time:
-No Recoil
shop_no_recoil_for_time (default: 1)
/If the No Recoil is for time; 1 - for time; 0 - to next spawn/
shop_no_recoil_lenght <num> (default: 20)
/The No Recoil time if the cvar is on/
-Speed
shop_speed_for_time (default: 1)
/If the Speed is for time; 1 - for time; 0 - to next spawn/
shop_speed_lenght <num> (default: 20)
/The Speed time if the cvar is on/
-Gravity
shop_gravity_for_time (default: 1)
/If the Gravity is for time; 1 - for time; 0 - to next spawn/
shop_gravity_lenght <num> (default: 20)
/The Gravity time if the cvar is on/
*The time ramaining till the item's removing appears in HUD in the upper left corner
*The Gravity cvar is for both types of gravity
3. Define the max items bought for spawn:
shop_max_items_for_spawn <num> (default: 0)
/0 - unlimited items per spawn/
4. Define the items' costs:
shop_hp_cost <num> (default: 5000$)
/cost of item №1 (+HP)/
shop_armor_cost <num> (default: 5000$)
/cost of item №2 (+Armor)/
shop_hp_and_armor_cost <num> (default: 12000$)
/cost of item №3 (+HP и Armor)/
shop_awp_cost <num> (default: 13000$)
/cost of item №4 (AWP)/
shop_chameleon_cost <num> (default: 16000$)
/cost of item №5 (Chameleon)/
shop_speed_cost <num> (default: 10000$)
/cost of item №6 (Speed)/
shop_g3sg1_cost <num> (default: 13000$)
/cost of item №7 (G3SG1)/
shop_invisible_cost <num> (default: 16000$)
/cost of item №8 (Invisible)/
shop_grenades_cost <num> (default: 2000$)
/cost of item №9 (All Grenades)/
shop_m249_deagle_cost <num> (default: 8000$)
/cost of item №10 (М249 + Deagle)/
shop_gravity_60%_cost <num> (default: 9000$)
/cost of item №11 (Gravity 65%)/
shop_gravity_35%_cost <num> (default: 15000$)
/cost of item №12 (Gravity 35%)/
shop_zombie_cost <num> (default: 5000$)
/cost of item №13 (Zombie Models)/
shop_silent_walk_cost <num> (default: 5000$)
/cost of item №14 (Silent Walk)/
shop_no_recoil_cost <num> (default: 15000$)
/cost of item №15 (No Recoil)/
shop_ammo_cost <num> (default: 6000$)
/cost of item №16 (Full Ammo)/
shop_dmg_x2_cost <num> (default: 15000$)
/cost of item №17 (Double Damage)/
NEW OPTION: VIP players' costs (flag "e" - slay)
First is the cvar to define if VIP costs are enabled (default: disabled):
vip_costs 0/1 (default: 0)
Next is to define the VIP players' costs. Default they are the same, but they can be changed with the following cvars:
shop_hp_vip_cost <num> (default: 5000$)
/Cost of item №1 (+HP) for VIP players/
shop_armor_vip_cost <num> (default: 5000$)
/Cost of item №2 (+Armor) for VIP players/
shop_hp_and_armor_vip_cost <num> (default: 12000$)
/Cost of item №3 (+HP и Armor) for VIP players/
shop_awp_vip_cost <num> (default: 13000$)
/Cost of item №4 (AWP) for VIP players/
shop_chameleon_vip_cost <num> (default: 16000$)
/Cost of item №5 (Chameleon) for VIP players/
shop_speed_vip_cost <num> (default: 10000$)
/Cost of item №6 (Speed) for VIP players/
shop_g3sg1_vip_cost <num> (default: 13000$)
/Cost of item №7 (G3SG1) for VIP players/
shop_invisible_vip_cost <num> (default: 16000$)
/Cost of item №8 (Invisible) for VIP players/
shop_grenades_vip_cost <num> (default: 2000$)
/Cost of item №9 (All Grenades) for VIP players/
shop_m249_deagle_vip_cost <num> (default: 8000$)
/Cost of item №10 (М249) + Deagle for VIP players/
shop_gravity_60%_vip_cost <num> (default: 9000$)
/Cost of item №11 (Gravity 65%) for VIP players/
shop_gravity_35%_vip_cost <num> (default: 15000$)
/Cost of item №12 (Gravity 35%) for VIP players/
shop_zombie_cost <num> (default: 5000$)
/Cost of item №13 (Zombie Models) for VIP players/
shop_silent_walk_vip_cost <num> (default: 5000$)
/Cost of item №14 (Silent Walk) for VIP players/
shop_no_recoil_vip_cost <num> (default: 15000$)
/Cost of item №15 (No Recoil) for VIP players/
shop_ammo_vip_cost <num> (default: 6000$)
/Cost of item №16 (Full Ammo) for VIP players/
shop_dmg_x2_vip_cost <num> (default: 15000$)
/Cost of item №17 (Double Damage) for VIP players/
3.Turn on/off items:
*Default all the items are enabled. Value 1 turns the item on, value 0 turns it off.*
shop_hp_on
/Turn on/off item №1/
shop_armor_on
/Turn on/off item №2/
shop_hp_and_armor_on
/Turn on/off item №3/
shop_awp_on
/Turn on/off item №4/
shop_chameleon_on
/Turn on/off item №5/
shop_speed_on
/Turn on/off item №6/
shop_g3sg1_on
/Turn on/off item №7/
shop_invisible_on
/Turn on/off item №8/
shop_grenades_on
/Turn on/off item №9/
shop_m249_deagle_on
/Turn on/off item №10/
shop_gravity_60%_on
/Turn on/off item №11/
shop_gravity_35%_on
/Turn on/off item №12/
shop_zombie_on
/Turn on/off item №13/
shop_silent_walk_on
/Turn on/off item №14/
shop_no_recoil_on
/Turn on/off item №15/
shop_ammo_on
/Turn on/off item №16/
shop_dmg_x2_on
/Turn on/off item №17/
If the item is disabled, it won't even appear in the shop menu!
These are the cvars to define the chat messages prefix:
shop_prefix "PREFIX" (default:
[CS-MaxGaminG.iNFO])
/defines the chat messages prefix/
Example:
shop_prefix "
[ServerPrefix]"
shop_prefix_color <num> (default:
4)
/defines the chat message prefix color/
1 -
default chat color
3 -
team color -
EXAMPLE
4 -
green color -
EXAMPLE
Chat Messages:
1. When you buy current item -
EXAMPLE
2. When you are dead or spectator and try to buy something -
EXAMPLE
3. When you don't have enough money -
EXAMPLE
4. When you already have the current item -
EXAMPLE
5. When you have already bought the max items allowed -
EXAMPLE
Here is the еxterior of the plugin -
Page №1 Page №2 Page №3
CHANGELOG:
Code:
-------------Version 4.7--------------
-added items №10, 11 и 12
-reduced the size of the code
-------------Version 4.8--------------
-аdded item №13
-added VIP costs option
-reduced the size of the code
-------------Version 5.3--------------
-аdded many new items №14, 15, 16, 17
-added different way to disable items from shop - they directly disappear from the menu instead of chat message
-added the max items per spawn option
-added the time cvars for No Recoil, Speed and Gravity
-optimized the code a lot
-*Little after the release of this version, but too insignificant for new version*- Changed client_PreThink with a fakemeta forward for the no recoil option
ToDo List:
Code:
-Add a new HeadHunter option (HeadShot only)
-Add a point system! And there will be two different shops - money shop and points shop
*I hope you'll enjoy it! It took me a lot of time, so I expect you will like it. I'm waiting for your notes, opinions, reviews and remarks.