Skocz do zawartości

Nowy szablon forum

mygo.pl

Stworzyliśmy dla Was nowy wygląd forum. Z pewnością znajdziesz rzeczy, które wg Ciebie mogą zostać zmienione - wspomnij o tym w specjalnym wątku.

Czytaj więcej

Jak założyć własną sieć

serwerów CS

Zastanawiasz się nad prowadzeniem własnej sieci serwerów? Przeczytaj podstawowe informacje, na które należy zwrócić uwagę, przy takim projekcie.

Czytaj więcej

Tworzymy spis sieci

dodaj swoją

Dodaj sieć do której należysz, pozwoli to na promocję i budowę ogólnopolskiej bazy sieci CS.

Czytaj więcej

MYGO.pl

RSSy
  • Postów

    26222
  • Dołączył

  • Ostatnia wizyta

    nigdy
  • Wygrane w rankingu

    11

Ostatnia wygrana MYGO.pl w dniu 12 Lipca 2019

Użytkownicy przyznają MYGO.pl punkty reputacji!

O MYGO.pl

  • Urodziny 06.07.2016

Informacje o mnie

  • Imię
    RSS Plugins
  • Skąd
    RSS Plugins
  • Płeć
    Mężczyzna
  • Zawód
    RSS Plugins

Kontakt

Ostatnie wizyty

10854 wyświetleń profilu
  • GETu

  • chujnik

  • marcelo

  • sdn

  • ߯ø

Osiągnięcia MYGO.pl

Nowicjusz

Nowicjusz (1/14)

51

