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

Wysłany: 2018-06-26, 08:56


Kulegg







Wiek: 46
Na forum: 3125 dni
Posty: 283

Piwa: 20

Respekt: 50

Witam, posiadam frakcje samc i paczke PYSA

Chodzi konkretnie o Frakcj? samc, mo?na si? zalogowa?, panel dzia?a i wszystko jest niby git, ale nie mo?na si? wylogowa? z frakcji, jedyny spos?b na wylogowanie si? z frakcji to reconnect, a to bez sensu, czy kto? by mi umia? pom?c? ;/

kod z s_duty:

 --[[
    DevelopersYolos And Spli
]]

local marker=createMarker(-2630.38,631.04,56.34-0.9'cylinder'1.525500)
setElementDimension(marker0)
setElementInterior(marker0)

local t=createElement('text')
setElementData(t,'name','S?u?ba\nSan Andreas Medical Center\n[SAMC]')
setElementDimension(t0)
setElementInterior(t0)
setElementPosition(t,-2630.38,631.04,56.34)





local licz = {}


function isPlayerInFaction(plr)
    local sid=getElementData(plr,'player:sid')
    if not sid then return end

    local result=exports['pystories-db']:dbGet('SELECT 1 FROM pystories_factions WHERE code=? AND sid=? LIMIT 1;'"SAMC"sid)
    if result[1then
        return true
    else
        return false
    end
end

addEventHandler('onMarkerHit'marker, function(el,md)
    if isPlayerInFaction(elthen
        if not getElementData(el,'player:duty'then
            setElementModel(el,274)
            exports['pystories-frakcja-ustawienia']:rozpocznijnaliczanie(el)
            setElementData(el,'player:faction','SAMC')
            local rank exports['pystories-frakcja-ustawienia']:getPlayerFactionRank(el,'SAMC')
            setElementData(el,"player:rank",rank)
        else
            exports['pystories-frakcja-ustawienia']:zatrzymajnaliczanie(el)
            takeWeapon(el,41)
            setElementData(el'player:faction'false)
           setElementData(el,"player:rank",false)
           local skin=getElementData(el,"player:skin")
           setElementModel(elskin)
             setPlayerName(el,getElementData(el,"last:nick"))
           setElementData(el,"last:nick",getPlayerName(el))
           setElementData(el,"last:color",tostring(getPlayerNametagColor(el)))
            --setPlayerNametagColor(el,false)
        end
    else
        outputChatBox('Nie jeste? zatrudniony jako SAMC.'el25500)
    end
end)

function naliczanie(el)
    if isElement(elthen
   local x getElementData(el,"player:workinjob") or 0
   setElementData(el,"player:workinjob",x+1)
   else
    if isTimer(licz[el]) then
    killTimer(licz[el])
    licz[el] = nil
    end
   end
end



Postaw piwo autorowi tego posta
 

 
Wysłany: 2018-06-26, 14:55


Mezo.

Mod-Team






Wiek: 24
Na forum: 3211 dni
Posty: 548
Nick w MP: Mezo

Piwa: 6070

Respekt: 517
Respekt: 517

Masz jakie? b??dy pod debugscript?

Podpis
- Na forum pomagam na miarę swoich możliwości, oraz bezpłatnie.
- Jeżeli potrzebujesz pomocy, pisz do mnie w prywatnej wiadomości, pomoc uzyskasz szybciej.
Współpraca - [email protected]


Użytkownik - 19.08.2017
GTAO MEMBER - 29.03.2019
Support-Team - 03.02.2019 - 07.05.2019
Moderator - 07.05.2019 - 02.08.2020
Mod-Team - 02.08.2020 - 25.03.2022

Postaw piwo autorowi tego posta
 

 
Wysłany: 2018-06-26, 14:59


Xrent

-






Wiek: 21
Na forum: 3047 dni
Posty: 230
Nick w MP: Pazdam

Piwa: 535

Respekt: 295,3
Respekt: 295,3Respekt: 295,3Respekt: 295,3

Ostrzeżeń: 60%
Masz w??czone wszystkie skrypty z frakcji tzn frakcja-ustawienia itd?
Jakie? b??dy w db3
db3 to komenda kt?ra pokazuje b??dy mo?esz odpali? j? jak masz adma
/debugscript 3

Postaw piwo autorowi tego posta
 

 
Wysłany: 2018-06-26, 17:16


Kulegg







Wiek: 46
Na forum: 3125 dni
Posty: 283

Piwa: 20

Respekt: 50

No w?asnie nie pisze mi nic w db3 o tym ;/

Postaw piwo autorowi tego posta
 

 
Wysłany: 2018-06-26, 19:03


Toffiaaak.







Wiek: 23
Na forum: 4410 dni
Posty: 128
Nick w MP: Toffy.

Piwa: 1836

Respekt: 242
Respekt: 242Respekt: 242

local marker=createMarker(-2630.38,631.04,56.34-0.9'cylinder'1.525500)
setElementDimension(marker0)
setElementInterior(marker0)

local t=createElement('text')
setElementData(t,'name','S?u?ba\nSan Andreas Medical Center\n[SAMC]')
setElementDimension(t0)
setElementInterior(t0)
setElementPosition(t,-2630.38,631.04,56.34)





local licz = {}


function isPlayerInFaction(plr)
    local sid=getElementData(plr,'player:sid')
    if not sid then return end

    local result=exports['pystories-db']:dbGet('SELECT 1 FROM pystories_factions WHERE code=? AND sid=? LIMIT 1;'"SAMC"sid)
    if result[1then
        return true
    else
        return false
    end
end

addEventHandler('onMarkerHit'marker, function(el,md)
    if isPlayerInFaction(elthen
        if not getElementData(el,'player:duty'then
            setElementModel(el,274)
            exports['pystories-frakcja-ustawienia']:rozpocznijnaliczanie(el)
            setElementData(el,'player:faction','SAMC')
            local rank exports['pystories-frakcja-ustawienia']:getPlayerFactionRank(el,'SAMC')
            setElementData(el,"player:rank",rank)
            setElementData(el,"player:duty"true)
        else
            exports['pystories-frakcja-ustawienia']:zatrzymajnaliczanie(el)
            takeWeapon(el,41)
            setElementData(el'player:faction'false)
           setElementData(el,"player:rank",false)
           local skin=getElementData(el,"player:skin")
           setElementModel(elskin)
             setPlayerName(el,getElementData(el,"last:nick"))
           setElementData(el,"last:nick",getPlayerName(el))
           setElementData(el,"last:color",tostring(getPlayerNametagColor(el)))
            --setPlayerNametagColor(el,false)
            setElementData(el,"player:duty"false)
        end
    else
        outputChatBox('Nie jeste? zatrudniony jako SAMC.'el25500)
    end
end)

function naliczanie(el)
    if isElement(elthen
   local x getElementData(el,"player:workinjob") or 0
   setElementData(el,"player:workinjob",x+1)
   else
    if isTimer(licz[el]) then
    killTimer(licz[el])
    licz[el] = nil
    end
   end
end


Podpis

Osiągnięcia:
- wygrana w konkursie LUA (kat. średnia) - 05.02.18
- 150 reputacji - 06.02.18
- 100 postów - 06.02.18

Postaw piwo autorowi tego posta
 

 
Tagi: logowanie :: wylogowywanie :: się :: frakcji :: samc
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA 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