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

Wysłany: 2020-08-10, 11:38


Lewusek1232







Wiek: 29
Na forum: 2145 dni
Posty: 14
Nick w MP: TheBest



Respekt: 50

Witam. Przychodz? do was z problemem poniewa?, gracze na moim serwerze jak do nich strzelam maj? "godmode" Czyli poprostu regeneruje im si? zdrowie ca?y czas dopiero minigunem da si? zabi?

Paczka:
ogrpg
( mieszaniec ecv2)

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 11:59


VVirmex

Sgrypter luja






Wiek: 21
Na forum: 3365 dni
Posty: 281
Nick w MP: AxyZ

Piwa: 234

Respekt: 110
Respekt: 110

W corze jest funkcja (lub skrypt community) kt?ra zabrania DM pomi?dzy graczami.
Pr?buj szuka? po plikach w corze lub jakiego? skryptu community na antydm :D

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:01


Lewusek1232







Wiek: 29
Na forum: 2145 dni
Posty: 14
Nick w MP: TheBest



Respekt: 50

[quote="VVirmex"]W corze jest funkcja (lub skrypt community) kt?ra zabrania DM pomi?dzy graczami.
Pr?buj szuka? po plikach w corze lub jakiego? skryptu community na antydm :D [/quote]

Wy??czy?em skrypt ogrpg-core i dalej mi si? regeneruje HP a skryptu z nazw? Anty-DM nie mam na serwerze

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:01


VVirmex

Sgrypter luja






Wiek: 21
Na forum: 3365 dni
Posty: 281
Nick w MP: AxyZ

Piwa: 234

Respekt: 110
Respekt: 110

Na PYSie s? na przyk?ad takie funkcje w c_damages:


function stopMinigunDamage attackerweaponbodypart )
    if ( weapon == then 
        cancelEvent()
    end
end
addEventHandler "onClientPlayerDamage"getLocalPlayer(), stopMinigunDamage )

function nodamage(attackerbodypart)
    if not attacker then return end
    if getElementType(attacker) == 'vehicle' then
        cancelEvent()
    end
end
addEventHandler("onClientPlayerDamage"getLocalPlayer(),nodamage)


Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:02


Lewusek1232







Wiek: 29
Na forum: 2145 dni
Posty: 14
Nick w MP: TheBest



Respekt: 50

[quote="VVirmex"][/quote] Jak to mog? usun???

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:04


VVirmex

Sgrypter luja






Wiek: 21
Na forum: 3365 dni
Posty: 281
Nick w MP: AxyZ

Piwa: 234

Respekt: 110
Respekt: 110

Na PYStories takie funkcje istniej? w c_damages, pystories-core. Spr?buj pogrzeba? w corze, mo?e co? znajdziesz :D

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:05


Lewusek1232







Wiek: 29
Na forum: 2145 dni
Posty: 14
Nick w MP: TheBest



Respekt: 50

[quote="VVirmex"]Na PYSie s? na przyk?ad takie funkcje w c_damages:

[lua]
function stopMinigunDamage ( attacker, weapon, bodypart )
if ( weapon == 0 ) then
cancelEvent()
end
end
addEventHandler ( "onClientPlayerDamage", getLocalPlayer(), stopMinigunDamage )

function nodamage(attacker, bodypart)
if not attacker then return end
if getElementType(attacker) == 'vehicle' then
cancelEvent()
end
end
addEventHandler("onClientPlayerDamage", getLocalPlayer(),nodamage)
[/lua][/quote]

Mam takie co?
dmg_c.lua - https://code.skript.pl/YG5kmJxf
I czy je?li usun? ten plik z mety i og?lnie go wywale to b?dzie mi dzia?a? core dalej?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:05


VVirmex

Sgrypter luja






Wiek: 21
Na forum: 3365 dni
Posty: 281
Nick w MP: AxyZ

Piwa: 234

Respekt: 110
Respekt: 110

Usu? tylko funkcj? nodamage i stopMinigunDamage, linijki 75 i 82

[ Dodano: 2020-08-10, 12:06 ]
Potem zapisz plik i zrestartuj cora.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:07


PatryKK.

Emeryt LUA






Wiek: 26
Na forum: 3061 dni
Posty: 1060
Nick w MP: PatryKK.

Piwa: 2322

Respekt: 331,5
Respekt: 331,5Respekt: 331,5Respekt: 331,5

Usu? to:
function blokada prevSlotnewSlot )
    if getPedWeapon(getLocalPlayer(),newSlot) == and getElementData(getLocalPlayer(),"player:admin") == true then 
        toggleControl "fire"true )
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 7 then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"false)
        return false
    elseif getPedWeapon(getLocalPlayer(),newSlot) ~= and  getPedWeapon(getLocalPlayer(),newSlot) ~= 22 then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == true then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == false then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    else
        toggleControl "fire"false ) 
        toggleControl("aim_weapon"false)
    end
end
addEventHandler "onClientPlayerWeaponSwitch"getRootElement(), blokada )


Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:08


VVirmex

Sgrypter luja






Wiek: 21
Na forum: 3365 dni
Posty: 281
Nick w MP: AxyZ

Piwa: 234

Respekt: 110
Respekt: 110

"PatryKK." napisał/a:

Usu? to:
function blokada prevSlotnewSlot )
    if getPedWeapon(getLocalPlayer(),newSlot) == and getElementData(getLocalPlayer(),"player:admin") == true then 
        toggleControl "fire"true )
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 7 then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"false)
        return false
    elseif getPedWeapon(getLocalPlayer(),newSlot) ~= and  getPedWeapon(getLocalPlayer(),newSlot) ~= 22 then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == true then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == false then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    else
        toggleControl "fire"false ) 
        toggleControl("aim_weapon"false)
    end
