RSSy MYGO.pl Opublikowano Grudzień 20, 2022 o 16:00 RSSy Udostępnij Opublikowano Grudzień 20, 2022 o 16:00 Hello, I am asking for a plugin so that when the players enter the CSDM-server/respawn, they automatically receive only these 4 things: -ak47/m4a1 for: terrorist/counterterrorist - as primary weapon; - AWP - for both teams - as a secondary weapon; -deagle - for both teams - instead of the knife; - HE-grenade automaticaly - for both teams; Currently, on my server I use a slightly edited by me, OcixChrome plugin with which players get: - AVP for both teams - as a primary weapon -deagle for both teams -instead of the knife ak47 and m4a1 are gone, as well as the HE-grenade. I am attaching the plugin, and if possible or easier it can be edited so that the above condition is met. But, if necessary, please write a new plugin. Thanks for understanding and sorry for my bad English. HTML Code: #include <amxmodx> #include <cstrike> #include <engine> #include <fun> #include <hamsandwich> #define PLUGIN_VERSION "1.1" enum _:Cvars { autoawp_ammo, autoawp_knife, autoawp_health, autoawp_armor, autoawp_block_drop } new g_eCvars[Cvars] new const g_szEntities[][] = { "player_weaponstrip", "game_player_equip", "armoury_entity" } public plugin_init() { register_plugin("Auto AWP", PLUGIN_VERSION, "OciXCrom") register_cvar("CRXAutoAWP", PLUGIN_VERSION, FCVAR_SERVER|FCVAR_SPONLY|FCVAR_UNLOGGED) RegisterHam(Ham_Spawn, "player", "OnPlayerSpawn", 1) register_clcmd("drop", "OnWeaponDrop") g_eCvars[autoawp_ammo] = register_cvar("autoawp_ammo", "30") g_eCvars[autoawp_knife] = register_cvar("autoawp_knife", "1") g_eCvars[autoawp_health] = register_cvar("autoawp_health", "-1") g_eCvars[autoawp_armor] = register_cvar("autoawp_armor", "-1") g_eCvars[autoawp_block_drop] = register_cvar("autoawp_block_drop", "1") for(new i, iEnt = -1; i < sizeof(g_szEntities); i++) { iEnt = -1 while((iEnt = find_ent_by_class(iEnt, g_szEntities[i]))) { if(is_valid_ent(iEnt)) remove_entity(iEnt) } } } public OnPlayerSpawn(id) { if(!is_user_alive(id)) return strip_user_weapons(id) if(get_pcvar_num(g_eCvars[autoawp_knife])) give_item(id, "weapon_deagle") static iAmmo, iHealth, iArmor iAmmo = get_pcvar_num(g_eCvars[autoawp_ammo]) iHealth = get_pcvar_num(g_eCvars[autoawp_health]) iArmor = get_pcvar_num(g_eCvars[autoawp_armor]) if(iAmmo == -1) { cs_set_weapon_ammo(give_item(id, "weapon_awp"), 97280) cs_set_user_bpammo(id, CSW_AWP, 0) } else { give_item(id, "weapon_awp") cs_set_user_bpammo(id, CSW_AWP, iAmmo) } if(iHealth != -1) set_user_health(id, iHealth) if(iArmor != -1) set_user_armor(id, iArmor) } public OnWeaponDrop(id) return get_pcvar_num(g_eCvars[autoawp_block_drop]) Przeczytaj cały wpis Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
Rekomendowane odpowiedzi