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

Wysłany: 2017-01-08, 10:45


Wilkuu*

InsideMTA.pl






Wiek: 24
Na forum: 3714 dni
Posty: 50
Nick w MP: Wilku.

Piwa: 268

Respekt: 30,5

Witam problem odno?nie ?ciany raport?w.W?a?nie nwm czemu nie widz? jak kto? wy?le reporta. Stawiam zimne :piwo: i R*




addCommandHandler("gp",function(plr)
    outputChatBox("Interior: " .. getElementInterior(localPlayer) .. " Dimension: " .. getElementDimension(localPlayer))
    local x,y,z = getElementPosition(localPlayer)
    local xr,yr,zr = getElementRotation(localPlayer)
    p=string.format("%.2f,%.2f,%.2f",x,y,z)
    setClipboard(p)
    outputChatBox("Pozycja gracza: {" ..p.."},")
    --outputChatBox("Pozycja Rotacji: "..xr..", " ..yr..", " ..zr, plr)
    local veh=getPedOccupiedVehicle(localPlayer)
    if veh then
        local x,y,z=getElementPosition(veh)
        local rx,ry,rz=getElementRotation(veh)
        local ID = getElementModel ( veh )
        local Model = getVehicleName ( veh )
        p=string.format("%.2f,%.2f,%.2f,%.1f,%.1f,%.1f",x,y,z,rx,ry,rz)
        setClipboard(p)
        outputChatBox("*Pozycja pojazdu:("..p.."),")
        outputChatBox("*Nazwa Pojazdu:"..Model.." \n*ID Pojazdu "..ID..".")
    end
end)

addCommandHandler("gp2",function(plr)
    outputChatBox("Interior: " .. getElementInterior(localPlayer) .. " Dimension: " .. getElementDimension(localPlayer))
    local x,y,z = getElementPosition(localPlayer)
    local xr,yr,zr = getElementRotation(localPlayer)
    p=string.format("%.2f,%.2f,%.2f",x,y,z)
    setClipboard(p)
    outputChatBox("Pozycja gracza: " ..p.." ")
    outputChatBox("Pozycja rotacji: "..xr..", " ..yr..", " ..zr, plr)
    local veh=getPedOccupiedVehicle(localPlayer)
    if veh then
        local x,y,z=getElementPosition(veh)
        local rx,ry,rz=getElementRotation(veh)
        local ID = getElementModel ( veh )
        local Model = getVehicleName ( veh )
        p=string.format("%.2f,%.2f,%.2f,%.1f,%.1f,%.1f",x,y,z,rx,ry,rz)
        setClipboard(p)
        outputChatBox("*Pozycja pojazdu:("..p.."),")
        outputChatBox("*Nazwa Pojazdu:"..Model.." \n*ID Pojazdu "..ID..".")
    end
end)


local xtext=nil
local gameView={" "}
local reportView={"Lista raport?w:"}
local sx,sy=guiGetScreenSize()

addEventHandler("onClientRender", root, function()
if getElementData(localPlayer, "duty") == 1 or getElementData(localPlayer, "duty") == 2 or getElementData(localPlayer, "duty") == 3 then
    concat=table.concat(gameView, "\n")
    dxDrawText(concat, sx*(10+1)/1024, sy*(279+1)/768, sx*(326+1)/1024, sy*(497+1)/768, tocolor(0, 0, 0, 255), 1.00, "default", "left", "top", false, true)
    dxDrawText(concat, sx*(10)/1024, sy*(279)/768, sx*(326)/1024, sy*(497)/768, white, 1.00, "default", "left", "top", false, true)
end
    end)


function renderingInfo()
    dxDrawRectangle(sx*(258)/1024, sy*(0)/768, sx*(500)/1024, sy*(23)/768, tocolor(0, 0, 0, 155), false)
    dxDrawRectangle(sx*(843)/1280, sy*(536)/600, sx*(427)/1280, sy*(28)/600, tocolor(0, 0, 0, 155), false)
    dxDrawText(xtext, sx*(258+1)/1024, sy*(0+1)/768, sx*(758+1)/1024, sy*(23+1)/768, tocolor(0, 0, 0, 255), 1.00, "default", "center", "center", false, true)
    dxDrawText(xtext, sx*(258)/1024, sy*(0)/768, sx*(758)/1024, sy*(23)/768, tocolor(255, 0, 0, 255), 1.00, "default", "center", "center", false, true)
    dxDrawText(xtext, sx*(860+1)/1280, sy*(542+1)/600, sx*(1260+1)/1280, sy*(560+1)/600, tocolor(0, 0, 0, 255), 1.00, "default", "left", "top", false, false, false, false, false)
    dxDrawText(xtext, sx*(860)/1280, sy*(542)/600, sx*(1260)/1280, sy*(560)/600, tocolor(255, 0, 0, 255), 1.00, "default", "left", "top", false, false, false, false, false)
    dxDrawImage(sx*(1242)/1280, sy*(541)/600, sx*(24)/1280, sy*(19)/600, ":dutyAdministracji/img/mark.png", 0, 0, 0, tocolor(255, 255, 255, 255), false)
