hlmod.hu https://hlmod.hu/ |
|
frag elosztó https://hlmod.hu/viewtopic.php?f=29&t=22301 |
Oldal: 1 / 1 |
Szerző: | WaReZuM [2015.10.02. 18:08 ] |
Hozzászólás témája: | frag elosztó |
Sziasztok! Olyan frag elosztó kéne nekem ami chatbe kiírja mindenkinek hogy "[Információ] Játékos kapott +1 fraget amiért besegített XXX megölésében !" "Játékos" helyén legyen a támadó neve az "XXX" helyén pedig a támadotté. Előre is köszönöm ![]() |
Szerző: | mforce [2015.10.02. 18:09 ] |
Hozzászólás témája: | Re: frag elosztó |
Valahonnan TÚL ismerős... ![]() A másik támadó nevét viszont nem írja. Sőt ez így is túl hosszú néhány névnél kiiratni. |
Szerző: | WaReZuM [2015.10.02. 18:15 ] |
Hozzászólás témája: | Re: frag elosztó |
mforce írta: Valahonnan TÚL ismerős... ![]() A másik támadó nevét viszont nem írja. Sőt ez így is túl hosszú néhány névnél kiiratni. Milyen másik támadó? 1 támadó van a másik a támadott(enemy). 51 hit-nél írja ki. Egyébként igen. Tiedről vettem ![]() |
Szerző: | mforce [2015.10.02. 18:17 ] |
Hozzászólás témája: | Re: frag elosztó |
SMA Forráskód: [ Mindet kijelol ]
|
Szerző: | WaReZuM [2015.10.02. 18:22 ] |
Hozzászólás témája: | Re: frag elosztó |
mforce írta: SMA Forráskód: [ Mindet kijelol ]#include <amxmodx>#include <fun>#include <cstrike> #define PREFIX "ProKillers" //#define LIVE_UPDATE #define IsValidPlayers(%1,%2) ((1 <= %1 <= 32) && (1 <= %2 <= 32)) new g_iAssist[33];new g_iAssDamage[33][33]; public plugin_init(){ register_plugin("Lite frageloszto", "1.17", "neugomon"); register_event("HLTV", "eRoundStart", "a", "1=0", "2=0"); register_event("DeathMsg", "eDeathMsg", "a", "1>0"); register_event("Damage", "eDamage", "be", "2!0", "3=0", "4!0");} public client_disconnect(id) ResetAssist(id); public eRoundStart(){ new pl[32], pnum; get_players(pl, pnum); for(new i; i < pnum; i++) ResetAssist(pl[i]);} public eDeathMsg(){ static pKiller, pVictim; pKiller = read_data(1); pVictim = read_data(2); if(pKiller == pVictim || pKiller == g_iAssist[pVictim] || !is_user_connected(g_iAssist[pVictim])) return; cs_set_user_money(g_iAssist[pVictim], cs_get_user_money(g_iAssist[pVictim]) + 300); static iFrags; iFrags = get_user_frags(g_iAssist[pVictim]) + 1; set_user_frags(g_iAssist[pVictim], iFrags);#if defined LIVE_UPDATE static mScoreInfo; if(!mScoreInfo) mScoreInfo = get_user_msgid("ScoreInfo"); message_begin(MSG_ALL, mScoreInfo); write_byte(g_iAssist[pVictim]); write_short(iFrags); write_short(get_user_deaths(g_iAssist[pVictim])); write_short(0); write_short(get_user_team(g_iAssist[pVictim])); message_end();#endif static victim[32]; get_user_name(pVictim, victim, charsmax(victim)); ChatColor(g_iAssist[pVictim], "^4[%s] ^1Kaptál ^4+1 ^1fraget, mert besegítettél ^3%s ^1megölésében.", PREFIX, victim); ResetAssist(pVictim);} public eDamage(id){ static pAttacker; pAttacker = get_user_attacker(id); if(id == pAttacker || !IsValidPlayers(id, pAttacker)) return; g_iAssDamage[id][pAttacker] += read_data(2); if(!g_iAssist[id] && g_iAssDamage[id][pAttacker] >= 50) g_iAssist[id] = pAttacker;} ResetAssist(id){ g_iAssist[id] = 0; arrayset(g_iAssDamage[id], 0, sizeof g_iAssDamage[]);} stock ChatColor(id, const szMessage[], any:...){ static szMsg[190], IdMsg; vformat(szMsg, charsmax(szMsg), szMessage, 3); if(!IdMsg) IdMsg = get_user_msgid("SayText"); message_begin(MSG_ONE, IdMsg, .player = id); write_byte(id); write_string(szMsg); message_end();} Köszöntem ![]() |
Szerző: | mforce [2015.10.02. 18:24 ] |
Hozzászólás témája: | Re: frag elosztó |
Ahhoz kell, de EHHEZ nem ![]() |
Oldal: 1 / 1 | Minden időpont UTC+02:00 időzóna szerinti |
Powered by phpBB® Forum Software © phpBB Limited https://www.phpbb.com/ |