Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.

Wysłany: 2015-10-06, 16:16


Fanciak

BOT






Wiek: 25
Na forum: 4446 dni
Posty: 728
Nick w MP: Fanciak

Piwa: 1572

Respekt: 500
Respekt: 500

A sprobuj tak:


function disableTec prevSlotnewSlot )
    if getPedWeapon(getLocalPlayer(),newSlot) == 22 then
        toggleControl "fire"false )
        toggleControl "action"false )
         
        addEventHandler "onClientRender"rootHandleTheRendering )
        addEventHandler "onClientRender"rootcreateText )
        else
        toggleControl "fire"true ) 
        toggleControl "action"true ) 
    end
end
addEventHandler "onClientPlayerWeaponSwitch"getRootElement(), disableTec )



@Up wyprzedziles :v

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-10-06, 16:55


Dexnes_

Tiger






Wiek: 26
Na forum: 4401 dni
Posty: 620
Nick w MP: Dexnes

Piwa: 1394

Respekt: 390
Respekt: 390Respekt: 390Respekt: 390Respekt: 390

Fanciak, twoja blokada dzia?a te? gdy zmienie bro? , DestroY, twoja blokada tez dziala tylko gdy zmienie bro? ;(

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-10-06, 17:14


#404







Wiek: 26
Na forum: 4771 dni
Posty: 1438

Piwa: 2512

Respekt: 833,5
Respekt: 833,5Respekt: 833,5

Ostrzeżeń: 60%
BlackGamePL, w takim razie jak mia?a dzia?a? ?
Masz co? takiego...


function blockShoot()

    if getPedWeapon(localPlayer) == 22 then
                toggleControl("fire"false)
                toggleControl("action"false)
                toggleControl("aim_weapon"false)
    else
                toggleControl("fire"true)
                toggleControl("action"true)    
                toggleControl("aim_weapon"true)
    end
end

addEventHandler("onClientRender"rootblockShoot)



Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-10-06, 17:49


Dexnes_

Tiger






Wiek: 26
Na forum: 4401 dni
Posty: 620
Nick w MP: Dexnes

Piwa: 1394

Respekt: 390
Respekt: 390Respekt: 390Respekt: 390Respekt: 390

DestroY, ja chc? tak aby wgl nie da?o si? bi? , po wej?ciu na serwer blokuje si? bicie z wyznaczonych broni kt?re s? w kodzie.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-10-06, 17:50


Fanciak

BOT






Wiek: 25
Na forum: 4446 dni
Posty: 728
Nick w MP: Fanciak

Piwa: 1572

Respekt: 500
Respekt: 500

function blockShoot()

    if getPedWeapon(localPlayer) == 22 then
                toggleControl("fire"false)
                toggleControl("action"false)
                toggleControl("aim_weapon"false)
    end
end

addEventHandler("onClientResourceStart"rootblockShoot)


Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-10-06, 18:07


Dexnes_

Tiger






Wiek: 26
Na forum: 4401 dni
Posty: 620
Nick w MP: Dexnes

Piwa: 1394

Respekt: 390
Respekt: 390Respekt: 390Respekt: 390Respekt: 390

Fanciak, Nie dziala :/

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-10-06, 18:17


Fanciak

BOT






Wiek: 25
Na forum: 4446 dni
Posty: 728
Nick w MP: Fanciak

Piwa: 1572

Respekt: 500
Respekt: 500

function blokowanieStrzalu()

    if getPedWeapon(localPlayer) == 22 then
        toggleControl("fire"false)
        toggleControl("action"false)
        toggleControl("aim_weapon"false)
    else
        toggleControl("fire"true)
        toggleControl("action"true)
        toggleControl("aim_weapon"true)
    end
end

addEventHandler("onClientRender"rootblokowanieStrzalu)



Musi dzialac

Postaw piwo autorowi tego posta
 

 
Wysłany: 2015-10-06, 18:50


Dexnes_

Tiger






Wiek: 26
Na forum: 4401 dni
Posty: 620
Nick w MP: Dexnes

Piwa: 1394

Respekt: 390
Respekt: 390Respekt: 390Respekt: 390Respekt: 390

<3 Fancik dzia?a moj MiszczUXLua

Bardzo chc? podzi?kowa? DestroY'owi i Fancikowi za pomoc przy tym skrypcie , wielkie dzi?kuje za cierpliwo??,czas i za wszystko ;) Naprawde pomagacie ch?opcy ;)

Do zamkni?cia ;D

Postaw piwo autorowi tego posta
 

 
Tagi: blokada :: bicia :: dla :: poszczególnych :: broni
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA » Blokada bicia dla poszczególnych broni Ten temat jest zablokowany bez możliwości zmiany postów lub pisania odpowiedzi

Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach
Dodaj temat do Ulubionych
Wersja do druku