-
Posts
374 -
Joined
-
Last visited
Everything posted by Mc_Trekkie
-
В каком смысле "поток" ?
-
Это баг МТА,имхо. Много раз такое было.
-
Мне что делать не фиг? О_О Как Я понял-вы не можете помочь,ну ладно.
-
function bankrob ( hitPlayer, MatchingDimension ) if getElementType( hitPlayer ) == 'player' then if source == robmarker then if isTimer( robbank ) then outputChatBox( "Bank already robbed", hitPlayer, 255, 255, 0) end else outputChatBox ( "****PRESS N TO ROB!.****", hitPlayer, 255, 0, 0, false ) bindKey ( hitPlayer,"n", "down", function( player ) if isTimer( robbank ) then outputChatBox ( "ERROR", player, 255, 0, 0, false ) else outputChatBox ( "BANK ROBBERY!PROTECT THE ROBBER!", root, 255, 0, 0, false ) setPlayerWantedLevel ( player, 4 ) robbank = setTimer( robb, 10000, 1, player ) robbank1 = setTimer ( bankrob, 10000, 1, player) end end ) end end end addEventHandler( "onMarkerHit", robmarker, bankrob ) Вот,собсна,не работает.Дебаг молчит. Маркер создаётся,Dimension и Interior меняется.
-
Я это понял,т.к на другие строки орал,работал в Editor Лень было считать.
-
Где ты нашёл эти строки? Он даже в таком виде не работает. Не сохраняет лвл.
-
function AlterWantedLevel( pPlayer, iLevel ) local pAccount = getPlayerAccount( pPlayer ); assert( pAccount and not isGuestAccount( pAccount ), "invalid account" ); return setAccountData( pAccount, "wanted_level", iLevel ) and setPlayerWantedLevel( pPlayer, iLevel ); end addEventHandler( "onPlayerSpawn", root, function() local pAccount = getPlayerAccount( source ); assert( pAccount and not isGuestAccount( pAccount ), "invalid account" ); setPlayerWantedLevel( source, tonumber( getAccountData( pAccount, "wanted_level" ) ) or 0 ); end ); addEventHandler( "onPlayerWasted", root, function( iTotalAmmo, pKiller, iKillerWeapon, iBodypart, bStealth ) AlterWantedLevel( pKiller, 1 ); end ); Как-то всё трудно 26,33-Bad Argument Всё ОК.
-
Пример тяжёлый O_O Можно по проще примерчик?Оо
-
Чего не хватает в MTA:SA, чтобы стать популярнее?
Mc_Trekkie replied to MX_Master's topic in Russian / Русский
Ну и каким же образом? Много много png? -
Окай. function trolltest ( ) wantedlevel = getPlayerWantedLevel( source ) end leveltimer = setTimer( trolltest , 5000, 0 ) function setit ( ) setPlayerWantedLevel( source, wantedlevel ) end addEventHandler("onPlayerWasted", getRootElement(), setit) Bad Argument(setPlayerWantedLevel) + Работать будет?
-
Можете написать простой скрипт на сохранение лвл разыск. после смерти и что б менялся этот лвл... А то вот пытаюсь с другом и ничего
-
В XML,вроде,нельзя писать Русский Текст. Лучше в коде пиши. Как проверить-игрок в воде или нет?
-
Панель Ди-джея [99% compleated] Thanks to all!
Mc_Trekkie replied to PSPNoobster's topic in Помощь / Отчеты об ошибках
Помню,как ты вчера с этим парился -
xP, yP, zP = -1695.83, 21.8250, 5.32 -- gate = createObject(971, xP, yP, zP) function gate ( ) if gate == xP, yP, ZP then --Твой код end
-
Чего не хватает в MTA:SA, чтобы стать популярнее?
Mc_Trekkie replied to MX_Master's topic in Russian / Русский
Была бы возможность вставлять видео ,было бы круто (На сервере) -
Спс кэп,уже как бэ давно всё проверял ошибка со строки 5:)
-
Там всё верно,проверка на команды делается,но хп и бабло не убавляется/прибавляется.
-
Молчит,зараза.
-
Не работает)
-
Server: createTeam ( "Medic", 200, 0, 100 ) addEventHandler( 'onPlayerDamage',root, function( attacker, weapon, bodypart, loss ) local health = getElementHealth( source ) if isElement( attacker ) and attacker ~= source and weapon == 41 and health < 100 then local team = getPlayerTeam( attacker ) if team then if getTeamName( team ) == 'Medic' then local money = getPlayerMoney( source ) if money >= 10 then givePlayerMoney( attacker,10 ) takePlayerMoney( source,10 ) setElementHealth( source,getElementHealth( source ) + 10 ) end end end end end ) Client: addEventHandler( 'onClientPlayerDamage',localPlayer, function( attacker, weapon, bodypart, loss ) local health = getElementHealth( source ) if isElement( attacker ) and attacker ~= source and weapon == 41 and health < 100 then local team = getPlayerTeam( attacker ) if team then if getTeamName( team ) == 'Medic' then if getPlayerMoney( ) >= 10 then cancelEvent( ) end end end end end )
-
Cпасиб вам огромное)) Особенно Кениксу GURU
-
addEventHandler( "onClientResourceStart", getResourceRootElement( getThisResource() ), function( ) bindKey( "0", "down", startRadio); end ) function startRadio( thePalyer ) if not sound then sound = playSound('http://217.147.86.151:20175/listen.pls') setSoundVolume(sound, 5) else stopSound (sound) unbindKey ( thePlayer, "0", "down", startRadio ) end end Знаю,говнокод,но это не мой код,просто он щас не может написать тут.) Почему не работает? Надо что б если музыка играется-она остановилась и потом можно было ещё раз её проиграть.
-
function taxi1(thePlayer, seat, jacked) theVehicleID = getElementModel ( source ) if (theVehicleID == 420) and ( seat ~= 0 ) then driver = getVehicleOccupant(source, 0) setTimer (taxitakemoney, 30000, 0) end end addEventHandler ("onVehicleEnter", getRootElement(), taxi1) --function for take money function taxitakemoney( seat, jaked, thePlayer ) givePlayerMoney (driver, 30) takePlayerMoney (thePlayer, 30) end Вот собсна,бабло прибавляется,но не убавляется у игрока.
-
А ты хочешь иконку просто или над головой ТОЛЬКО Админа?
-
Есть говно-код а есть говно-релизации... которыми к сожалению часто приходится пользоваться в SAMP. В MTA со стороны разработчика этого слава богу лишён. Но ты же предлагаешь какашку, которая немыслима даже для SAMP. Какой же тогда вариант ещё сделать, чтобы тряслась камера? Берёшь мышку в руки,начинаешь её трясти!
