admin Дата: Вторник, 13.09.2011, 16:22:59 | Сообщение # 1
Группа: Администраторы
Сообщений: 3869
Верху мода: Code
native PlayAudioStreamForPlayer(playerid, url[], Float:posX = 0.0, Float:posY = 0.0, Float:posZ = 0.0, Float:distance = 50.0, usepos = 0); //это функция почитать можно пройдя по ссылке:http://www.forum-pawno.ucoz.com/forum/5-2317-1 new PlayerTotalKills[MAX_PLAYERS] = 0; new string[128];
После этого ищем public OnPlayerDeath и туда вставляем: Code
new Name[128]; GetPlayerName(killerid, Name, sizeof(Name)); PlayerTotalKills[killerid] = PlayerTotalKills[killerid] +1; PlayerTotalKills[playerid] = 0; if(PlayerTotalKills[killerid] == 1) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/firstblood.mp3"); format(string, sizeof(string), "~r~%s FIRST BLOOD", Name); GameTextForAll(string, 6000,3); } if(PlayerTotalKills[killerid] == 2) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/doublekill.mp3"); format(string, sizeof(string), "~r~%s DOUBLE KILL.", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 3) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/killingspree.mp3"); format(string, sizeof(string), "~r~%s KILLING SPREE", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 4) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/dominating.mp3"); format(string, sizeof(string), "~r~%s IS DOMINATING", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 5) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/triplekill.mp3"); format(string, sizeof(string), "~r~%s TRIPLE KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 7) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/monsterkill.mp3"); format(string, sizeof(string), "~r~%s MONSTER KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 9) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/wickedsick.mp3"); format(string, sizeof(string), "~r~%s WICKED SICK", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 11) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ludicrouskill.mp3"); format(string, sizeof(string), "~r~%s LUDICROUS KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 13) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ultrakill.mp3"); format(string, sizeof(string), "~r~%s ULTRA KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 15) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/unstoppable.mp3"); format(string, sizeof(string), "~r~%s IS UNSTOPPABLE", Name); GameTextForAll(string, 6000,3); return 1; }
Примерно так должен быть public: Code
public OnPlayerDeath(playerid, killerid, reason) { new Name[128]; GetPlayerName(killerid, Name, sizeof(Name)); PlayerTotalKills[killerid] = PlayerTotalKills[killerid] +1; PlayerTotalKills[playerid] = 0; if(PlayerTotalKills[killerid] == 1) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/firstblood.mp3"); format(string, sizeof(string), "~r~%s FIRST BLOOD", Name); GameTextForAll(string, 6000,3); } if(PlayerTotalKills[killerid] == 2) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/doublekill.mp3"); format(string, sizeof(string), "~r~%s DOUBLE KILL.", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 3) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/killingspree.mp3"); format(string, sizeof(string), "~r~%s KILLING SPREE", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 4) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/dominating.mp3"); format(string, sizeof(string), "~r~%s IS DOMINATING", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 5) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/triplekill.mp3"); format(string, sizeof(string), "~r~%s TRIPLE KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 7) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/monsterkill.mp3"); format(string, sizeof(string), "~r~%s MONSTER KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 9) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/wickedsick.mp3"); format(string, sizeof(string), "~r~%s WICKED SICK", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 11) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ludicrouskill.mp3"); format(string, sizeof(string), "~r~%s LUDICROUS KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 13) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ultrakill.mp3"); format(string, sizeof(string), "~r~%s ULTRA KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 15) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/unstoppable.mp3"); format(string, sizeof(string), "~r~%s IS UNSTOPPABLE", Name); GameTextForAll(string, 6000,3); return 1; } return 1; }
Где ссылки указаны там они стоят на звуки. Так же можно будет изменить звуки на свои. Урок by - 26_RUSSS
zm-jail.ru Разработка сайта samp-pawno.ru
Сообщение Верху мода: Code
native PlayAudioStreamForPlayer(playerid, url[], Float:posX = 0.0, Float:posY = 0.0, Float:posZ = 0.0, Float:distance = 50.0, usepos = 0); //это функция почитать можно пройдя по ссылке:http://www.forum-pawno.ucoz.com/forum/5-2317-1 new PlayerTotalKills[MAX_PLAYERS] = 0; new string[128];
После этого ищем public OnPlayerDeath и туда вставляем: Code
new Name[128]; GetPlayerName(killerid, Name, sizeof(Name)); PlayerTotalKills[killerid] = PlayerTotalKills[killerid] +1; PlayerTotalKills[playerid] = 0; if(PlayerTotalKills[killerid] == 1) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/firstblood.mp3"); format(string, sizeof(string), "~r~%s FIRST BLOOD", Name); GameTextForAll(string, 6000,3); } if(PlayerTotalKills[killerid] == 2) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/doublekill.mp3"); format(string, sizeof(string), "~r~%s DOUBLE KILL.", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 3) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/killingspree.mp3"); format(string, sizeof(string), "~r~%s KILLING SPREE", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 4) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/dominating.mp3"); format(string, sizeof(string), "~r~%s IS DOMINATING", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 5) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/triplekill.mp3"); format(string, sizeof(string), "~r~%s TRIPLE KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 7) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/monsterkill.mp3"); format(string, sizeof(string), "~r~%s MONSTER KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 9) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/wickedsick.mp3"); format(string, sizeof(string), "~r~%s WICKED SICK", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 11) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ludicrouskill.mp3"); format(string, sizeof(string), "~r~%s LUDICROUS KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 13) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ultrakill.mp3"); format(string, sizeof(string), "~r~%s ULTRA KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 15) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/unstoppable.mp3"); format(string, sizeof(string), "~r~%s IS UNSTOPPABLE", Name); GameTextForAll(string, 6000,3); return 1; }
Примерно так должен быть public: Code
public OnPlayerDeath(playerid, killerid, reason) { new Name[128]; GetPlayerName(killerid, Name, sizeof(Name)); PlayerTotalKills[killerid] = PlayerTotalKills[killerid] +1; PlayerTotalKills[playerid] = 0; if(PlayerTotalKills[killerid] == 1) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/firstblood.mp3"); format(string, sizeof(string), "~r~%s FIRST BLOOD", Name); GameTextForAll(string, 6000,3); } if(PlayerTotalKills[killerid] == 2) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/doublekill.mp3"); format(string, sizeof(string), "~r~%s DOUBLE KILL.", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 3) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/killingspree.mp3"); format(string, sizeof(string), "~r~%s KILLING SPREE", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 4) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/dominating.mp3"); format(string, sizeof(string), "~r~%s IS DOMINATING", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 5) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/triplekill.mp3"); format(string, sizeof(string), "~r~%s TRIPLE KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 7) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/monsterkill.mp3"); format(string, sizeof(string), "~r~%s MONSTER KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 9) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/wickedsick.mp3"); format(string, sizeof(string), "~r~%s WICKED SICK", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 11) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ludicrouskill.mp3"); format(string, sizeof(string), "~r~%s LUDICROUS KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 13) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/ultrakill.mp3"); format(string, sizeof(string), "~r~%s ULTRA KILL", Name); GameTextForAll(string, 6000,3); return 1; } if(PlayerTotalKills[killerid] == 15) { PlayAudioStreamForPlayer(playerid, "http://www.pamp3.site40.net/quake/unstoppable.mp3"); format(string, sizeof(string), "~r~%s IS UNSTOPPABLE", Name); GameTextForAll(string, 6000,3); return 1; } return 1; }
Где ссылки указаны там они стоят на звуки. Так же можно будет изменить звуки на свои. Урок by - 26_RUSSS Автор - admin Дата добавления - 13.09.2011 в 16:22:59