VIP Plugin.
-
addryann
- Foreigner
- Мнения: 13
- Регистриран: 10 фев 2019, 22:52
VIP Plugin.
Someone can help me with an plugin , with flag "H" to be for VIP. 1. Deagle & Ak47 + He Grenade &FlashBang + Vest & Helmet . 2 :
Deagle & M4a1+ He Grenade &FlashBang + Vest & Helmet . 3 . Deagle & AWP + VEST & HELM & He Grenade & FlashBang. This menu should appear for flag H , and as well to be on tabscore "V.I.P" instead of "Dead/Bomb" ,and if it's possible,flag "h". 100$ per kill and, 200$ per headshot , to be more special..
Deagle & M4a1+ He Grenade &FlashBang + Vest & Helmet . 3 . Deagle & AWP + VEST & HELM & He Grenade & FlashBang. This menu should appear for flag H , and as well to be on tabscore "V.I.P" instead of "Dead/Bomb" ,and if it's possible,flag "h". 100$ per kill and, 200$ per headshot , to be more special..
-
OciXCrom TM
- Администратор
- Мнения: 4970
- Регистриран: 06 окт 2016, 19:20
- Местоположение: /resetscore
- Се отблагодари: 53 пъти
- Получена благодарност: 445 пъти
- Години: 21
- Контакти:
VIP Plugin.
Not tested.
Код: Избери всички
#include <amxmodx>
#include <cstrike>
#include <fun>
#include <hamsandwich>
const VIP_FLAG = ADMIN_CFG
const ARMOR_AMOUNT = 100
const MONEY_PER_KILL = 100
const MONEY_PER_HS = 200
const MONEY_MAX = 16000
new g_iMenu
public plugin_init()
{
register_plugin("VIP Menu & Extras", "1.0", "OciXCrom")
RegisterHam(Ham_Spawn, "player", "OnPlayerSpawn", 1)
register_message(get_user_msgid("ScoreAttrib"), "OnScoreAttrib")
register_event("DeathMsg", "OnPlayerKilled", "a")
CreateMenu()
}
CreateMenu()
{
g_iMenu = menu_create("VIP Menu", "VIPMenu_Handler")
menu_additem(g_iMenu, "AK47 + Deagle + HE + Flash + Vesthelm")
menu_additem(g_iMenu, "M4A1 + Deagle + HE + Flash + Vesthelm")
menu_additem(g_iMenu, "AWP + Deagle + HE + Flash + Vesthelm")
}
public OnScoreAttrib(iMsgId, iDest, iReceiver)
{
if(has_access(get_msg_arg_int(1)))
set_msg_arg_int(2, ARG_BYTE, (1<<2))
}
public OnPlayerSpawn(id)
{
if(!is_user_alive(id) || !has_access(id))
return
menu_display(id, g_iMenu)
}
public VIPMenu_Handler(id, iMenu, iItem)
{
if(iItem == MENU_EXIT || !is_user_alive(id))
{
menu_cancel(id)
return
}
new iC4 = cs_get_user_plant(id)
strip_user_weapons(id)
give_item(id, "weapon_knife")
give_item(id, "weapon_deagle")
give_item(id, "weapon_hegrenade")
give_item(id, "weapon_flashbang")
cs_set_user_bpammo(id, CSW_DEAGLE, 35)
cs_set_user_armor(id, ARMOR_AMOUNT, CS_ARMOR_VESTHELM)
if(iC4)
{
give_item(id, "weapon_c4")
cs_set_user_plant(id)
}
switch(iItem)
{
case 0:
{
give_item(id, "weapon_ak47")
cs_set_user_bpammo(id, CSW_AK47, 90)
}
case 1:
{
give_item(id, "weapon_m4a1")
cs_set_user_bpammo(id, CSW_M4A1, 90)
}
case 2:
{
give_item(id, "weapon_awp")
cs_set_user_bpammo(id, CSW_AWP, 90)
}
}
}
public OnPlayerKilled()
{
new iAttacker = read_data(1), iVictim = read_data(2)
if(!is_user_connected(iAttacker) || iAttacker == iVictim || !has_access(iAttacker))
return
cs_set_user_money(iAttacker, clamp((cs_get_user_money(iAttacker) + (read_data(3) ? MONEY_PER_HS : MONEY_PER_KILL)), .max = MONEY_MAX))
}
bool:has_access(id)
return bool:(get_user_flags(id) & VIP_FLAG)
-
addryann
- Foreigner
- Мнения: 13
- Регистриран: 10 фев 2019, 22:52
VIP Plugin.
i don't have that VIP on tabscore..i have to test if i receive the money for kills. 100$ per kill, 200$ per hs
-
OciXCrom TM
- Администратор
- Мнения: 4970
- Регистриран: 06 окт 2016, 19:20
- Местоположение: /resetscore
- Се отблагодари: 53 пъти
- Получена благодарност: 445 пъти
- Години: 21
- Контакти:
VIP Plugin.
VIP in scoreboard works only for Counter-Terrorists. Don't worry, both things are there.
-
addryann
- Foreigner
- Мнения: 13
- Регистриран: 10 фев 2019, 22:52
VIP Plugin.
Could you set up the menu after three rounds of play? Thank you very much.
PS: if i put for someone flag "H" they can't write anymore on "Y" ? why ?
PS: if i put for someone flag "H" they can't write anymore on "Y" ? why ?
-
OciXCrom TM
- Администратор
- Мнения: 4970
- Регистриран: 06 окт 2016, 19:20
- Местоположение: /resetscore
- Се отблагодари: 53 пъти
- Получена благодарност: 445 пъти
- Години: 21
- Контакти:
VIP Plugin.
Once every three rounds or every round after the third one?
The writing thing has nothing to do with this plugin.
The writing thing has nothing to do with this plugin.
-
addryann
- Foreigner
- Мнения: 13
- Регистриран: 10 фев 2019, 22:52
-
OciXCrom TM
- Администратор
- Мнения: 4970
- Регистриран: 06 окт 2016, 19:20
- Местоположение: /resetscore
- Се отблагодари: 53 пъти
- Получена благодарност: 445 пъти
- Години: 21
- Контакти:
VIP Plugin.
Код: Избери всички
#include <amxmodx>
#include <cstrike>
#include <fun>
#include <hamsandwich>
const VIP_FLAG = ADMIN_CFG
const ARMOR_AMOUNT = 100
const MONEY_PER_KILL = 100
const MONEY_PER_HS = 200
const MONEY_MAX = 16000
const ACTIVE_ROUND = 3
new g_iMenu, g_iRound
public plugin_init()
{
register_plugin("VIP Menu & Extras", "1.1", "OciXCrom")
RegisterHam(Ham_Spawn, "player", "OnPlayerSpawn", 1)
register_message(get_user_msgid("ScoreAttrib"), "OnScoreAttrib")
register_event("DeathMsg", "OnPlayerKilled", "a")
register_logevent("OnRoundStart", 2, "0=World triggered", "1=Round_Start")
register_logevent("OnFirstRound", 2, "0=World triggered", "1&Restart_Round_")
register_logevent("OnFirstRound", 2, "0=World triggered", "1=Game_Commencing")
CreateMenu()
}
public OnFirstRound()
g_iRound = 0
public OnRoundStart()
g_iRound++
CreateMenu()
{
g_iMenu = menu_create("VIP Menu", "VIPMenu_Handler")
menu_additem(g_iMenu, "AK47 + Deagle + HE + Flash + Vesthelm")
menu_additem(g_iMenu, "M4A1 + Deagle + HE + Flash + Vesthelm")
menu_additem(g_iMenu, "AWP + Deagle + HE + Flash + Vesthelm")
}
public OnScoreAttrib(iMsgId, iDest, iReceiver)
{
if(has_access(get_msg_arg_int(1)))
set_msg_arg_int(2, ARG_BYTE, (1<<2))
}
public OnPlayerSpawn(id)
{
if(!is_user_alive(id) || !has_access(id) || g_iRound != ACTIVE_ROUND)
return
menu_display(id, g_iMenu)
}
public VIPMenu_Handler(id, iMenu, iItem)
{
if(iItem == MENU_EXIT || !is_user_alive(id) || g_iRound != ACTIVE_ROUND)
{
menu_cancel(id)
return
}
new iC4 = cs_get_user_plant(id)
strip_user_weapons(id)
give_item(id, "weapon_knife")
give_item(id, "weapon_deagle")
give_item(id, "weapon_hegrenade")
give_item(id, "weapon_flashbang")
cs_set_user_bpammo(id, CSW_DEAGLE, 35)
cs_set_user_armor(id, ARMOR_AMOUNT, CS_ARMOR_VESTHELM)
if(iC4)
{
give_item(id, "weapon_c4")
cs_set_user_plant(id)
}
switch(iItem)
{
case 0:
{
give_item(id, "weapon_ak47")
cs_set_user_bpammo(id, CSW_AK47, 90)
}
case 1:
{
give_item(id, "weapon_m4a1")
cs_set_user_bpammo(id, CSW_M4A1, 90)
}
case 2:
{
give_item(id, "weapon_awp")
cs_set_user_bpammo(id, CSW_AWP, 90)
}
}
}
public OnPlayerKilled()
{
new iAttacker = read_data(1), iVictim = read_data(2)
if(!is_user_connected(iAttacker) || iAttacker == iVictim || !has_access(iAttacker))
return
cs_set_user_money(iAttacker, clamp((cs_get_user_money(iAttacker) + (read_data(3) ? MONEY_PER_HS : MONEY_PER_KILL)), .max = MONEY_MAX))
}
bool:has_access(id)
return bool:(get_user_flags(id) & VIP_FLAG)
Кой е на линия
Потребители, разглеждащи този форум: Няма регистрирани потребители и 1 гост