end
addEventHandler "onClientPlayerWeaponSwitch"getRootElement(), blokada )


+1, nie zauwa?y?em.

Podpis
Kontakt:
Discord: fluffy.rbx
Wiadomość PW Forum [Odpiszę wtedy, kiedy będę mógł]

Support Team: 26.08.2020 do 04.05.2021 [*]
Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:09


Lewusek1232







Wiek: 29
Na forum: 2145 dni
Posty: 14
Nick w MP: TheBest



Respekt: 50

[quote="VVirmex"]Usu? tylko funkcj? nodamage i stopMinigunDamage, linijki 75 i 82

[size=9][ [i][b]Dodano[/b]: 2020-08-10, 12:06[/i] ][/size]
Potem zapisz plik i zrestartuj cora.[/quote]

Robie restart core i dalej nic. Mo?e zrobi? reconnecta? To co? da?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:10


VVirmex

Sgrypter luja






Wiek: 21
Na forum: 3365 dni
Posty: 281
Nick w MP: AxyZ

Piwa: 234

Respekt: 110
Respekt: 110

Usu? to, co ci napisa? Patryk

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:10


killercycDDS

Migacz






Wiek: 25
Na forum: 4512 dni
Posty: 629
Nick w MP: killer_cyc[DDS]

Piwa: 1659

Respekt: 22

"PatryKK." napisał/a:

Usu? to:
function blokada prevSlotnewSlot )
    if getPedWeapon(getLocalPlayer(),newSlot) == and getElementData(getLocalPlayer(),"player:admin") == true then 
        toggleControl "fire"true )
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 7 then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"false)
        return false
    elseif getPedWeapon(getLocalPlayer(),newSlot) ~= and  getPedWeapon(getLocalPlayer(),newSlot) ~= 22 then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == true then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == false then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    else
        toggleControl "fire"false ) 
        toggleControl("aim_weapon"false)
    end
end
addEventHandler "onClientPlayerWeaponSwitch"getRootElement(), blokada )

+ jeszcze regeneracje hp nadaje paralizator wi?kszo?? paczek go ma :D

Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:12


VVirmex

Sgrypter luja






Wiek: 21
Na forum: 3365 dni
Posty: 281
Nick w MP: AxyZ

Piwa: 234

Respekt: 110
Respekt: 110

"killercycDDS" napisał/a:

"PatryKK." napisał/a:

Usu? to:
function blokada prevSlotnewSlot )
    if getPedWeapon(getLocalPlayer(),newSlot) == and getElementData(getLocalPlayer(),"player:admin") == true then 
        toggleControl "fire"true )
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 7 then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"false)
        return false
    elseif getPedWeapon(getLocalPlayer(),newSlot) ~= and  getPedWeapon(getLocalPlayer(),newSlot) ~= 22 then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == true then
        toggleControl ("fire"false ) 
        toggleControl("aim_weapon"true)
    elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == false then
        toggleControl ("fire"true ) 
        toggleControl("aim_weapon"true)
    else
        toggleControl "fire"false ) 
        toggleControl("aim_weapon"false)
    end
end
addEventHandler "onClientPlayerWeaponSwitch"getRootElement(), blokada )

+ jeszcze regeneracje hp nadaje paralizator wi?kszo?? paczek go ma :D


No ale paralizator chyba ma nie zadawa? obra?e? w HP, nie?
Wystarczy ?e usunie to co da?e? wy?ej i tylko paralizator b?dzie mia? tak? funkcj?.

Podpis
Kontakt:
Discord: fluffy.rbx
Wiadomość PW Forum [Odpiszę wtedy, kiedy będę mógł]

Support Team: 26.08.2020 do 04.05.2021 [*]
Postaw piwo autorowi tego posta
 

 
Wysłany: 2020-08-10, 12:12


Lewusek1232







Wiek: 29
Na forum: 2145 dni
Posty: 14
Nick w MP: TheBest



Respekt: 50

[quote="killercycDDS"][quote="PatryKK."]Usu? to:
[lua]function blokada ( prevSlot, newSlot )
if getPedWeapon(getLocalPlayer(),newSlot) == 0 and getElementData(getLocalPlayer(),"player:admin") == true then
toggleControl ( "fire", true )
toggleControl("aim_weapon", true)
elseif getPedWeapon(getLocalPlayer(),newSlot) == 7 then
toggleControl ("fire", false )
toggleControl("aim_weapon", false)
return false
elseif getPedWeapon(getLocalPlayer(),newSlot) ~= 0 and getPedWeapon(getLocalPlayer(),newSlot) ~= 22 then
toggleControl ("fire", true )
toggleControl("aim_weapon", true)
elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == true then
toggleControl ("fire", false )
toggleControl("aim_weapon", true)
elseif getPedWeapon(getLocalPlayer(),newSlot) == 22 and getElementData(getLocalPlayer(),"player:admin") == false then
toggleControl ("fire", true )
toggleControl("aim_weapon", true)
else
toggleControl ( "fire", false )
toggleControl("aim_weapon", false)
end
end
addEventHandler ( "onClientPlayerWeaponSwitch", getRootElement(), blokada )[/lua][/quote]
+ jeszcze regeneracje hp nadaje paralizator wi?kszo?? paczek go ma :D [/quote]


Tak wygl?da kod i dalej nic po restarcie :
https://code.skript.pl/VoKl4G8t

Postaw piwo autorowi tego posta
 

 
Tagi: pomiędzy :: graczami
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA » DM pomiędzy graczami Odpowiedz do tematu

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