end

addEventHandler("onClientRender", root, function()
if getElementData(localPlayer, "duty") == 1 or getElementData(localPlayer, "duty") == 2 or getElementData(localPlayer, "duty") == 3 then
    local tt={}
    for i,v in ipairs(reportView) do
        if v[1] then table.insert(tt,v[1]) end
    end
    concat=table.concat(tt, "\n")
    dxDrawText(concat, sx*(698+1)/1024, sy*(278+1)/768, sx*(1014+1)/1024, sy*(496+1)/768, tocolor(0, 0, 0, 255), 1.00, "default", "right", "top", false, true)
    dxDrawText(concat, sx*(698)/1024, sy*(278)/768, sx*(1014)/1024, sy*(496)/768, tocolor(255, 255, 255, 255), 1.00, "default", "right", "top", false, true)
end
    end)

addEvent("admin:addText", true)
addEventHandler("admin:addText", root, function(text)
    table.insert(gameView, text)
    if #gameView > 20 then
        table.remove(gameView, 1)
    end
end)

addEvent("admin:addReport", true)
addEventHandler("admin:addReport", root, function(text,id)
    table.insert(reportView, {text,id})
    if #reportView > 20 then
        table.remove(reportView, 1)
    end
end)

addEvent("admin:removeReport", true)
addEventHandler("admin:removeReport", root, function(id)
    for i=#reportView, 1, -1 do
        if reportView[i][2] == id then
            table.remove(reportView,i)
        end
    end
end)

addEvent("admin:rendering", true)
addEventHandler("admin:rendering", root, function(text)
    xtext=text
    addEventHandler("onClientRender", root, renderingInfo)
    setTimer(function()
        removeEventHandler("onClientRender", root, renderingInfo)
    end, 5000, 1)
end)


Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 10:50


_Haze

Peace Yo!






Wiek: 25
Na forum: 4325 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

Co restart skryptu report ci si? ?eruj?, jakie? db albo co? si? wy?wietla?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 11:23


Wilkuu*

InsideMTA.pl






Wiek: 24
Na forum: 3714 dni
Posty: 50
Nick w MP: Wilku.

Piwa: 268

Respekt: 30,5

Jak wpisze start dutyadministracji to nic nie wyskakuje.Dopiero jak napisze raport id pow?d to wyskakuje.

http://imgur.com/a/EMpVw

Podpis
InsideMTA.pl

Wilku#2675
Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 11:29


_Haze

Peace Yo!






Wiek: 25
Na forum: 4325 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

Tadzio., poda?e? pe?ny nick

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 11:40


Wilkuu*

InsideMTA.pl






Wiek: 24
Na forum: 3714 dni
Posty: 50
Nick w MP: Wilku.

Piwa: 268

Respekt: 30,5

"Hazmudex" napisał/a:

Tadzio., poda?e? pe?ny nick


Jak by? m?g? to powiedz gdzie ten nick pe?ny.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 12:47


_Haze

Peace Yo!






Wiek: 25
Na forum: 4325 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

Tadzio., podaj strone serwera

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 12:48


Wilkuu*

InsideMTA.pl






Wiek: 24
Na forum: 3714 dni
Posty: 50
Nick w MP: Wilku.

Piwa: 268

Respekt: 30,5

"Hazmudex" napisał/a:

Tadzio., podaj strone serwera


Prosz? strona servera.



addCommandHandler("raport", function(plr,cmd,cel,...)
    if not cel then
        outputChatBox("U?yj: /raport <kawa?ek nick'u> <pow?d>", plr)
        return
    end
    local target = findPlayer(plr,cel)
    if not target then
        outputChatBox("Nie znaleziono podanego gracza.", plr, 255, 0, 0)
        return
    end
    local text=table.concat({...}, " ")
    desc = getPlayerName(plr).."("..getElementData(plr,"id")..") >> "..getPlayerName(target).."("..getElementData(target,"id").."): "..text
    triggerClientEvent(root, "admin:addReport", resourceRoot, desc, getElementData(target,"id"))
    outputChatBox("Pomy?lnie wys?ano zg?oszenie na gracza: "..getPlayerName(target), plr)
end)

addCommandHandler("cl", function(plr,cmd,id,...)
if getElementData(plr, "duty") == 1 or getElementData(plr, "duty") == 2 or getElementData(plr, "duty") == 3 then
    if not tonumber(id) then
        outputChatBox("U?yj: /cl <ID> <pow?d usuni?cia>", plr)
        return
    end
    local reason = table.concat({...}, " ")
    local target = findPlayer(plr,id)
    if target then
        id = getElementData(target, "id")
        opis = getPlayerName(target)
    end
    triggerClientEvent(plr, "admin:removeReport", resourceRoot, id)
    for i,v in ipairs(getElementsByType("player")) do
        if getElementData(plr, "duty") == 1 or getElementData(plr, "duty") == 2 or getElementData(plr, "duty") == 3 then
        if getElementData(v, "duty") == 1 or getElementData(v, "duty") == 2 or getElementData(v, "duty") == 3 then
                outputChatBox(""..getPlayerName(plr).." usun??/??a raport na: "..opis.."/"..id..": "..reason, v, 255, 0, 0)
            end
        end
    end
    end
end)