Reputacja

  1. Features Just simple hook of sentry gun's bullet fire. You can increase amounts of bullet or make sentry fire laser instead of firing bullet. I plan to make sub-plugins for this. Forwards PHP Code: /** * Called before CBaseEntity::FireBullets(). * * @param sentry Sentry entity index. * @param builder Sentry builder index. * @param shots Number of bullets. * @param src Start point of bullet fire. * @param dirShooting Direction of bullet fire. * @param spread Spread of bullet fire. * @param distance Distance of bullet's max reach. * @param tracerFreq Tracer Frequency. Set to 0, no bullet tracer. * @param damage Damage of per bullet. * @param playerDamage Damage to be used instead of m_flDamage if we hit a player. * @param flags See FireBulletsFlags_t. * @param damageForceScale Damage's force scale. But it doesn't seem to affect alive player? * @param attacker Attacker index. Unless it's a special situation, it is builder. If builder isn't valid, it is sentry. * @param ignoreEnt Define target who bullet will ignore. Default value is -1(none). * * @return Plugin_Stop or Plugin_Handled to block shooting bullet. * Plugin_Changed to change parameters. * Plugin_Continue is nothing happen. */ forward Action TF2_SentryFireBullet(int sentry, int builder, int &shots, float src[3], const float dirShooting[3], float spread[3], float &distance, int &tracerFreq, float &damage, int &playerDamage, int &flags, float &damageForceScale, int &attacker, int &ignoreEnt); forward void TF2_SentryFireBulletPost(int sentry, int builder, int shots, const float src[3], const float dirShooting[3], const float spread[3], float distance, int tracerFreq, float damage, int playerDamage, int flags, float damageForceScale, int attacker, int ignoreEnt); Credits - nosoop: Help dealing with in-memory structs and dhooks_gameconf_shim to avoid global hook conflicts. - AzulFlamaWallon: Gave idea to make this. Dependancy - sourcemod 1.11+ (Because it use DHooks with detour support) - stocksoup(compile only) Source code and Download: https://github.com/M60TM/TF2-Sentry-FireBullet Wyświetl pełny artykuł
  2. Tengo una pequeña duda, bueno tengo un extra item que quiero que aparezca en la categoria de la c4 es decir por ejemplo: 1 - armas primarias 2 - armas secundarias 3 - knife 4 - granadas 5 - extra item - mi extra item Esto es posible o no? Przeczytaj cały wpis
  3. I would like a plugin, so that when a player makes the first kill, a sound will be heard (if you somehow have a list of nice sounds, not necessarily FIRST KILL) and a message will appear: Jucatorul name(with green) a facut primul KILL , speram sa supravietuiasca pana la final. I mention that I used a similar plugin but deleted it. Someone ignorant offered it to me. But it appeared to every player that he made the first kill and the chat was filled with messages as I wrote above. Only the first kill on the entire map regardless of the teams. Przeczytaj cały wpis
  4. I have a server which has custom settings/plugins such as faster charging speed and I noticed while charging and pressing E (the prompt that tells you that you are too far away from survivors and can teleport to them as a ghost), the next charge will have infinite cooldown and can't charge. I don't know the exact cause of this bug but I have noticed it in my custom server and also a few other custom servers, and I haven't found any plugin relating to this. This plugin simply detects when a Charger is in the charging state and is able to press E to spawn to a random Survivor as a ghost, and then sets the cooldown to the value of convar z_charge_interval. This is my first plugin released, any feedback is appreciated :D Attached Files Get Plugin or Get Source (fixchargerteleportcooldownbug.sp - 1.7 KB) fixchargerteleportcooldownbug.smx (5.3 KB) Wyświetl pełny artykuł
  5. MYGO.pl

    RSSAOG7772

    Chào mừng mọi người đến với nhà cái AOG777 nơi phục vụ các khách hàng, đa dạng hóa thể loại, đầy đủ các chương trình hấp dẫn, phục vụ quý khách hàng một cách chu đáo và hỗ trợ nhanh nhất. Xin cảm ơn! Link Đăng ký:👇CHI TIẾT: 👇 🌐Web: https://aog7772.com/ 🌐Web: https://aog676.com/ ☎️ 𝐋𝐈Ê𝐍 𝐇Ệ 𝐓𝐄𝐋𝐄𝐆𝐑𝐀𝐌 : https://t.me/aog676cskh Wyświetl pełny artykuł
  6. About L4D2 Voice Viewer for 10+ Servers Features 1.Show who is talking (center text or hint text) 2.Limit voice time. Simple plugin but I can't find it anywhere:( I've noticed many servers with something similar, but it appears they don't restrict "open mic" players. developed for 8+ players coop server. ConVar: Spoiler // This file was auto-generated by SourceMod (v1.12.0.7043) // ConVars for plugin "l4d2_voiceviewer.smx" // Enable or Disable // - // Default: "1" l4d2_voiceviewer_enable "1" // Check interval. // - // Default: "0.5" l4d2_voiceviewer_interval "0.5" // Time limit for sending voice. // Time(s) = l4d2_voiceviewer_interval * l4d2_voiceviewer_limit // - // Default: "60" l4d2_voiceviewer_limit "60" // Time to wait for restrictions to be lifted // Time(s) = l4d2_voiceviewer_reset * l4d2_voiceviewer_limit // - // Default: "240" l4d2_voiceviewer_reset "240" // Where to print voice messages? // 0 = Disable, 2 = HintText, 4 = CenterText; Add to get all // - // Default: "2" l4d2_voiceviewer_type "2" Translations: English and Simplified Chinese. I hope someone can provide better English. Install: 1.Download the .smx file and put into your servers \addons\sourcemod\plugins folder. 2.Put the "l4d2_voiceviewer.phrases.txt" file into \addons\sourcemod\translations folder. Attached Files Get Plugin or Get Source (l4d2_voiceviewer.sp - 4.8 KB) l4d2_voiceviewer.phrases.txt (627 Bytes) Wyświetl pełny artykuł
  7. Description This plugin will set sv_alltalk cvar to 1 on round end and return to its original value when round starts Attached Files Get Plugin or Get Source (roundend_alltalk.sma - 506 Bytes) Przeczytaj cały wpis
  8. I have this VIP plugin, and on restricted maps, the menu no longer appears, but the deagle and he/ammo are still active. I would like these features to be deactivated. Thank's Code: #include amxmodx #include amxmisc #include cstrike #include fun #include hamsandwich #include engine #include fakemeta #include csx #if AMXX_VERSION_NUM < 183 #include colorchat #endif #define p. "VIP Clasic" #define v. "9.0" #define a. "Jică Măcelaru'" #define VIP_FLAG "t" #define SCOREATTRIB_VIP (1 << 2) new const Float: g_flCoords[][] = { { 0.50, 0.40 }, { 0.56, 0.44 }, { 0.60, 0.50 }, { 0.56, 0.56 }, { 0.50, 0.60 }, { 0.44, 0.56 }, { 0.40, 0.50 }, { 0.44, 0.44 } }; new const g_szBeginning[] = "Membrii VIP"; new g_Cvar[30], g_Round[33] = 0, g_JumpNum[33], bool:g_DoJump[33], g_iPosition[33], g_iSize, g_szMessage[256], SyncHudMessage, g_VipConfig[] = "vipConfig.cfg", g_VipMaps[] = "vipMaps.ini", g_File1[128], g_File2[128], bool:g_Use[33], bool:g_Menu[33], o; enum { Primary = 1, Secondary, Knife, Grenades, C4 }; public plugin_init() { register_plugin p., v., a.; register_clcmd "say", "sayCommand"; register_clcmd "say_team", "sayCommand"; g_Cvar[0] = register_cvar("vip_mode", "2"); g_Cvar[1] = register_cvar("vip_tag", "VIP"); g_Cvar[2] = register_cvar("vip_start_hp", "120"); g_Cvar[3] = register_cvar("vip_start_ap", "120"); g_Cvar[4] = register_cvar("vip_start_money", "1000"); g_Cvar[5] = register_cvar("vip_jump", "1"); g_Cvar[6] = register_cvar("vip_hp_kill", "15"); g_Cvar[7] = register_cvar("vip_ap_kill", "15"); g_Cvar[8] = register_cvar("vip_hp_hs", "20"); g_Cvar[9] = register_cvar("vip_ap_hs", "20"); g_Cvar[10] = register_cvar("vip_hp_kill_knife", "20"); g_Cvar[11] = register_cvar("vip_ap_kill_knife", "20"); g_Cvar[12] = register_cvar("vip_hp_hs_knife", "25"); g_Cvar[13] = register_cvar("vip_ap_hs_knife", "25"); g_Cvar[14] = register_cvar("vip_bulletdmg", "1"); g_Cvar[16] = register_cvar("vip_in_out", "1"); g_Cvar[17] = register_cvar("vip_show_chat", "1"); g_Cvar[18] = register_cvar("vip_show_hud", "1"); g_Cvar[19] = register_cvar("vip_maxhp", "200"); g_Cvar[20] = register_cvar("vip_maxap", "200"); g_Cvar[21] = register_cvar("vip_parachute", "0"); g_Cvar[22] = register_cvar("vip_money_kill", "400"); g_Cvar[23] = register_cvar("vip_money_hs", "600"); g_Cvar[24] = register_cvar("vip_bulletdmg_mode", "1"); g_Cvar[25] = register_cvar("vip_tab", "1"); g_Cvar[26] = register_cvar("vip_defusekit", "1"); g_Cvar[27] = register_cvar("vip_free", "1"); g_Cvar[28] = register_cvar("vip_free_start", "00"); g_Cvar[29] = register_cvar("vip_free_end", "08"); set_task 300.0, "msgInfo", _, _, _, "b"; set_task 1.0, "showVipsH", _, _, _, "b", 0; set_task 1.0, "GiveVIP" ,_,_,_, "b"; register_message get_user_msgid("ScoreAttrib"), "MessageScoreAttrib"; RegisterHam Ham_Spawn, "player", "Spawn", 1; SyncHudMessage = CreateHudSyncObj(); g_iSize = sizeof(g_flCoords); register_event "HLTV", "newRound", "a", "1=0", "2=0"; register_event "ResetHUD", "resetModel", "b"; } public plugin_cfg() { new File[64]; get_configsdir File, charsmax(File); formatex g_File1, charsmax(g_File1), "%s/%s", File, g_VipConfig; formatex g_File2, charsmax(g_File2), "%s/%s", File, g_VipMaps; if(!file_exists(g_File1)) { write_file(g_File1, "; Plugin VIP creat de Jică Măcelaru' (aka. StefaN@CS, Devil., joker`)"); write_file(g_File1, "; Plugin publicat pe www.indungi.ro/forum"); write_file(g_File1, "; https://www.indungi.ro/forum/topic/829508-vip-clasic-90-vip_clasicamxx/"); write_file(g_File1, "; Suport Counter-Strike 1.6 contra-cost"); write_file(g_File1, "; Contact"); write_file(g_File1, "; PM forum: https://www.indungi.ro/forum/profile/349550-jică-măcelaru/"); write_file(g_File1, "; Steam: https://steamcommunity.com/id/baulesscs161/"); write_file(g_File1, "; Paypal: paypal.me/sacotia"); write_file(g_File1, "; Cine considera ca l-am ajutat si ca merit. Multumesc!"); write_file(g_File1, ""); write_file(g_File1, ""); write_file(g_File1, ""); write_file(g_File1, "/////// Vip Configuration File"); write_file(g_File1, ""); write_file(g_File1, "//// VIP Mode"); write_file(g_File1, "// Setati modul de aparitie al meniului"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - meniu prin comanda /vmenu"); write_file(g_File1, "// 2 - meniu din a 3-a runda"); write_file(g_File1, "// Default: '1'"); write_file(g_File1, "vip_mode ^"2^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Tag"); write_file(g_File1, "// Setati tagul ce va aparea in chat in mesaje"); write_file(g_File1, "// Default: 'VIP'"); write_file(g_File1, "vip_tag ^"VIP^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Start"); write_file(g_File1, "// Setati viata, armura si banii cu care va incepe vipul fiecare runda"); write_file(g_File1, "// La bani setati cu cati bani in plus va incepe"); write_file(g_File1, "// EX: VIP-ul are 800 bani si la spawn i se vor mai adauga inca 1000"); write_file(g_File1, "// Default: 150, 150, 1000"); write_file(g_File1, "vip_start_hp ^"120^""); write_file(g_File1, "vip_start_ap ^"120^""); write_file(g_File1, "vip_start_money ^"1000^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP HP/AP/BANI per kill/hs"); write_file(g_File1, "// Setati cat hp/ap/bani sa primeasca vip-ul pe fiecare kill/hs facut in functie de cum este facut kill-ul/hs-ul"); write_file(g_File1, "// Default: 5, 5, 10, 10, 15, 15, 20, 20, 400, 600"); write_file(g_File1, "vip_hp_kill ^"15^""); write_file(g_File1, "vip_ap_kill ^"15^""); write_file(g_File1, "vip_hp_hs ^"20^""); write_file(g_File1, "vip_ap_hs ^"20^""); write_file(g_File1, "vip_hp_kill_knife ^"20^""); write_file(g_File1, "vip_ap_kill_knife ^"20^""); write_file(g_File1, "vip_hp_hs_knife ^"25^""); write_file(g_File1, "vip_ap_hs_knife ^"25^""); write_file(g_File1, "vip_money_kill ^"400^""); write_file(g_File1, "vip_money_hs ^"600^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Max HP/AP"); write_file(g_File1, "// Setati maximul de hp/ap pe care il poate avea vipul"); write_file(g_File1, "// Default: 200, 200"); write_file(g_File1, "vip_max_hp ^"200^""); write_file(g_File1, "vip_max_ap ^"200^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Jump"); write_file(g_File1, "// Setati cat poate sari vipul"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - 2x jump"); write_file(g_File1, "// 2 - 3x jump"); write_file(g_File1, "// 3 - 4x jump"); write_file(g_File1, "// ..."); write_file(g_File1, "// z - yx jump"); write_file(g_File1, "Default: 1"); write_file(g_File1, "vip_jump ^"1^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Parachute"); write_file(g_File1, "// Setati daca vip-ul va avea sau nu parasuta"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_parachute ^"0^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Defuse Kit (Only CT)"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_defusekit ^"1^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Show"); write_file(g_File1, "// Setati momentele in care vor fi afisati vipii"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Cand intra/iese de pe server cu mesaj in chat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_in_out ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Cand tastezi comanda /vips apare in chat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_show_chat ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Afisare in hud in coltul stang, sus"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_show_hud ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Afisare in TAB (ScoreBoard)"); write_file(g_File1, "// Default: 0"); write_file(g_File1, "vip_tab ^"0^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Bulletdamage + mode"); write_file(g_File1, "// Setati daca vipul va avea bulletdamage"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_bulletdmg ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Setati modul de aparitie al bulletdamageului"); write_file(g_File1, "// vip_bulletdmg trebuie sa fie setat pe 1"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - cerc multi color pentru ambele echipe"); write_file(g_File1, "// 2 - cerc albastru/rosu (CT - albastru / T - rosu)"); write_file(g_File1, "// 3 - centru multi color pentru ambele echipe"); write_file(g_File1, "// 4 - centru albastru/rosu (CT - albastru / T - rosu)"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_bulletdmg_mode ^"1^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Model"); write_file(g_File1, "// Setati daca vip-ul va avea model sau nu"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Daca doriti sa activati modelul, setati valoarea 1 si schimbati mapa ca sa se descarce modelele"); write_file(g_File1, "// Daca doriti sa dezactivati modelul, setati valoarea 0 si schimbati mapa ca sa nu se mai descarce modelele"); write_file(g_File1, "Default: 1"); write_file(g_File1, "vip_model ^"0^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Free"); write_file(g_File1, "// Setati daca va fi vip free sau nu pe server"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "vip_free ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Setati orele intre care va fi vip free"); write_file(g_File1, "// Ore disponibile"); write_file(g_File1, "// 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, 12"); write_file(g_File1, "// 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 00"); write_file(g_File1, "// Default: 22, 08"); write_file(g_File1, "vip_free_start ^"22^""); write_file(g_File1, "vip_free_end ^"08^""); } server_cmd "exec %s", g_File1; if(!file_exists(g_File2)) { write_file(g_File2, ";--------------- | Lista hartilor pe care meniul vipului este restrictionat | ---------------"); write_file(g_File2, ""); write_file(g_File2, ";Adaugati mapele una sub alta"); write_file(g_File2, ""); write_file(g_File2, "35hp"); write_file(g_File2, "awp_india"); write_file(g_File2, "awp_bycastor"); write_file(g_File2, "fy_snow"); write_file(g_File2, "awp_zigzag"); } } public sayCommand(id) { new Said[10]; read_args Said, charsmax(Said); remove_quotes(Said); if(equal(Said, "/vips")) showVipsC(id); else if(equal(Said, "/vip")) vipInfo(id); else if(equal(Said, "/vmenu")) if(get_pcvar_num(g_Cvar[0]) == 1) if(g_Menu[id] == true) vipMenu(id); return 0; } public client_putinserver(id) { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; set_task 2.0, "vipIn", id; g_JumpNum[id] = 0; g_DoJump[id] = false; g_Round[id] = 0; g_Use[id] = false; g_Menu[id] = true; return 1; } #if AMXX_VERSION_NUM < 183 public client_disconnect(id) #else public client_disconnected(id) #endif { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; set_task 2.0, "vipOut", id; g_JumpNum[id] = 0; g_DoJump[id] = false; g_Round[id] = 0; g_Use[id] = false; return 1; } public vipInfo(id) show_motd(id, "/addons/amxmodx/configs/vipInfo.html"); public msgInfo() { new tag[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); #if AMXX_VERSION_NUM < 183 ColorChat 0, GREEN, "^3[%s] ^1You want to buy Vip Type ^4/vip.", tag; #else client_print_color 0, print_team_default, "^3[%s] ^1You want to buy Vip Type ^4/vip.", tag; #endif } public plugin_precache() { g_Cvar[15] = register_cvar("vip_model", "0"); if(get_pcvar_num(g_Cvar[15]) == 0) return 1; precache_model "models/player/vip_tero/vip_tero.mdl"; precache_model "models/player/vip_ct/vip_ct.mdl"; return 1; } public newRound() for(new i = 0; i < 32; i++) g_Use[i] = false; public vipMenu(id) { if(!is_user_alive(id) || !(get_user_flags(id) & read_flags(VIP_FLAG)) || g_Use[id]) return 1; new menu; switch(cs_get_user_team(id)) { case CS_TEAM_T: { menu = menu_create("\r[\dVIP\r] \yPistolarii System", "Ammunition"); menu_additem menu, "AK47 + DEAGLE + GRENADE", "1"; menu_additem menu, "M4A1 + DEAGLE + GRENADE", "2"; menu_additem menu, "AWP + DEAGLE + GRENADE", "3"; } case CS_TEAM_CT: { menu = menu_create("\r[\dVIP\r] \yPistolarii System", "Ammunition"); menu_additem menu, "M4A1 + DEAGLE + GRENADE", "1"; menu_additem menu, "AK47 + DEAGLE + GRENADE", "2"; menu_additem menu, "AWP + DEAGLE + GRENADE", "3"; } } menu_display id, menu, 0; return 1; } public Ammunition(id, menu, item) { if(item == MENU_EXIT) return 1; new access, callback, data[6], szName[64], tag[32]; menu_item_getinfo(menu, item, access, data, charsmax(data), szName, charsmax(szName), callback); get_pcvar_string g_Cvar[1], tag, charsmax(tag); new key = str_to_num(data); if(cs_get_user_team(id) == CS_TEAM_T) { switch(key) { case 1: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_ak47"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AK47, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 2: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_m4a1"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_M4A1, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 3: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_awp"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AWP, 30; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } } } if(cs_get_user_team(id) == CS_TEAM_CT) { switch(key) { case 1: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_m4a1"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_M4A1, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 2: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_ak47"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AK47, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 3: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_awp"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AWP, 30; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } } } menu_destroy(menu); return 1; } public Spawn(id) { if(!is_user_alive(id) || !(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; if(get_user_team(id) == 2) { give_item(id, "item_thighpack"); } StripWeapons id, Secondary; give_item(id, "weapon_deagle"); give_item(id, "weapon_knife"); give_item(id, "weapon_hegrenade"); give_item(id, "weapon_flashbang"); cs_set_user_bpammo(id, CSW_HEGRENADE, 1); cs_set_user_bpammo(id, CSW_FLASHBANG, 2); cs_set_user_bpammo(id, CSW_DEAGLE, 35); if(get_pcvar_num(g_Cvar[0]) == 2) { if(g_Menu[id] == true) if(g_Round[id] >= 4) vipMenu(id); g_Round[id]++; } if(get_pcvar_num(g_Cvar[26]) == 1) if(cs_get_user_team(id) == CS_TEAM_CT) give_item id, "item_thighpack"; give_item id, "item_assaultsuit"; set_user_health id, get_pcvar_num(g_Cvar[2]); set_user_armor id, get_pcvar_num(g_Cvar[3]); cs_set_user_money id, clamp(cs_get_user_money(id) + get_pcvar_num(g_Cvar[4]), 0, 16000); new MapName[32], szLine[128], iLen; new Size = file_size(g_File2, 1) get_mapname(MapName, sizeof(MapName)); for(new i = 0; i < Size; i ++) { read_file(g_File2, i, szLine, charsmax(szLine), iLen); if(equali(MapName, szLine)) g_Menu[id] = false; } return 1; } public GiveVIP() { if(get_pcvar_num(g_Cvar[27]) == 1) { time(o, _, _); if(o >= get_pcvar_num(g_Cvar[28]) && o < 24 || o >= 00 && o < get_pcvar_num(g_Cvar[29])) { for(new i = 1; i <= get_maxplayers(); i++) if(is_user_connected(i) || !is_user_bot(i) || !is_user_hltv(i) || !(get_user_flags(i) & read_flags(VIP_FLAG))) set_user_flags i, read_flags(VIP_FLAG) set_hudmessage random_num(0, 255), random_num(0, 255), random_num(0, 255), -1.0, 0.02, 0, 1.0, 1.0; show_hudmessage 0, "", get_pcvar_num(g_Cvar[28]), get_pcvar_num(g_Cvar[29]); } if(o == get_pcvar_num(g_Cvar[29])) server_cmd("amx_reloadadmins"); } } public vipIn(id) { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; if(get_pcvar_num(g_Cvar[16]) == 1) { new tag[32], name[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); get_user_name id, name, charsmax(name); #if AMXX_VERSION_NUM < 183 ColorChat 0, GREEN, "^3[%s] ^4%s ^1s-a conectat pe server.", tag, name; #else client_print_color 0, print_team_default, "^3[%s] ^4%s ^1s-a conectat pe server.", tag, name; #endif } return 1; } public vipOut(id) { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; if(get_pcvar_num(g_Cvar[16]) == 1) { new tag[32], name[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); get_user_name id, name, charsmax(name); #if AMXX_VERSION_NUM < 183 ColorChat 0, GREEN, "^3[%s] ^4%s ^1s-a deconectat de pe server.", tag, name; #else client_print_color 0, print_team_default, "^3[%s] ^4%s ^1s-a deconectat de pe server.", tag, name; #endif } return 1; } public client_PreThink(id) { if(!is_user_alive(id)) return 1; new Float:fallspeed = 100.0 * -1.0; new BUTTON = get_user_button(id); new OLDBUTTON = get_user_oldbutton(id); new JUMP_VIP = get_pcvar_num(g_Cvar[5]); if((BUTTON & IN_JUMP) && !(get_entity_flags(id) & FL_ONGROUND) && !(OLDBUTTON & IN_JUMP)) { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; if(g_JumpNum[id] < JUMP_VIP) { g_DoJump[id] = true; g_JumpNum[id]++; } } if((BUTTON & IN_JUMP) && (get_entity_flags(id) & FL_ONGROUND)) g_JumpNum[id] = 0; if(get_pcvar_num(g_Cvar[21]) == 1) { if(BUTTON & IN_USE) { new Float:velocity[3]; entity_get_vector(id, EV_VEC_velocity, velocity); if(velocity[2] < 0.0) { entity_set_int id, EV_INT_sequence, 3; entity_set_int id, EV_INT_gaitsequence, 1; entity_set_float id, EV_FL_frame, 1.0; entity_set_float id, EV_FL_framerate, 1.0; velocity[2] = (velocity[2] + 40.0 < fallspeed) ? velocity[2] + 40.0 : fallspeed; entity_set_vector id, EV_VEC_velocity, velocity; } } } return 0; } public client_PostThink(id) { if(!is_user_alive(id)) return 1; if(g_DoJump[id] == true) { new Float: velocity[3]; entity_get_vector id, EV_VEC_velocity, velocity; velocity[2] = random_float(265.0, 285.0); entity_set_vector id, EV_VEC_velocity, velocity; g_DoJump[id] = false; } return 0; } public client_death(killer, victim, weapon, hitplace) { if(!(get_user_flags(killer) & read_flags(VIP_FLAG))) return 1; new VIP_MAXHP = get_pcvar_num(g_Cvar[19]); new VIP_HP = get_user_health(killer); new VIP_MAXAP = get_pcvar_num(g_Cvar[20]); new VIP_AP = get_user_armor(killer); if(!(hitplace == HIT_HEAD) && !(weapon == CSW_KNIFE)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[6]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor killer, VIP_AP + get_pcvar_num(g_Cvar[7]); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[22]), 0, 16000); } if(hitplace == HIT_HEAD && !(weapon == CSW_KNIFE)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[8]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor killer, VIP_AP + get_pcvar_num(g_Cvar[9]); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[23]), 0, 16000); } if(weapon == CSW_KNIFE && !(hitplace == HIT_HEAD)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[10]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor(killer, VIP_AP + get_pcvar_num(g_Cvar[11])); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[22]), 0, 16000); } if(weapon == CSW_KNIFE && (hitplace == HIT_HEAD)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[12]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor killer, VIP_AP + get_pcvar_num(g_Cvar[13]); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[23]), 0, 16000); } return 1; } public client_damage(iAttacker, iVictim, iDamage) { if(!(get_user_flags(iAttacker) & read_flags(VIP_FLAG))) return 1; if(get_pcvar_num(g_Cvar[14]) == 1) { if(get_pcvar_num(g_Cvar[24]) == 1) { if(++g_iPosition[iAttacker] == g_iSize) g_iPosition[iAttacker] = 0; set_hudmessage random_num(0, 255), random_num(0, 255), random_num(0, 255), Float: g_flCoords[g_iPosition[iAttacker]][0], Float: g_flCoords[g_iPosition[iAttacker]][1], 0, 0.1, 2.5, 0.02, 0.02, -1; show_hudmessage iAttacker, "%i", iDamage; } else if(get_pcvar_num(g_Cvar[24]) == 2) { if(++g_iPosition[iAttacker] == g_iSize) g_iPosition[iAttacker] = 0; if(cs_get_user_team(iAttacker) == CS_TEAM_CT) { set_hudmessage 42, 170, 255, Float: g_flCoords[g_iPosition[iAttacker]][0], Float: g_flCoords[g_iPosition[iAttacker]][1], 0, 0.1, 2.5, 0.02, 0.02, -1; show_hudmessage iAttacker, "%i", iDamage; } else if(cs_get_user_team(iAttacker) == CS_TEAM_T) { set_hudmessage 200, 0, 0, Float: g_flCoords[g_iPosition[iAttacker]][0], Float: g_flCoords[g_iPosition[iAttacker]][1], 0, 0.1, 2.5, 0.02, 0.02, -1; show_hudmessage iAttacker, "%i", iDamage; } } else if(get_pcvar_num(g_Cvar[24]) == 3) { set_hudmessage random_num(0, 255), random_num(0, 255), random_num(0, 255), -1.0, 0.5, 0, 0.0, 0.1, 0.1, 0.1; show_hudmessage iAttacker, "%i", iDamage; } else if(get_pcvar_num(g_Cvar[24]) == 4) { if(cs_get_user_team(iAttacker) == CS_TEAM_CT) { set_hudmessage 42, 170, 255, -1.0, 0.4, 0, 0.0, 2.0, 0.1, 0.1; show_hudmessage iAttacker, "%i", iDamage; } else if(cs_get_user_team(iAttacker) == CS_TEAM_T) { set_hudmessage 200, 0, 0, -1.0, 0.4, 0, 0.0, 2.0, 0.1, 0.1; show_hudmessage iAttacker, "%i", iDamage; } } } return 1; } public showVipsC(user) { if(get_pcvar_num(g_Cvar[17]) == 1) { new tag[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); new vipNames[33][32]; new message[256]; new id, count, x, len; for(id = 1 ; id <= get_maxplayers() ; id++) if(is_user_connected(id)) if(get_user_flags(id) & read_flags(VIP_FLAG)) get_user_name id, vipNames[count++], charsmax(vipNames[]); len = format(message, 255, "^3[%s] ^1VIP-ii online sunt:^4 ", tag); if(count > 0) { for(x = 0 ; x < count ; x++) { len += format(message[len], 255-len, "%s%s ", vipNames[x], x < (count-1) ? ", ":""); if(len > 96) { print_message(user, message); len = format(message, 255, " "); } } print_message(user, message); } else { #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Nu sunt ^4VIP^1-i online.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Nu sunt ^4VIP^1-i online.", tag; #endif } } return 0; } print_message(id, msg[]) { message_begin(MSG_ONE, get_user_msgid("SayText"), {0,0,0}, id); write_byte(id); write_string(msg); message_end(); } public showVipsH() { if(get_pcvar_num(g_Cvar[18]) == 1) { static iPlayers[32]; static iPlayersNum; get_players(iPlayers, iPlayersNum, "ch"); if(!iPlayersNum) return 1; static iVipsConnected, szVipsNames[128], szName[32]; formatex(szVipsNames, sizeof (szVipsNames) -1, ""); iVipsConnected = 0; static id, i; for(i = 0; i < iPlayersNum; i++) { id = iPlayers[i]; if(get_user_flags(id) & read_flags(VIP_FLAG)) { get_user_name(id, szName, sizeof(szName) -1); add(szVipsNames, sizeof(szVipsNames) -1, szName); add(szVipsNames, sizeof(szVipsNames) -1, "^n"); iVipsConnected++; } } formatex(g_szMessage, sizeof(g_szMessage) -1, "%s (%i)^n%s", g_szBeginning, iVipsConnected, szVipsNames); set_hudmessage 25, 255, 0, 0.01, 0.20, 0, 0.0, 1.0, 0.1, 0.1, -1; ShowSyncHudMsg 0, SyncHudMessage, g_szMessage; } return 0; } public resetModel(id, level, cid) { if(!is_user_alive(id) || !(get_user_flags(id) & read_flags(VIP_FLAG)) || get_pcvar_num(g_Cvar[15]) == 0) return 1; new CsTeams:userTeam = cs_get_user_team(id) if(userTeam == CS_TEAM_T) cs_set_user_model id, "vip_tero"; else if(userTeam == CS_TEAM_CT) cs_set_user_model id, "vip_ct"; else cs_reset_user_model(id); return 0; } public MessageScoreAttrib(iMsgID, iDest, iReceiver) { if(get_pcvar_num(g_Cvar[25]) == 1) { new id = get_msg_arg_int(1); if(is_user_connected(id) && (get_user_flags(id) & read_flags(VIP_FLAG)) && is_user_alive(id)) set_msg_arg_int(2, ARG_BYTE, SCOREATTRIB_VIP); } } stock StripWeapons(id, Type, bool: bSwitchIfActive = true) { new iReturn; if(is_user_alive(id)) { new iEntity, iWeapon; while((iWeapon = GetWeaponFromSlot(id, Type, iEntity)) > 0) iReturn = ham_strip_user_weapon(id, iWeapon, Type, bSwitchIfActive); } return iReturn; } stock GetWeaponFromSlot( id , iSlot , &iEntity ) { if ( !( 1 <= iSlot <= 5 ) ) return 0; iEntity = 0; const m_rgpPlayerItems_Slot0 = 367; const m_iId = 43; const XO_WEAPONS = 4; const XO_PLAYER = 5; iEntity = get_pdata_cbase( id , m_rgpPlayerItems_Slot0 + iSlot , XO_PLAYER ); return ( iEntity > 0 ) ? get_pdata_int( iEntity , m_iId , XO_WEAPONS ) : 0; } stock ham_strip_user_weapon(id, iCswId, iSlot = 0, bool:bSwitchIfActive = true) { new iWeapon if( !iSlot ) { static const iWeaponsSlots[] = { -1, 2, //CSW_P228 -1, 1, //CSW_SCOUT 4, //CSW_HEGRENADE 1, //CSW_XM1014 5, //CSW_C4 1, //CSW_MAC10 1, //CSW_AUG 2, //CSW_ELITE 2, //CSW_FIVESEVEN 1, //CSW_UMP45 1, //CSW_SG550 1, //CSW_GALIL 1, //CSW_FAMAS 2, //CSW_USP 2, //CSW_GLOCK18 1, //CSW_AWP 1, //CSW_MP5NAVY 1, //CSW_M249 1, //CSW_M3 1, //CSW_M4A1 1, //CSW_TMP 1, //CSW_G3SG1 4, //CSW_FLASHBANG 2, //CSW_DEAGLE 1, //CSW_SG552 1, //CSW_AK47 3, //CSW_KNIFE 1 //CSW_P90 } iSlot = iWeaponsSlots[iCswId] } const XTRA_OFS_PLAYER = 5 const m_rgpPlayerItems_Slot0 = 367 iWeapon = get_pdata_cbase(id, m_rgpPlayerItems_Slot0 + iSlot, XTRA_OFS_PLAYER) const XTRA_OFS_WEAPON = 4 const m_pNext = 42 const m_iId = 43 while( iWeapon > 0 ) { if( get_pdata_int(iWeapon, m_iId, XTRA_OFS_WEAPON) == iCswId ) { break } iWeapon = get_pdata_cbase(iWeapon, m_pNext, XTRA_OFS_WEAPON) } if( iWeapon > 0 ) { const m_pActiveItem = 373 if( bSwitchIfActive && get_pdata_cbase(id, m_pActiveItem, XTRA_OFS_PLAYER) == iWeapon ) { ExecuteHamB(Ham_Weapon_RetireWeapon, iWeapon) } if( ExecuteHamB(Ham_RemovePlayerItem, id, iWeapon) ) { user_has_weapon(id, iCswId, 0) ExecuteHamB(Ham_Item_Kill, iWeapon) return 1 } } return 0 } Przeczytaj cały wpis
  9. I'm looking for a plugin, but it doesn't seem to exist, the closest would be this: [INC] FTP https://forums.alliedmods.net/showthread.php?t=142850 However, it is very complex, I wanted a simpler one that could upload the file: PHP Code: new FTP_Server[] = "ftp.test.com"; new FTP_Port = 21; new FTP_User[] = "login"; new FTP_Pass[] = "pass"; new FTP_File[] = "cstrike/addons/amxmodx/data/csstats.dat" that would automatically upload the file at each end of the map. :3 Przeczytaj cały wpis
  10. Welcome. Change Your Name is a plugin that allows you to change your name in-game independently of your Steam name (and much more!). This version replaces and supercedes Set My Name, which is now considered obsolete/out-of-date. As a player, change your name to anything you would like, reset any time or see if another player has changed their name! Have the fun you deserve with options! As an admin, control the names you want to keep out of your server! Prevent players from changing their names at all! Force lock a name on a player! Rename your players with an updated rename command! Or have some fun from time to time by randomizing somebody’s name! A lot of options to keep bad actors at bay! Plugin comes with statistics and a full admin command suite for server administrators with no SRCDS access. Change Your Name has a lot of commands. Most of them sets up how the plugin behaves. Default values should work fine. You will find sm_name.cfg in cfg/sourcemod where values can be configured. ConVars sm_name_version - Displays the current version of the plugin. (1.7.0.1963) sm_name_help_enable 0/1 - Displays/Hides [NAME] This server allows name changes. Type !nhelp for more information message when players connect to the server. [Default: 1] sm_name_enable 0/1 - Enables/Disables plugin. [Default: 1] sm_cname_enable 0/1 - Enable/Disable the ability to change name. [Default: 1] sm_oname_enable 0/1 - Enable/Disable fetching the name players had when they connected to the server. [Default: 1] sm_sname_enable 0/1 - Enable/Disable fetching players Steam name. [Default: 1] sm_srname_enable 0/1 - Enable/Disable resetting to Steam name. [Default: 1] sm_name_ban_time <time in minutes> - Defines the behavior or the ban time if a player joins the server with a banned name. -2 -> Removes their name [Default] -1 -> Kicks player 0 and above -> Bans player (time in minutes) sm_name_ban_reason <reason> - Defines the kick message. [Default: [AUTO-DISCONNECT] This name is banned from being used. Please change it.] [CSGO: AUTOKICK - Banned player name detected. Please change it] sm_name_cooldown <time in seconds> - Defines the amount of time a player has to wait before being able to change their name again. Time in seconds, but formatted in MM:SS in-game. [Default: 30 seconds] sm_name_bannednames_checker 0/1 - Defines whether players names will be checked against banned_names.ini [Default: 1] sm_name_bannedids_checker 0/1 - Defines whether players SteamID will be checked against banned_id.ini [Default: 1] sm_rename_cooldown <time in seconds> - Defines how long a player will have to wait before changing their name again after an admin has renamed them. Time in seconds, but formatted in MM:SS in-game. [Default: 600 (10 minutes)] The following ConVars are for debugging purposes. When turned on, they will log information into logs/NameChanger. Please note that debugging mode will turn itself off on map end or on server restart. sm_name_debug 0/1 - Enable/Disable debug mode. [Default: 0] sm_name_debug_sound 0/1 - Enable/Disable sound notification when debug mode is enabled/disabled. [Default: 1] sm_name_debug_snd_on <sound file> - Defines the sound to use relative to the sounds folder whenever debug mode is turned on. [Default: hl1/fvox/bell.wav] [CSGO: training/bell_normal.wav] [L4D/L4D2: buttons/bell.wav] sm_name_debug_snd_off <sound file> - Defines the sound to use relative to the sounds folder whenever debug mode is turned off. [Default: hl1/fvox/beep.wav] [CSGO: buttons/combine_button_locked.wav] [L4D/L4D2: buttons/blip1.wav] Note: You may have to manually set debug sounds for the game you run this plugin on. Admin Commands sm_name_ban <name to ban> - Name to ban. Do not put white spaces — “Bananas” is valid, but “I hate bananas” is not. More information below. sm_name_unban <name to unban> - Name to unban. sm_name_banid <SteamID to ban> - SteamID to ban. It must be a Steam 2 ID format. More information below. sm_name_reload - Reloads files storing banned names and SteamIDs. sm_rename <#userid|name> <new name> - Renames a player. You must use quotes if the new name has white spaces. You must also replace playercommands.smx with the new version posted here. It disables the standard sm_rename from SM. sm_name_random <#userid|name> - Randomizes a player’s name. sm_name_force <#userid|name> <new name> - Forces a new name on a client. They will not be able to change their name through sm_name or sm_srname or even on Steam. sm_name_unforce <#userid|name> - Removes a forced locked name. nameadmin <command> [argument] - Main administration interface for plugin. Explained below. The command nameadmin allows your server administrators to view plugin statistics, such as overall number of name changes, resets, queries, etc. In addition to plugin statistics, you can also check individual player statistics, providing the same amount of information. Finally, it allows them to restart the plugin should the plugin run into issues for any reason.nameadmin - Displays the available commands. nameadmin cmd - Displays arguments you can use with “cmd”. nameadmin cmd list - Displays a list of available cmds. nameadmin cmd <cmd name|#cmd> - Displays info on a specific cmd. nameadmin cvar - Displays arguments you can use with “cvar”. nameadmin cvar list - Displays a list of available cvar. nameadmin cvar <cvar name|#cvar> - Displays info on a specific cvar. nameadmin plugin - Displays the arguments you can use with “plugin”. nameadmin plugin info - Displays general plugin info. nameadmin plugin stats - Displays precise plugin statistics. nameadmin plugin reload - Reloads the plugin the same way sm plugins reload <file> would. Please note that this wipes previously stored information in memory and thereby, will prevent players from using the plugin until the map has reloaded/changed. nameadmin plugin reload map_reload - Reloads the plugin the same way sm plugins reload <file> would and reloads the map to refresh information stored in memory. Note: Anytime the plugin is unloaded or reloaded, the latest statistics are printed into the server console and dumped into Sourcemod's logs. nameadmin player - Displays the arguments you can use with “player”. nameadmin player status - Displays all the connected players in a list with necessary information. nameadmin player status <#userid|name> - Displays player name statistics. nameadmin credits - Displays detailed credits listing. nameadmin version - Displays detailed plugin version. The following is taken from banned_names_example.ini. Check this file again if you need to review instructions. Code: Adding banned names manually to file instructions: To add a name, simply type the name you want to have banned. YOU MUST ADD A NEW BLANK LINE AFTER THE LAST NAME! NAMES CANNOT HAVE WHITE SPACES! Banned names will be read on server restart, next map or by manually reloading files through sm_name_reload. A banned name means that if the banned name is found anywhere in somebody's player name, the entire name gets removed (or the player is kicked based on your server settings) i.e. if you ban the name "Apple", if a player is named "Apple is the best fruit", the entire name will be removed (or the player will be kicked). Be careful with the names you ban as this could quickly lead to undesired effects. MAXIMUM NUMBER OF BANNED NAMES IS 255! ADMINS ARE IMMUNE TO NAME BANS! EXAMPLES: Valid examples: Snowflake Sucker Clown Invalid example (DO NOT DO THIS): I hate bananas -> Invalid due to white spaces used Do not add any comment behind a name, as this will mess the file up if you use sm_name_unban later on, plus, there is no guarantee the name will be read properly. Play it safe.The following is taken from banned_ids_example.ini. Check this file again if you need to review instructions. Code: READ THIS FILE CAREFULLY, AS IT EXPLAINS HOW TO USE IT AND HOW BANNED STEAM IDS ARE STORED. To add a Steam ID, simply type the Steam ID in a Steam 2 ID format (beginning with STEAM_0:). YOU MUST ADD A NEW BLANK LINE AFTER THE LAST STEAM ID! DO NOT ADD ANY EXTRA INFORMATION BEHIND THE STEAM ID! Banned Steam IDs will be read on server restart, next map or by manually reloading files through sm_name_reload. MAXIMUM NUMBER OF BANNED STEAM IDs IS 255! ADMINS ARE IMMUNE TO STEAM ID BANS! EXAMPLES: STEAM_0:1:012345678 STEAM_0:1:876543210 Again, do not add any comment behind a SteamID. It is common to add the name that is tied to the SteamID, but this will mess the file up if you use sm_name_unbanid later on, plus, there is no guarantee the SteamID will be read properly. Play it safe.Public Commandssm_name <new name> - Change your name to a new name. Quotes are NOT required. sm_oname <#userid|name> - Fetches the name a player had when they connected to the server. sm_sname <#userid|name> - Fetches the Steam name of a player. sm_srname - Resets your current name to your Steam name. sm_nhelp - Prints public commands to the console. sm_name_credits - Prints credits listing to the console. This plugin does not require any third-party plugins or extensions to function, except for Half-Life 2: Deathmatch. ============================================= FOR HL2DM USERS: YOU MUST INSTALL player model fix plugin to fix a bug with cl_playermodel. ============================================= Plugin can be automatically updated through Updater by GoD-Tony, but it is not required for this plugin to function. For developers If you need to recompile the plugin for any reason, the only include that is not Sourcemod standard issued is Unix time. To install this plugin:Download the ZIP in the attachment below. Extract the ZIP anywhere you would like. Inside the Plugins folder, you will find a number of folders corresponding to some games. As their names suggest: For Counter-Strike: Global Offensive -> Open folder Counter-Strike Global Offensive and copy the contents inside of it into your Counter-Strike Global Offensive's SRCDS directory (e.g. C:\SteamCMD\csgo\csgo) For Half-Life 2: Deathmatch -> Open folder Half-Life 2: Deathmatch and copy the contents inside of it into your Half-Life 2: Deathmatch's SRCDS directory (e.g. C:\SteamCMD\hl2mp\hl2mp) For Left 4 Dead 1 and 2 -> Open folder Left 4 Dead 1 & 2 and copy the contents inside of it into your Left 4 Dead's or Left 4 Dead 2's SRCDS directory (e.g. C:\SteamCMD\l4d\l4d) For all other Source engine games not listed above, open folder General and copy the contents inside of it into your game's SRCDS directory of your choice:For Counter-Strike: Source -> e.g. C:\SteamCMD\css\cstrike For Team Fortress 2 -> e.g. C:\SteamCMD\tf2\tf Etc. If you would like a no color version (no colored text in chat), copy and paste the contents from folder General No Color into your game’s SRCDS directory of your choice. Tested games Counter-Strike: Global Offensive Counter-Strike: Source Half-Life 2: Deathmatch Left 4 Dead 2 Team Fortress 2 Note: Despite my best efforts, I could not test the plugin on Left 4 Dead 1. I was stuck on the loading screen when connecting to my server, and it would not budge. That or I would get a black screen. If this is anything to go by, Left 4 Dead 2 was working fine for me, so did the plugin, so I will assume it is working fine in Left 4 Dead 1 as well. If not, let me know what is going on. Please make sure to use the correct version for the game you run a SRCDS server for. Failsafes are in place to ensure that. Do not try to use the no color version on CSGO, HL2DM or L4D as they will not work. It is possible to create a no color version for those games if there is demand for it. Plugin latest compile: 09/26/23 Plugin latest version: 1.7.0.1963 Compiled on Sourcemod version: 1.11.0.6936 Plugin tested on local servers running: Windows 10 x64 Linux status: Unknown MacOS status: Unknown This plugin will not run on previous versions of Sourcemod. It is unknown if plugin runs fine or at all on 1.12.0.7047 Counter-Strike: Global Offensive Spoiler Counter-Strike: Source Spoiler Half-Life 2: Deathmatch Spoiler Left 4 Dead 2 Spoiler Team Fortress 2 Spoiler Latest plugin statistics dumped on plugin unload/reloaded in the SRCDS dedicated console Spoiler Before posting, make sure that:You are using the latest stable build of Sourcemod. That the problem is clearly from this plugin and not another one. If conflicts arise from another plugin, let me know, and I will look into solutions. That the issue can be consistently reproduced. If you run into issues with the plugin:Turn on debug mode and see what is happening. Restart server. Reinstall plugin. If all fails, for the best possible assistance, provide your Sourcemod version, screenshots/videos of the issue(s), steps to reproduce. It is possible that if you rename a player while he is on cooldown after using !name or srname, some seconds might be skipped on the admin rename cooldown. It is recommended to keep sm_name_cooldown to a low value (default is 30 seconds, which is best for most servers) and sm_rename_cooldown to at least 300 seconds (5 minutes) (default 600 seconds — 10 minutes). Add sm_name_reset <#userid|name> - Resets a player’s name to their Steam name. Currently did not feel like adding it, because it is the same as doing !sname <#userid|name> and !rename <#userid|name> <new name>, even if currently, it requires 2 commands. Add sm_name_history <#userid|name> to display their latest names used. Create a separate plugin version with MySQL support (pretty large thing to do, no guarantee it will ever be made if there is no demand for it). sm_permaname <new name> - Sets a name and will be set every time a player joins the server. sm_permaname_remove - To remove a permanently set name. Allow for customizing the tag. This is so that servers can be more homogenous when other plugins are used. Allow for customizing colors. Q: Can this run on Source 2? A: Unknow at this time. I would like to wait and see where Counter-Strike 2 is headed before making large decisions. Q: There is a game I want to run this on, but it does not work. A: If it is running on Source, name the game. I will definitely look into it to make it compatible if I can. Q: Can you make this available on AMX? A: Unlikely. Q: What is the difference between !oname and !sname anyway? Why not use one? A: They both differ in their own way. When you connect to the server, your name you connect with is stored in memory. If you change your Steam name, that name that was stored does not change. This could still be useful for admins for catching bad actors who joined with a bad name for example. !sname will always fetch the Steam name you currently have. Q: Plugin is conflicting with plugin X. Can you fix it? A: Depends on the nature of this conflict. If it is caused by my plugin, then I will look into it. Q: Can you add feature X? A: Maybe. If the feature makes sense for this plugin, I might consider it for a future update. Q: Why does HL2DM require an extra plugin? Could it not work without it? A: It can technically work without the player model fixer, but you would be running into issues with servers that have mp_teamplay set to 1. As a precaution, you need to use the player model fix. Q: Could you make a feature where a player cannot take the name used by another player? Can you make VIP names? A: I looked into it, but concluded this is too risky to implement and here is why. Player names are not unique and if I start doing things like preventing a player from using a name, because another is using the same name, it is going to cause a huge conflict in the long run, even as an option you could enable/disable. Q: Can you adapt the plugin for my server? A: If I start doing this, I am probably never going to see the end of it. One of the major goals of this plugin was to provide options. If it is lacking something you want, post a suggestion below. Q: Why does your code look horrible? A: I am not an experienced Sourcemod coder and this is my first large project so to speak. I continued off of the previous code that I had made back 2018, when I was learning Sourcemod from scratch. I would like to re-visit this in the future and optimize the code. Right now, things work as they should. Q: I use Updater by GoD-Tony, do I need to download new versions here as they release? A: No. I will ensure that if you use Updater, you will not have to worry about manually updating anything. Q: Is there a more minimalistic version? A: There is always eyal282’s version at your disposal. I can eventually look into providing individual modules if there is enough demand for it. Q: Do you have a Github repository? A: Yes! Plugins can be found on Github here. Attached Files Plugins.zip (418.2 KB) Wyświetl pełny artykuł
  11. Simple connect status for Half-Life 2: Deathmatch Description Provides basic messages when a client is connecting, put in server and disconnected (including disconnect reason). Default engine messages look like garbage and this enhances the gaming experience without printing additional useless information. Additionally, changing mp_teamplay will automatically reload the map for you. Some messages do not need to show if team play is on, plus, you earn a few seconds anyway. Best used with Player Model Fix for Half-Life 2: Deathmatch. ConVars sm_connect_status_version - Plugin version sm_connect_status_enable - Enable/Disable plugin Additional information Plugin uses Updater by GoD-Tony. It is not required to have it for this plugin to run, but you will not have to manually update files. Known issues None that I know of. If you experience issues, let me know what happened and steps to reproduce if possible. Any screenshots/demos are welcome additions. To do Nothing. Screenshot Spoiler Attached Files [HL2MP] Connect Status.zip (8.2 KB) Wyświetl pełny artykuł
  12. Player Model Fix for Half-Life 2: Deathmatch Description This plugin fixes an issue where cl_playermodel does not get updated whenever players switches from one team to another. Added bonus, team changes are now shown with colors. It also fixes the "Player has joined team Unassigned" with something that makes more sense if mp_teamplay is set to 0. Please note that this does not fix the broken options from the menu. This is client side and a plugin will not be able to fix this. It is recommended to use this client side fix in addition to this plugin for the best possible experience. ConVars sm_name_playermodel_version - Plugin version sm_playermodel_fix - Enable/Disable fix sm_name_playermodel_msg - Whether to show message that player model was adjusted based on team (this is server wide) Public Commands sm_show_playermodel_msg <0|1> - Whether players wants to see the "Adjusting your cl_playermodel setting to match your team." message. Additional information Plugin uses Updater by GoD-Tony. It is not required to have it for this plugin to run, but you will not have to manually update files. Known issues None that I know of. If you experience issues, let me know what happened and steps to reproduce if possible. Any screenshots/demos are welcome additions. To do Nothing. Screenshots With teamplay on: Spoiler With teamplay off: Spoiler Attached Files [HL2MP] Player Model Fix.zip (13.0 KB) Wyświetl pełny artykuł
  13. Hello Can someone remove the mandatory registration system for this episode? Many players do not know how to register or forget their password PHP Code: #include <amxmodx> #include <amxmisc> #include <engine> #include <fakemeta> public mainMenuAccount(id){ if(!is_user_connected(id)) return; new gText[256]; new hidePass[12]; copy(hidePass, sizeof(userPassword[])-1, userPassword[id]); for(new i = 0; i < strlen(hidePass); i ++){ if (i % 3 || i < 2) hidePass[i] = '*'; } new hideIp[32]; copy(hideIp, sizeof(userIp[])-1, userIp[id]); for(new i = 0; i < strlen(hideIp); i ++){ if (i % 3 || i < 2) hideIp[i] = '*'; } if(!userLogged[id] && strlen(userPassword[id]) > 1){ format(gText, sizeof(gText), "\r[BaseBuilder]\y System Kont:^n\wZaloguj sie aby kozystac z konta^n"); } else { if( 1 >= strlen(userPassword[id])){ format(gText, sizeof(gText), "\r[BaseBuilder]\y System Kont:^n\wZarejestruj sie aby kozystac z konta^n"); } else { format(gText, sizeof(gText), "\r[BaseBuilder]\y System Kont:^n^n\ \dWitaj\y [\r%s\y]\d Tutaj znajdziesz ustawienia do swojego konta!^n^n\ \y%s^t^t\dTwoj Sid:\r %s^n\y%s^t^t\dTwoje ip:\r %s^n\y%s^t^t\dTwoje Haslo:\r %s", userName[id], symbolsCustom[SYMBOL_DR_ARROW], userSid[id],symbolsCustom[SYMBOL_DR_ARROW], hideIp, symbolsCustom[SYMBOL_DR_ARROW], hidePass); } } new menu = menu_create(gText, "mainMenuAccount_2"); if(!userLogged[id] && strlen(userPassword[id]) > 1){ format(gText, sizeof(gText), "Zaloguj"); } else { if( 1 >= strlen(userPassword[id])) format(gText, sizeof(gText), "Zarejestruj"); else format(gText, sizeof(gText), "Zmien haslo"); } menu_additem(menu, gText); if(playerLogged(id)){ menu_additem(menu, "Wyloguj Sie"); menu_additem(menu, "Ustawienia^n"); new szSavedIP[MAXBITIP], szSavedSID[MAXBITAUTHID]; get_user_ip(id, szSavedIP, sizeof(szSavedIP)-1, 1); get_user_authid(id, szSavedSID, sizeof(szSavedSID)-1); if( equal(szSavedIP, userIp[id] ) && equal(szSavedSID, userSid[id] ) ) menu_additem(menu, "\rAutomatyczne Logowanie"); else menu_additem(menu, "\yAutomatyczne Logowanie\d |\w Wylaczone"); } menu_display(id,menu,0); } public mainMenuAccount_2(id, menu, item){ if( item == MENU_EXIT ){ menu_destroy(menu); return PLUGIN_HANDLED; } switch(item){ case 0: cmd_execute(id, "messagemode Haslo"); case 1:{ if( !playerLogged(id) ){ mainMenuAccount(id); return PLUGIN_HANDLED; } userLogged[id] = false; logBB(id, LOG_ACCOUNT, "logout", "wylogowal sie !!"); chatPrint(id, PREFIX_NORMAL, "Wylogowales sie!" ); } case 2:{ settingAccount(id); } case 3:{ if(userLogged[id]){ new szSavedIP[MAXBITIP], szSavedSID[MAXBITAUTHID]; get_user_ip(id, szSavedIP, sizeof(szSavedIP)-1, 1); get_user_authid(id, szSavedSID, sizeof(szSavedSID)-1); if(equal(szSavedIP, userIp[id] ) && equal(szSavedSID, userSid[id] ) ){ chatPrint(id, PREFIX_LINE, "Masz juz wlaczone^3 Automatyczne^1 Logowanie!"); mainMenuAccount(id); return PLUGIN_CONTINUE; } logBB(id, LOG_ACCOUNT, "update", "wlaczyl automatyczne logowanie! (IP: %s | SID: %s)", userIp[id], userSid[id]); chatPrint(id, PREFIX_LINE, "Zaktualizowales swoje^3 Automatyczne^1 Logowanie!"); new ip[MAXBITIP], sid[MAXBITAUTHID]; get_user_ip(id, ip, sizeof(ip)-1, 1); get_user_authid(id, sid, sizeof(sid)-1); userIp[id] = ip; userSid[id] = sid; mainMenuAccount(id); } } default: return PLUGIN_CONTINUE; } return PLUGIN_HANDLED; } public readPassword(id){ new szArg[12]; read_argv(1, szArg, sizeof(szArg)); replace_all(szArg, sizeof(szArg), "^"", ""); replace_all(szArg, sizeof(szArg), " ", ""); if( strlen(szArg) < 3 ){ chatPrint(id, PREFIX_NORMAL, "Podane haslo jest za krotkie^3 ( Limit 11 symboli )" ); mainMenuAccount(id); return PLUGIN_CONTINUE; } if( strlen(szArg) > 11 ){ chatPrint(id, PREFIX_NORMAL, "Podane haslo jest zadlugie" ); mainMenuAccount(id); return PLUGIN_CONTINUE; } if (!userLogged[id] && strlen(userPassword[id]) > 1){ if( equal(szArg, userPassword[id]) ){ userLogged[id]=true; logBB(id, LOG_ACCOUNT, "succes", "zalogowal sie, uzyl - [Aktualne haslo: %s]", szArg); chatPrint(id, PREFIX_NORMAL, "Zalogowano pomyslnie" ); mainMenuAccount(id); }else{ logBB(id, LOG_ACCOUNT, "fail", "bledne haslo !! [Wpisal: %s][Aktualne haslo: %s]",szArg, userPassword[id]); chatPrint(id, PREFIX_NORMAL, "Podales zle haslo:^3 %s", szArg ); } } else { userLogged[id]=true; chatPrint(id, PREFIX_NORMAL, "Ustawiles haslo:^4 %s", szArg ); logBB(id, LOG_ACCOUNT, "change", "ustawil [Haslo: %s]", szArg); copy(userPassword[id], sizeof(userPassword[]), szArg); mainMenuAccount(id); } return PLUGIN_CONTINUE; } public settingAccount(id){ if(!is_user_connected(id)) return; new gText[64]; format(gText, sizeof(gText), "\r[BaseBuilder]\y Ustawienia Kont:"); new menu = menu_create(gText, "settingAccount_2"); menu_additem(menu, "Ustawienia Hudu"); format(gText, sizeof(gText), "JetPack Speed:\r %d", userJetpackSpeed[id]); menu_additem(menu, gText); format(gText, sizeof(gText), "Rendering: %s", userMoverBlockColor[id] == BLOCK_COLOR ? "\rKolor" : userMoverBlockColor[id] == BLOCK_RENDER ? "\yRendering" : "\dTekstura"); menu_additem(menu, gText); format(gText, sizeof(gText), "Modele Kosy: %s", hasOption(userSaveOption[id], save_MODELS) ? "\rWlaczone" : "\dWylaczone"); menu_additem(menu, gText); if(userFov[id] == 90) format(gText, sizeof(gText), "Fov Broni:\y Normalny^n"); else format(gText, sizeof(gText), "Fov Broni:\r %d^n", userFov[id]); menu_additem(menu, gText); //format(gText, sizeof(gText), "Wiadomosci Kopalni: %s", hasOption(userSaveOption[id], save_CAVE) ? "\rWlaczone" : "\dWylaczone"); //menu_additem(menu, gText); format(gText, sizeof(gText), "Ludzie: %s", hasOption(userSaveOption[id], save_INVIS) ? "\rWlaczone" : "\dWylaczone"); menu_additem(menu, gText); format(gText, sizeof(gText), "Widok z trzeciej osoby: %s", userViewCamera[id] ? "\rWlaczone" : "\dWylaczone"); menu_additem(menu, gText); menu_display(id, menu, 0); return; } public settingAccount_2(id, menu, item){ if( item == MENU_EXIT){ menu_destroy(menu); return PLUGIN_CONTINUE; } switch(item){ case 0: { changeHud(id); } case 1:{ if ((userJetpackSpeed[id] += 100) > 1000) userJetpackSpeed[id] = 100; settingAccount(id); } case 2:{ userMoverBlockColor[id] = (userMoverBlockColor[id]+1) % 3; settingAccount(id); } case 3:{ if( hasOption(userSaveOption[id], save_MODELS) ){ removeOption(userSaveOption[id], save_MODELS); chatPrint(id, PREFIX_LINE, "Modele do kosy^3 wlaczone"); }else{ addOption(userSaveOption[id], save_MODELS); chatPrint(id, PREFIX_LINE, "Modele do kosy^3 wylaczone"); } settingAccount(id); } case 4:{ if(cs_get_user_zoom(id) == CS_SET_AUGSG552_ZOOM || cs_get_user_zoom(id) == CS_SET_FIRST_ZOOM || cs_get_user_zoom(id) == CS_SET_SECOND_ZOOM){ chatPrint(id, PREFIX_LINE, "Wylacz^3 ZOOM'a^1 aby zmienic^3 FOV'a"); settingAccount(id); return PLUGIN_CONTINUE; } if ((userFov[id] += 5) > 150 || userFov[id] < 90) userFov[id] = 90; setFov(id, userFov[id]); settingAccount(id); } case 5:{ if( hasOption(userSaveOption[id], save_INVIS) ){ removeOption(userSaveOption[id], save_INVIS); chatPrint(id, PREFIX_LINE, "Widzenie osob wlaczone"); }else{ addOption(userSaveOption[id], save_INVIS); chatPrint(id, PREFIX_LINE, "Widzenie osob wylaczone"); } settingAccount(id); } case 6:{ userViewCamera[id] =! userViewCamera[id]; if(userViewCamera[id]) set_view(id,CAMERA_3RDPERSON); else set_view(id, CAMERA_NONE); settingAccount(id); } } return PLUGIN_CONTINUE; } public startLogin(id){ id -= TASK_LOGIN; if( !is_user_connected(id) ) return; if(!playerLogged(id)){ if(!is_user_hltv(id)){ userSpeedAdmin[id] = 1000.0; if(!userWarningHudStart[id]){ Display_Fade(id, 4096,4096, 4096,1, 1, 1,255); set_dhudmessage(255, 102, 0, -1.0, 0.2, 0, 0.5, 0.9, 0.5, 0.5); if( strlen(userPassword[id]) < 2 ) show_dhudmessage(id, "[ Zarejestruj Sie ]^n[ Wpisz /konto | /zarejestruj ]"); else show_dhudmessage(id, "[ Zaloguj Sie ]^n[ Wpisz /konto | /login ]"); } } else { new szCurrentTime[9]; new szData[11]; get_time("%H:%M:%S",szCurrentTime,sizeof(szCurrentTime)); get_time("%d.%m.%Y",szData,sizeof(szData)); set_dhudmessage(255, 102, 0, -1.0, 0.0, 0, 0.5, 0.9, 0.5, 0.5); show_dhudmessage(id, "^n[ %s - %s ]^n[ BaseBuilder ]", szCurrentTime, szData); } } else { userSpeedAdmin[id] = 0.0; remove_task(id + TASK_LOGIN); } set_task(0.85, "startLogin", id + TASK_LOGIN); } new const pointAdd[] = { 1, 3, 5, 10, 15, 25, 255 }; new userHudAdd[33][4]; public changeHud(id){ if (!is_user_connected(id)) return PLUGIN_HANDLED; missionHud(id); new gText[128]; new menu = menu_create("\r[BaseBuilder]\y Konfiguracja HUD\w", "changeHud_2"); new cb = menu_makecallback("changeHud_3"); format(gText, sizeof(gText), "\wKolor \yCzerwony: \r%d", userHud[id][PLAYER_HUD_RED]); menu_additem(menu, gText, .callback=cb); format(gText, sizeof(gText), "\wKolor \yZielony: \r%d", userHud[id][PLAYER_HUD_GREEN]); menu_additem(menu, gText, .callback=cb); format(gText, sizeof(gText), "\wKolor \yNiebieski: \r%d^n", userHud[id][PLAYER_HUD_BLUE]); menu_additem(menu, gText, .callback=cb); format(gText, sizeof(gText), "\wSposob dodawania: \r%s", userHudAdd[id][2] == 1 ? "Klikaj" : "Wpisz"); menu_additem(menu, gText, .callback=cb); format(gText, sizeof(gText), "\%cWartosc dodawania: \%c%d", userHudAdd[id][2] == 1 ? 'w' : 'd', userHudAdd[id][2] == 1 ? 'r' : 'd', pointAdd[userHudAdd[id][0]]); menu_additem(menu, gText, .callback=cb); format(gText, sizeof(gText), "\%cTyp dodawania: \%c%s^n", userHudAdd[id][2] == 1 ? 'w' : 'd', userHudAdd[id][2] == 1 ? 'r' : 'd', userHudAdd[id][1] == 0 ? "Odejmij" : "Dodaj"); menu_additem(menu, gText, .callback=cb); format(gText, sizeof(gText), "\yDomyslne Ustawienia"); menu_additem(menu, gText, .callback=cb); menu_setprop(menu, MPROP_EXITNAME, "Wyjscie"); menu_display(id, menu); return PLUGIN_HANDLED; } public changeHud_3(id, menu, item) { switch(item){ case 4,5: { if(userHudAdd[id][2] == 1) return ITEM_ENABLED; else return ITEM_DISABLED; } } return ITEM_ENABLED; } public changeHud_2(id, menu, item){ if (!is_user_connected(id)) return PLUGIN_HANDLED; if (item == MENU_EXIT) { menu_destroy(menu); return PLUGIN_HANDLED; } new addHud = pointAdd[userHudAdd[id][0]]; switch (item) { case 0: { if(userHudAdd[id][2]){ if(userHudAdd[id][1]){ if ((userHud[id][PLAYER_HUD_RED] += addHud) > 255) userHud[id][PLAYER_HUD_RED] = 0; } else { if ((userHud[id][PLAYER_HUD_RED] -= addHud) < 0) userHud[id][PLAYER_HUD_RED] = 255; } } else { userHudAdd[id][3] =0; client_cmd(id, "messagemode WartoscKoloruHud"); } changeHud(id); } case 1:{ if(userHudAdd[id][2]){ if(userHudAdd[id][1]){ if ((userHud[id][PLAYER_HUD_GREEN] += addHud) > 255) userHud[id][PLAYER_HUD_GREEN] = 0; } else { if ((userHud[id][PLAYER_HUD_GREEN] -= addHud) < 0) userHud[id][PLAYER_HUD_GREEN] = 255; } } else { userHudAdd[id][3] =1; client_cmd(id, "messagemode WartoscKoloruHud"); } changeHud(id); } case 2:{ if(userHudAdd[id][2]){ if(userHudAdd[id][1]){ if ((userHud[id][PLAYER_HUD_BLUE] += addHud) > 255) userHud[id][PLAYER_HUD_BLUE] = 0; } else { if ((userHud[id][PLAYER_HUD_BLUE] -= addHud) < 0) userHud[id][PLAYER_HUD_BLUE] = 255; } } else { userHudAdd[id][3] =2; client_cmd(id, "messagemode WartoscKoloruHud"); } changeHud(id); } case 3:{ if(userHudAdd[id][2] == 0){ userHudAdd[id][2] ++; } else { userHudAdd[id][2] --; } changeHud(id); } case 4:{ if (++userHudAdd[id][0] >= sizeof(pointAdd)) { userHudAdd[id][0] = 0; } changeHud(id); } case 5:{ if(userHudAdd[id][1] == 0){ userHudAdd[id][1] ++; } else { userHudAdd[id][1] --; } changeHud(id); } case 6: { userHud[id][PLAYER_HUD_RED] = 255;//120; userHud[id][PLAYER_HUD_GREEN] = 0;// 255; userHud[id][PLAYER_HUD_BLUE] = 60;//60; userHudAdd[id][0] = 4; userHudAdd[id][1] = 1; userHudAdd[id][2] = 1; userHudAdd[id][3] = 0; changeHud(id); } } menu_destroy(menu); return PLUGIN_CONTINUE; } public readColor(id){ new szArg[7]; read_argv(1, szArg, sizeof(szArg)-3); new color = str_to_num(szArg)%256; switch(userHudAdd[id][3]){ case 0: userHud[id][PLAYER_HUD_RED] = color; case 1: userHud[id][PLAYER_HUD_GREEN] = color; case 2: userHud[id][PLAYER_HUD_BLUE] = color; } changeHud(id); } public missionHud(id){ if(userHud[id][PLAYER_HUD_RED] == 1 && userHud[id][PLAYER_HUD_GREEN] == 1 && userHud[id][PLAYER_HUD_BLUE] == 1 ){ addSecretMission(id, mission_secret_COLOR, 1); } } public bool:playerLogged(id){ if(!userLoaded[id] || !userLogged[id] || strlen(userPassword[id]) < 2) return false; return true; } /* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE *{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par } */ Przeczytaj cały wpis
  14. Hello, I also have this VIP plugin, and I would like to change the bullet damage in it please. Code: #include amxmodx #include amxmisc #include cstrike #include fun #include hamsandwich #include engine #include fakemeta #include csx #if AMXX_VERSION_NUM < 183 #include colorchat #endif #define p. "VIP Clasic" #define v. "9.0" #define a. "Jică Măcelaru'" #define VIP_FLAG "t" #define SCOREATTRIB_VIP (1 << 2) new const Float: g_flCoords[][] = { { 0.50, 0.40 }, { 0.56, 0.44 }, { 0.60, 0.50 }, { 0.56, 0.56 }, { 0.50, 0.60 }, { 0.44, 0.56 }, { 0.40, 0.50 }, { 0.44, 0.44 } }; new const g_szBeginning[] = "Membrii VIP"; new g_Cvar[30], g_Round[33] = 0, g_JumpNum[33], bool:g_DoJump[33], g_iPosition[33], g_iSize, g_szMessage[256], SyncHudMessage, g_VipConfig[] = "vipConfig.cfg", g_VipMaps[] = "vipMaps.ini", g_File1[128], g_File2[128], bool:g_Use[33], bool:g_Menu[33], o; enum { Primary = 1, Secondary, Knife, Grenades, C4 }; public plugin_init() { register_plugin p., v., a.; register_clcmd "say", "sayCommand"; register_clcmd "say_team", "sayCommand"; g_Cvar[0] = register_cvar("vip_mode", "2"); g_Cvar[1] = register_cvar("vip_tag", "VIP"); g_Cvar[2] = register_cvar("vip_start_hp", "120"); g_Cvar[3] = register_cvar("vip_start_ap", "120"); g_Cvar[4] = register_cvar("vip_start_money", "1000"); g_Cvar[5] = register_cvar("vip_jump", "1"); g_Cvar[6] = register_cvar("vip_hp_kill", "15"); g_Cvar[7] = register_cvar("vip_ap_kill", "15"); g_Cvar[8] = register_cvar("vip_hp_hs", "20"); g_Cvar[9] = register_cvar("vip_ap_hs", "20"); g_Cvar[10] = register_cvar("vip_hp_kill_knife", "20"); g_Cvar[11] = register_cvar("vip_ap_kill_knife", "20"); g_Cvar[12] = register_cvar("vip_hp_hs_knife", "25"); g_Cvar[13] = register_cvar("vip_ap_hs_knife", "25"); g_Cvar[14] = register_cvar("vip_bulletdmg", "1"); g_Cvar[16] = register_cvar("vip_in_out", "1"); g_Cvar[17] = register_cvar("vip_show_chat", "1"); g_Cvar[18] = register_cvar("vip_show_hud", "1"); g_Cvar[19] = register_cvar("vip_maxhp", "200"); g_Cvar[20] = register_cvar("vip_maxap", "200"); g_Cvar[21] = register_cvar("vip_parachute", "0"); g_Cvar[22] = register_cvar("vip_money_kill", "400"); g_Cvar[23] = register_cvar("vip_money_hs", "600"); g_Cvar[24] = register_cvar("vip_bulletdmg_mode", "1"); g_Cvar[25] = register_cvar("vip_tab", "1"); g_Cvar[26] = register_cvar("vip_defusekit", "1"); g_Cvar[27] = register_cvar("vip_free", "1"); g_Cvar[28] = register_cvar("vip_free_start", "00"); g_Cvar[29] = register_cvar("vip_free_end", "08"); set_task 300.0, "msgInfo", _, _, _, "b"; set_task 1.0, "showVipsH", _, _, _, "b", 0; set_task 1.0, "GiveVIP" ,_,_,_, "b"; register_message get_user_msgid("ScoreAttrib"), "MessageScoreAttrib"; RegisterHam Ham_Spawn, "player", "Spawn", 1; SyncHudMessage = CreateHudSyncObj(); g_iSize = sizeof(g_flCoords); register_event "HLTV", "newRound", "a", "1=0", "2=0"; register_event "ResetHUD", "resetModel", "b"; } public plugin_cfg() { new File[64]; get_configsdir File, charsmax(File); formatex g_File1, charsmax(g_File1), "%s/%s", File, g_VipConfig; formatex g_File2, charsmax(g_File2), "%s/%s", File, g_VipMaps; if(!file_exists(g_File1)) { write_file(g_File1, "; Plugin VIP creat de Jică Măcelaru' (aka. StefaN@CS, Devil., joker`)"); write_file(g_File1, "; Plugin publicat pe www.indungi.ro/forum"); write_file(g_File1, "; https://www.indungi.ro/forum/topic/829508-vip-clasic-90-vip_clasicamxx/"); write_file(g_File1, "; Suport Counter-Strike 1.6 contra-cost"); write_file(g_File1, "; Contact"); write_file(g_File1, "; PM forum: https://www.indungi.ro/forum/profile/349550-jică-măcelaru/"); write_file(g_File1, "; Steam: https://steamcommunity.com/id/baulesscs161/"); write_file(g_File1, "; Paypal: paypal.me/sacotia"); write_file(g_File1, "; Cine considera ca l-am ajutat si ca merit. Multumesc!"); write_file(g_File1, ""); write_file(g_File1, ""); write_file(g_File1, ""); write_file(g_File1, "/////// Vip Configuration File"); write_file(g_File1, ""); write_file(g_File1, "//// VIP Mode"); write_file(g_File1, "// Setati modul de aparitie al meniului"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - meniu prin comanda /vmenu"); write_file(g_File1, "// 2 - meniu din a 3-a runda"); write_file(g_File1, "// Default: '1'"); write_file(g_File1, "vip_mode ^"2^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Tag"); write_file(g_File1, "// Setati tagul ce va aparea in chat in mesaje"); write_file(g_File1, "// Default: 'VIP'"); write_file(g_File1, "vip_tag ^"VIP^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Start"); write_file(g_File1, "// Setati viata, armura si banii cu care va incepe vipul fiecare runda"); write_file(g_File1, "// La bani setati cu cati bani in plus va incepe"); write_file(g_File1, "// EX: VIP-ul are 800 bani si la spawn i se vor mai adauga inca 1000"); write_file(g_File1, "// Default: 150, 150, 1000"); write_file(g_File1, "vip_start_hp ^"120^""); write_file(g_File1, "vip_start_ap ^"120^""); write_file(g_File1, "vip_start_money ^"1000^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP HP/AP/BANI per kill/hs"); write_file(g_File1, "// Setati cat hp/ap/bani sa primeasca vip-ul pe fiecare kill/hs facut in functie de cum este facut kill-ul/hs-ul"); write_file(g_File1, "// Default: 5, 5, 10, 10, 15, 15, 20, 20, 400, 600"); write_file(g_File1, "vip_hp_kill ^"15^""); write_file(g_File1, "vip_ap_kill ^"15^""); write_file(g_File1, "vip_hp_hs ^"20^""); write_file(g_File1, "vip_ap_hs ^"20^""); write_file(g_File1, "vip_hp_kill_knife ^"20^""); write_file(g_File1, "vip_ap_kill_knife ^"20^""); write_file(g_File1, "vip_hp_hs_knife ^"25^""); write_file(g_File1, "vip_ap_hs_knife ^"25^""); write_file(g_File1, "vip_money_kill ^"400^""); write_file(g_File1, "vip_money_hs ^"600^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Max HP/AP"); write_file(g_File1, "// Setati maximul de hp/ap pe care il poate avea vipul"); write_file(g_File1, "// Default: 200, 200"); write_file(g_File1, "vip_max_hp ^"200^""); write_file(g_File1, "vip_max_ap ^"200^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Jump"); write_file(g_File1, "// Setati cat poate sari vipul"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - 2x jump"); write_file(g_File1, "// 2 - 3x jump"); write_file(g_File1, "// 3 - 4x jump"); write_file(g_File1, "// ..."); write_file(g_File1, "// z - yx jump"); write_file(g_File1, "Default: 1"); write_file(g_File1, "vip_jump ^"1^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Parachute"); write_file(g_File1, "// Setati daca vip-ul va avea sau nu parasuta"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_parachute ^"0^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Defuse Kit (Only CT)"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_defusekit ^"1^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Show"); write_file(g_File1, "// Setati momentele in care vor fi afisati vipii"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Cand intra/iese de pe server cu mesaj in chat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_in_out ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Cand tastezi comanda /vips apare in chat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_show_chat ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Afisare in hud in coltul stang, sus"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_show_hud ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Afisare in TAB (ScoreBoard)"); write_file(g_File1, "// Default: 0"); write_file(g_File1, "vip_tab ^"0^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Bulletdamage + mode"); write_file(g_File1, "// Setati daca vipul va avea bulletdamage"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_bulletdmg ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Setati modul de aparitie al bulletdamageului"); write_file(g_File1, "// vip_bulletdmg trebuie sa fie setat pe 1"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - cerc multi color pentru ambele echipe"); write_file(g_File1, "// 2 - cerc albastru/rosu (CT - albastru / T - rosu)"); write_file(g_File1, "// 3 - centru multi color pentru ambele echipe"); write_file(g_File1, "// 4 - centru albastru/rosu (CT - albastru / T - rosu)"); write_file(g_File1, "// Default: 1"); write_file(g_File1, "vip_bulletdmg_mode ^"1^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Model"); write_file(g_File1, "// Setati daca vip-ul va avea model sau nu"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "// Daca doriti sa activati modelul, setati valoarea 1 si schimbati mapa ca sa se descarce modelele"); write_file(g_File1, "// Daca doriti sa dezactivati modelul, setati valoarea 0 si schimbati mapa ca sa nu se mai descarce modelele"); write_file(g_File1, "Default: 1"); write_file(g_File1, "vip_model ^"0^""); write_file(g_File1, ""); write_file(g_File1, "//// VIP Free"); write_file(g_File1, "// Setati daca va fi vip free sau nu pe server"); write_file(g_File1, "// 0 - dezactivat"); write_file(g_File1, "// 1 - activat"); write_file(g_File1, "vip_free ^"1^""); write_file(g_File1, ""); write_file(g_File1, "// Setati orele intre care va fi vip free"); write_file(g_File1, "// Ore disponibile"); write_file(g_File1, "// 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, 12"); write_file(g_File1, "// 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 00"); write_file(g_File1, "// Default: 22, 08"); write_file(g_File1, "vip_free_start ^"22^""); write_file(g_File1, "vip_free_end ^"08^""); } server_cmd "exec %s", g_File1; if(!file_exists(g_File2)) { write_file(g_File2, ";--------------- | Lista hartilor pe care meniul vipului este restrictionat | ---------------"); write_file(g_File2, ""); write_file(g_File2, ";Adaugati mapele una sub alta"); write_file(g_File2, ""); write_file(g_File2, "35hp"); write_file(g_File2, "awp_india"); write_file(g_File2, "awp_bycastor"); write_file(g_File2, "fy_snow"); write_file(g_File2, "awp_zigzag"); } } public sayCommand(id) { new Said[10]; read_args Said, charsmax(Said); remove_quotes(Said); if(equal(Said, "/vips")) showVipsC(id); else if(equal(Said, "/vip")) vipInfo(id); else if(equal(Said, "/vmenu")) if(get_pcvar_num(g_Cvar[0]) == 1) if(g_Menu[id] == true) vipMenu(id); return 0; } public client_putinserver(id) { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; set_task 2.0, "vipIn", id; g_JumpNum[id] = 0; g_DoJump[id] = false; g_Round[id] = 0; g_Use[id] = false; g_Menu[id] = true; return 1; } #if AMXX_VERSION_NUM < 183 public client_disconnect(id) #else public client_disconnected(id) #endif { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; set_task 2.0, "vipOut", id; g_JumpNum[id] = 0; g_DoJump[id] = false; g_Round[id] = 0; g_Use[id] = false; return 1; } public vipInfo(id) show_motd(id, "/addons/amxmodx/configs/vipInfo.html"); public msgInfo() { new tag[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); #if AMXX_VERSION_NUM < 183 ColorChat 0, GREEN, "^3[%s] ^1Tastati in chat ^4/vip ^1pentru a vedea beneficiile si pretul vip-ului.", tag; #else client_print_color 0, print_team_default, "^3[%s] ^1Tastati in chat ^4/vip ^1pentru a vedea beneficiile si pretul vip-ului.", tag; #endif } public plugin_precache() { g_Cvar[15] = register_cvar("vip_model", "0"); if(get_pcvar_num(g_Cvar[15]) == 0) return 1; precache_model "models/player/vip_tero/vip_tero.mdl"; precache_model "models/player/vip_ct/vip_ct.mdl"; return 1; } public newRound() for(new i = 0; i < 32; i++) g_Use[i] = false; public vipMenu(id) { if(!is_user_alive(id) || !(get_user_flags(id) & read_flags(VIP_FLAG)) || g_Use[id]) return 1; new menu; switch(cs_get_user_team(id)) { case CS_TEAM_T: { menu = menu_create("\r[\dVIP\r] \yPistolarii System", "Ammunition"); menu_additem menu, "AK47 + DEAGLE + GRENADE", "1"; menu_additem menu, "M4A1 + DEAGLE + GRENADE", "2"; menu_additem menu, "AWP + DEAGLE + GRENADE", "3"; } case CS_TEAM_CT: { menu = menu_create("\r[\dVIP\r] \yPistolarii System", "Ammunition"); menu_additem menu, "M4A1 + DEAGLE + GRENADE", "1"; menu_additem menu, "AK47 + DEAGLE + GRENADE", "2"; menu_additem menu, "AWP + DEAGLE + GRENADE", "3"; } } menu_display id, menu, 0; return 1; } public Ammunition(id, menu, item) { if(item == MENU_EXIT) return 1; new access, callback, data[6], szName[64], tag[32]; menu_item_getinfo(menu, item, access, data, charsmax(data), szName, charsmax(szName), callback); get_pcvar_string g_Cvar[1], tag, charsmax(tag); new key = str_to_num(data); if(cs_get_user_team(id) == CS_TEAM_T) { switch(key) { case 1: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_ak47"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AK47, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 2: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_m4a1"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_M4A1, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 3: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_awp"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AWP, 30; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } } } if(cs_get_user_team(id) == CS_TEAM_CT) { switch(key) { case 1: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_m4a1"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_M4A1, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4M4a1^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 2: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_ak47"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AK47, 90; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Ak47^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } case 3: { StripWeapons id, Primary; StripWeapons id, Secondary; give_item id, "weapon_knife"; give_item id, "weapon_awp"; give_item id, "weapon_deagle"; give_item id, "weapon_hegrenade"; give_item id, "weapon_flashbang"; cs_set_user_bpammo id, CSW_FLASHBANG, 2; cs_set_user_bpammo id, CSW_AWP, 30; cs_set_user_bpammo id, CSW_DEAGLE, 35; #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Ai ales ^4Awp^1+^4Deagle^1+^4Set grenade^1.", tag; #endif g_Use[id] = true; } } } menu_destroy(menu); return 1; } public Spawn(id) { if(!is_user_alive(id) || !(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; if(get_user_team(id) == 2) { give_item(id, "item_thighpack"); } StripWeapons id, Secondary; give_item(id, "weapon_deagle"); give_item(id, "weapon_knife"); give_item(id, "weapon_hegrenade"); give_item(id, "weapon_flashbang"); cs_set_user_bpammo(id, CSW_HEGRENADE, 1); cs_set_user_bpammo(id, CSW_FLASHBANG, 2); cs_set_user_bpammo(id, CSW_DEAGLE, 35); if(get_pcvar_num(g_Cvar[0]) == 2) { if(g_Menu[id] == true) if(g_Round[id] >= 3) vipMenu(id); g_Round[id]++; } if(get_pcvar_num(g_Cvar[26]) == 1) if(cs_get_user_team(id) == CS_TEAM_CT) give_item id, "item_thighpack"; give_item id, "item_assaultsuit"; set_user_health id, get_pcvar_num(g_Cvar[2]); set_user_armor id, get_pcvar_num(g_Cvar[3]); cs_set_user_money id, clamp(cs_get_user_money(id) + get_pcvar_num(g_Cvar[4]), 0, 16000); new MapName[32], szLine[128], iLen; new Size = file_size(g_File2, 1) get_mapname(MapName, sizeof(MapName)); for(new i = 0; i < Size; i ++) { read_file(g_File2, i, szLine, charsmax(szLine), iLen); if(equali(MapName, szLine)) g_Menu[id] = false; } return 1; } public GiveVIP() { if(get_pcvar_num(g_Cvar[27]) == 1) { time(o, _, _); if(o >= get_pcvar_num(g_Cvar[28]) && o < 24 || o >= 00 && o < get_pcvar_num(g_Cvar[29])) { for(new i = 1; i <= get_maxplayers(); i++) if(is_user_connected(i) || !is_user_bot(i) || !is_user_hltv(i) || !(get_user_flags(i) & read_flags(VIP_FLAG))) set_user_flags i, read_flags(VIP_FLAG) set_hudmessage random_num(0, 255), random_num(0, 255), random_num(0, 255), -1.0, 0.02, 0, 1.0, 1.0; show_hudmessage 0, "EVENT VIP FREE %i:00 - %i:00", get_pcvar_num(g_Cvar[28]), get_pcvar_num(g_Cvar[29]); } if(o == get_pcvar_num(g_Cvar[29])) server_cmd("amx_reloadadmins"); } } public vipIn(id) { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; if(get_pcvar_num(g_Cvar[16]) == 1) { new tag[32], name[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); get_user_name id, name, charsmax(name); #if AMXX_VERSION_NUM < 183 ColorChat 0, GREEN, "^3[%s] ^4%s ^1s-a conectat pe server.", tag, name; #else client_print_color 0, print_team_default, "^3[%s] ^4%s ^1s-a conectat pe server.", tag, name; #endif } return 1; } public vipOut(id) { if(!(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; if(get_pcvar_num(g_Cvar[16]) == 1) { new tag[32], name[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); get_user_name id, name, charsmax(name); #if AMXX_VERSION_NUM < 183 ColorChat 0, GREEN, "^3[%s] ^4%s ^1s-a deconectat de pe server.", tag, name; #else client_print_color 0, print_team_default, "^3[%s] ^4%s ^1s-a deconectat de pe server.", tag, name; #endif } return 1; } public client_PreThink(id) { if(!is_user_alive(id) || !(get_user_flags(id) & read_flags(VIP_FLAG))) return 1; new Float:fallspeed = 100.0 * -1.0; new BUTTON = get_user_button(id); new OLDBUTON = get_user_oldbutton(id); new JUMP_VIP = get_pcvar_num(g_Cvar[5]); if((BUTTON & IN_JUMP) && !(get_entity_flags(id) & FL_ONGROUND) && !(OLDBUTON & IN_JUMP)) { if(g_JumpNum[id] < JUMP_VIP) { g_DoJump[id] = true; g_JumpNum[id]++ } } if((BUTTON & IN_JUMP) && (get_entity_flags(id) & FL_ONGROUND)) g_JumpNum[id] = 0; if(get_pcvar_num(g_Cvar[21]) == 1) { if(BUTTON & IN_USE) { new Float:velocity[3]; entity_get_vector(id, EV_VEC_velocity, velocity); if(velocity[2] < 0.0) { entity_set_int id, EV_INT_sequence, 3; entity_set_int id, EV_INT_gaitsequence, 1; entity_set_float id, EV_FL_frame, 1.0; entity_set_float id, EV_FL_framerate, 1.0; velocity[2] = (velocity[2] + 40.0 < fallspeed) ? velocity[2] + 40.0 : fallspeed; entity_set_vector id, EV_VEC_velocity, velocity; } } } return 0; } public client_PostThink(id) { if(!is_user_alive(id)) return 1; if(g_DoJump[id] == true) { new Float: velocity[3]; entity_get_vector id, EV_VEC_velocity, velocity; velocity[2] = random_float(265.0, 285.0); entity_set_vector id, EV_VEC_velocity, velocity; g_DoJump[id] = false; } return 0; } public client_death(killer, victim, weapon, hitplace) { if(!(get_user_flags(killer) & read_flags(VIP_FLAG))) return 1; new VIP_MAXHP = get_pcvar_num(g_Cvar[19]); new VIP_HP = get_user_health(killer); new VIP_MAXAP = get_pcvar_num(g_Cvar[20]); new VIP_AP = get_user_armor(killer); if(!(hitplace == HIT_HEAD) && !(weapon == CSW_KNIFE)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[6]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor killer, VIP_AP + get_pcvar_num(g_Cvar[7]); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[22]), 0, 16000); } if(hitplace == HIT_HEAD && !(weapon == CSW_KNIFE)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[8]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor killer, VIP_AP + get_pcvar_num(g_Cvar[9]); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[23]), 0, 16000); } if(weapon == CSW_KNIFE && !(hitplace == HIT_HEAD)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[10]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor(killer, VIP_AP + get_pcvar_num(g_Cvar[11])); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[22]), 0, 16000); } if(weapon == CSW_KNIFE && (hitplace == HIT_HEAD)) { if(VIP_HP >= VIP_MAXHP) set_user_health killer, VIP_MAXHP; else set_user_health killer, VIP_HP + get_pcvar_num(g_Cvar[12]); if(VIP_AP >= VIP_MAXAP) set_user_armor killer, VIP_MAXAP; else set_user_armor killer, VIP_AP + get_pcvar_num(g_Cvar[13]); cs_set_user_money killer, clamp(cs_get_user_money(killer) - 300 + get_pcvar_num(g_Cvar[23]), 0, 16000); } return 1; } public client_damage(iAttacker, iVictim, iDamage) { if(!(get_user_flags(iAttacker) & read_flags(VIP_FLAG))) return 1; if(get_pcvar_num(g_Cvar[14]) == 1) { if(get_pcvar_num(g_Cvar[24]) == 1) { if(++g_iPosition[iAttacker] == g_iSize) g_iPosition[iAttacker] = 0; set_hudmessage random_num(0, 255), random_num(0, 255), random_num(0, 255), Float: g_flCoords[g_iPosition[iAttacker]][0], Float: g_flCoords[g_iPosition[iAttacker]][1], 0, 0.1, 2.5, 0.02, 0.02, -1; show_hudmessage iAttacker, "%i", iDamage; } else if(get_pcvar_num(g_Cvar[24]) == 2) { if(++g_iPosition[iAttacker] == g_iSize) g_iPosition[iAttacker] = 0; if(cs_get_user_team(iAttacker) == CS_TEAM_CT) { set_hudmessage 42, 170, 255, Float: g_flCoords[g_iPosition[iAttacker]][0], Float: g_flCoords[g_iPosition[iAttacker]][1], 0, 0.1, 2.5, 0.02, 0.02, -1; show_hudmessage iAttacker, "%i", iDamage; } else if(cs_get_user_team(iAttacker) == CS_TEAM_T) { set_hudmessage 200, 0, 0, Float: g_flCoords[g_iPosition[iAttacker]][0], Float: g_flCoords[g_iPosition[iAttacker]][1], 0, 0.1, 2.5, 0.02, 0.02, -1; show_hudmessage iAttacker, "%i", iDamage; } } else if(get_pcvar_num(g_Cvar[24]) == 3) { set_hudmessage random_num(0, 255), random_num(0, 255), random_num(0, 255), -1.0, 0.5, 0, 0.0, 0.1, 0.1, 0.1; show_hudmessage iAttacker, "%i", iDamage; } else if(get_pcvar_num(g_Cvar[24]) == 4) { if(cs_get_user_team(iAttacker) == CS_TEAM_CT) { set_hudmessage 42, 170, 255, -1.0, 0.4, 0, 0.0, 2.0, 0.1, 0.1; show_hudmessage iAttacker, "%i", iDamage; } else if(cs_get_user_team(iAttacker) == CS_TEAM_T) { set_hudmessage 200, 0, 0, -1.0, 0.4, 0, 0.0, 2.0, 0.1, 0.1; show_hudmessage iAttacker, "%i", iDamage; } } } return 1; } public showVipsC(user) { if(get_pcvar_num(g_Cvar[17]) == 1) { new tag[32]; get_pcvar_string g_Cvar[1], tag, charsmax(tag); new vipNames[33][32]; new message[256]; new id, count, x, len; for(id = 1 ; id <= get_maxplayers() ; id++) if(is_user_connected(id)) if(get_user_flags(id) & read_flags(VIP_FLAG)) get_user_name id, vipNames[count++], charsmax(vipNames[]); len = format(message, 255, "^3[%s] ^1VIP-ii online sunt:^4 ", tag); if(count > 0) { for(x = 0 ; x < count ; x++) { len += format(message[len], 255-len, "%s%s ", vipNames[x], x < (count-1) ? ", ":""); if(len > 96) { print_message(user, message); len = format(message, 255, " "); } } print_message(user, message); } else { #if AMXX_VERSION_NUM < 183 ColorChat id, GREEN, "^3[%s] ^1Nu sunt ^4VIP^1-i online.", tag; #else client_print_color id, print_team_default, "^3[%s] ^1Nu sunt ^4VIP^1-i online.", tag; #endif } } return 0; } print_message(id, msg[]) { message_begin(MSG_ONE, get_user_msgid("SayText"), {0,0,0}, id); write_byte(id); write_string(msg); message_end(); } public showVipsH() { if(get_pcvar_num(g_Cvar[18]) == 1) { static iPlayers[32]; static iPlayersNum; get_players(iPlayers, iPlayersNum, "ch"); if(!iPlayersNum) return 1; static iVipsConnected, szVipsNames[128], szName[32]; formatex(szVipsNames, sizeof (szVipsNames) -1, ""); iVipsConnected = 0; static id, i; for(i = 0; i < iPlayersNum; i++) { id = iPlayers[i]; if(get_user_flags(id) & read_flags(VIP_FLAG)) { get_user_name(id, szName, sizeof(szName) -1); add(szVipsNames, sizeof(szVipsNames) -1, szName); add(szVipsNames, sizeof(szVipsNames) -1, "^n"); iVipsConnected++; } } formatex(g_szMessage, sizeof(g_szMessage) -1, "%s (%i)^n%s", g_szBeginning, iVipsConnected, szVipsNames); set_hudmessage 25, 255, 0, 0.01, 0.20, 0, 0.0, 1.0, 0.1, 0.1, -1; ShowSyncHudMsg 0, SyncHudMessage, g_szMessage; } return 0; } public resetModel(id, level, cid) { if(!is_user_alive(id) || !(get_user_flags(id) & read_flags(VIP_FLAG)) || get_pcvar_num(g_Cvar[15]) == 0) return 1; new CsTeams:userTeam = cs_get_user_team(id) if(userTeam == CS_TEAM_T) cs_set_user_model id, "vip_tero"; else if(userTeam == CS_TEAM_CT) cs_set_user_model id, "vip_ct"; else cs_reset_user_model(id); return 0; } public MessageScoreAttrib(iMsgID, iDest, iReceiver) { if(get_pcvar_num(g_Cvar[25]) == 1) { new id = get_msg_arg_int(1); if(is_user_connected(id) && (get_user_flags(id) & read_flags(VIP_FLAG)) && is_user_alive(id)) set_msg_arg_int(2, ARG_BYTE, SCOREATTRIB_VIP); } } stock StripWeapons(id, Type, bool: bSwitchIfActive = true) { new iReturn; if(is_user_alive(id)) { new iEntity, iWeapon; while((iWeapon = GetWeaponFromSlot(id, Type, iEntity)) > 0) iReturn = ham_strip_user_weapon(id, iWeapon, Type, bSwitchIfActive); } return iReturn; } stock GetWeaponFromSlot( id , iSlot , &iEntity ) { if ( !( 1 <= iSlot <= 5 ) ) return 0; iEntity = 0; const m_rgpPlayerItems_Slot0 = 367; const m_iId = 43; const XO_WEAPONS = 4; const XO_PLAYER = 5; iEntity = get_pdata_cbase( id , m_rgpPlayerItems_Slot0 + iSlot , XO_PLAYER ); return ( iEntity > 0 ) ? get_pdata_int( iEntity , m_iId , XO_WEAPONS ) : 0; } stock ham_strip_user_weapon(id, iCswId, iSlot = 0, bool:bSwitchIfActive = true) { new iWeapon if( !iSlot ) { static const iWeaponsSlots[] = { -1, 2, //CSW_P228 -1, 1, //CSW_SCOUT 4, //CSW_HEGRENADE 1, //CSW_XM1014 5, //CSW_C4 1, //CSW_MAC10 1, //CSW_AUG 2, //CSW_ELITE 2, //CSW_FIVESEVEN 1, //CSW_UMP45 1, //CSW_SG550 1, //CSW_GALIL 1, //CSW_FAMAS 2, //CSW_USP 2, //CSW_GLOCK18 1, //CSW_AWP 1, //CSW_MP5NAVY 1, //CSW_M249 1, //CSW_M3 1, //CSW_M4A1 1, //CSW_TMP 1, //CSW_G3SG1 4, //CSW_FLASHBANG 2, //CSW_DEAGLE 1, //CSW_SG552 1, //CSW_AK47 3, //CSW_KNIFE 1 //CSW_P90 } iSlot = iWeaponsSlots[iCswId] } const XTRA_OFS_PLAYER = 5 const m_rgpPlayerItems_Slot0 = 367 iWeapon = get_pdata_cbase(id, m_rgpPlayerItems_Slot0 + iSlot, XTRA_OFS_PLAYER) const XTRA_OFS_WEAPON = 4 const m_pNext = 42 const m_iId = 43 while( iWeapon > 0 ) { if( get_pdata_int(iWeapon, m_iId, XTRA_OFS_WEAPON) == iCswId ) { break } iWeapon = get_pdata_cbase(iWeapon, m_pNext, XTRA_OFS_WEAPON) } if( iWeapon > 0 ) { const m_pActiveItem = 373 if( bSwitchIfActive && get_pdata_cbase(id, m_pActiveItem, XTRA_OFS_PLAYER) == iWeapon ) { ExecuteHamB(Ham_Weapon_RetireWeapon, iWeapon) } if( ExecuteHamB(Ham_RemovePlayerItem, id, iWeapon) ) { user_has_weapon(id, iCswId, 0) ExecuteHamB(Ham_Item_Kill, iWeapon) return 1 } } return 0 } with this one Code: /* Plugin generated by AMXX-Studio */ #include <amxmodx> #include <amxmisc> #include <fakemeta_util> #define PLUGIN "Advanced Bullet Damage" #define VERSION "1.0" #define AUTHOR "Sn!ff3r" new g_type, g_enabled, g_recieved, bool:g_showrecieved, g_hudmsg1, g_hudmsg2 public plugin_init() { register_plugin(PLUGIN, VERSION, AUTHOR) register_event("Damage", "on_damage", "b", "2!0", "3=0", "4!0") register_event("HLTV", "on_new_round", "a", "1=0", "2=0") g_type = register_cvar("amx_bulletdamage","1") g_recieved = register_cvar("amx_bulletdamage_recieved","1") g_hudmsg1 = CreateHudSyncObj() g_hudmsg2 = CreateHudSyncObj() } public on_new_round() { g_enabled = get_pcvar_num(g_type) if(get_pcvar_num(g_recieved)) g_showrecieved = true } public on_damage(id) { if(g_enabled) { static attacker; attacker = get_user_attacker(id) static damage; damage = read_data(2) if(g_showrecieved) { set_hudmessage(255, 0, 0, 0.45, 0.50, 2, 0.1, 4.0, 0.1, 0.1, -1) ShowSyncHudMsg(id, g_hudmsg2, "%i^n", damage) } if(is_user_connected(attacker)) { switch(g_enabled) { case 1: { set_hudmessage(0, 100, 200, -1.0, 0.55, 2, 0.1, 4.0, 0.02, 0.02, -1) ShowSyncHudMsg(attacker, g_hudmsg1, "%i^n", damage) } case 2: { if(fm_is_ent_visible(attacker,id)) { set_hudmessage(0, 100, 200, -1.0, 0.55, 2, 0.1, 4.0, 0.02, 0.02, -1) ShowSyncHudMsg(attacker, g_hudmsg1, "%i^n", damage) } } } } } } /* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE *{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1045\\ f0\\ fs16 \n\\ par } */Thank's.. Przeczytaj cały wpis
  15. I enabled the option that gives a HE grenade when a player is spawned/respawned in this CSDM mod, but bots can't use the HE grenade properly. When i restart the server, bots use the HE grenade only one time, then don't use the grenade anymore, despite the fact they have one and always get it when they are respawned. In the csdm.cfg file, the setting are set that way: ;Grenade flags: ; f - flashbang ; h - he grenade ; s - smoke grenade grenades = hs It seems the default CS 1.6 can't use grenades in this mod. Maybe, i have to add additional bot support usign a third-party plugin? Przeczytaj cały wpis
×
×
  • Dodaj nową pozycję...