Ostatnio zmieniony przez Wilkuu* 2017-01-08, 13:54, w całości zmieniany 1 raz  
Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 12:58


_Haze

Peace Yo!






Wiek: 25
Na forum: 4325 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

Tadzio., po 1 chcia?em tylko cz??? reportu a nie ca?y core.
  triggerClientEvent(root, "admin:addReport", resourceRoot, desc, getElementData(target,"id"))

zamiast resourceRoot daj root + mo?liwe ?e nie podajesz prawid?owego nicku

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 13:53


Wilkuu*

InsideMTA.pl






Wiek: 24
Na forum: 3714 dni
Posty: 50
Nick w MP: Wilku.

Piwa: 268

Respekt: 30,5

"Hazmudex" napisał/a:

Tadzio., po 1 chcia?em tylko cz??? reportu a nie ca?y core.
  triggerClientEvent(root, "admin:addReport", resourceRoot, desc, getElementData(target,"id"))

zamiast resourceRoot daj root + mo?liwe ?e nie podajesz prawid?owego nicku



Nick w Sqlit jest dobry oto ss http://imgur.com/uDvn2Zw

A jak zmieni?em to nadal ten sam b??d

addCommandHandler("raport", function(plr,cmd,cel,...)
    if not cel then
        outputChatBox("U?yj: /raport <kawa?ek nick'u> <pow?d>", plr)
        return
    end
    local target = findPlayer(plr,cel)
    if not target then
        outputChatBox("Nie znaleziono podanego gracza.", plr, 255, 0, 0)
        return
    end
    local text=table.concat({...}, " ")
    desc = getPlayerName(plr).."("..getElementData(plr,"id")..") >> "..getPlayerName(target).."("..getElementData(target,"id").."): "..text
    triggerClientEvent(root, "admin:addReport", root, desc, getElementData(target,"id"))
    outputChatBox("Pomy?lnie wys?ano zg?oszenie na gracza: "..getPlayerName(target), plr)
end)

addCommandHandler("cl", function(plr,cmd,id,...)
if getElementData(plr, "duty") == 1 or getElementData(plr, "duty") == 2 or getElementData(plr, "duty") == 3 then
    if not tonumber(id) then
        outputChatBox("U?yj: /cl <ID> <pow?d usuni?cia>", plr)
        return
    end
    local reason = table.concat({...}, " ")
    local target = findPlayer(plr,id)
    if target then
        id = getElementData(target, "id")
        opis = getPlayerName(target)
    end
    triggerClientEvent(plr, "admin:removeReport", resourceRoot, id)
    for i,v in ipairs(getElementsByType("player")) do
        if getElementData(plr, "duty") == 1 or getElementData(plr, "duty") == 2 or getElementData(plr, "duty") == 3 then
        if getElementData(v, "duty") == 1 or getElementData(v, "duty") == 2 or getElementData(v, "duty") == 3 then
                outputChatBox(""..getPlayerName(plr).." usun??/??a raport na: "..opis.."/"..id..": "..reason, v, 255, 0, 0)
            end
        end
    end
    end
end)


Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 13:57


_Haze

Peace Yo!






Wiek: 25
Na forum: 4325 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

Tadzio., chodzi o nick in game.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 14:11


Wilkuu*

InsideMTA.pl






Wiek: 24
Na forum: 3714 dni
Posty: 50
Nick w MP: Wilku.

Piwa: 268

Respekt: 30,5

"Hazmudex" napisał/a:

Tadzio., chodzi o nick in game.


To Tadzio. ale tam trzeba wpisa? login a to nick gdzie?.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 14:22


_Haze

Peace Yo!






Wiek: 25
Na forum: 4325 dni
Posty: 1648
Nick w MP: Haze

Piwa: 2628

Respekt: 1020
Respekt: 1020

Tadzio., /raport nick gracz odwala np. /raport Tadzio. Gracz przeszkadza adminstratorom

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-01-08, 14:34


Wilkuu*

InsideMTA.pl






Wiek: 24
Na forum: 3714 dni
Posty: 50
Nick w MP: Wilku.

Piwa: 268

Respekt: 30,5

"Hazmudex" napisał/a:

Tadzio., /raport nick gracz odwala np. /raport Tadzio. Gracz przeszkadza adminstratorom


Nadal ten sam bl?d

Postaw piwo autorowi tego posta
 

 
Tagi: ściana :: raportów.
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






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