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

Wysłany: 2015-02-15, 20:07


Quin







Wiek: 25
Na forum: 4537 dni
Posty: 79

Piwa: 3

Respekt: 38

Witam znalaz?em taki skrypt na to ?e bez wyznaczonego skina zabija gracza lecz gdy ma si? wyznaczony skin (skin o ID 18) i tak zabija a ma nie zabija?. Dodam ?e to jest skrypt do gamemoda DayZ.
Kodzik:
cuboid createColCuboid (-1994.9669,614.15338,-35.01562592110450)
 
Infection_TIMER = { }
Infection_ID "18"

function target(elementdim)
        if dim == true then
                setTimer(target250001elementdim)
        outputChatBox("Masz 5 sekund inaczej umrzesz od wysokiej infekcji!"element)
        end
end
addEventHandler("onColShapeHit"cuboidtarget)
 
addEventHandler("onColShapeLeave"cuboid, function(elementdim)
        local gracz = (getElementType(element) == "player" and element or getVehicleController(element))
        if isTimer(Infection_TIMER[element]) then killTimer(Infection_TIMER[element]) end
end)
 
function Infection_killIntruder(p)
        setElementData(p"blood", -20)
        setTimer(target21001ptrue)
end
 
 
function target2(elementdim)
        if isElementWithinColShape(elementcuboidthen       
                if getElementType(element) == "player" then
                        gracz element
                        if getElementData(gracz"skin") ~= Infection_ID then
                                Infection_TIMER[element] = setTimer(Infection_killIntruder1501gracz)
                        end
                end
        end
end


Ostatnio zmieniony przez Quin 2015-02-16, 10:22, w całości zmieniany 1 raz  
Postaw piwo autorowi tego posta
 

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


dudeks







Wiek: 31
Na forum: 6576 dni
Posty: 171

Piwa: 89

Respekt: 105,3
Respekt: 105,3

cuboid createColSphere 1601.8708496094, -1599.3356933594, -17.837776184082305050 )
ZL_TIMER = { }
ZL_NAME "PolskaLiga"

function target(elementdim)
    if dim == true then
        setTimer(target250001elementdim)

    end
end
addEventHandler("onColShapeHit"cuboidtarget)

addEventHandler("onColShapeLeave"cuboid, function(elementdim)
    local gracz = (getElementType(element) == "player" and element or getVehicleController(element))
    if isTimer(ZL_TIMER[element]) then killTimer(ZL_TIMER[element]) end
end)

function ZL_killIntruder(p)
    setElementData(p"blood", -20)
    setTimer(target21001ptrue)
end

function target2(elementdim)
    if isElementWithinColShape(elementcuboidthen    
        if getElementType(element) == "player" then
            gracz element
            if getElementData(gracz"gang") ~= ZL_NAME then
                ZL_TIMER[element] = setTimer(ZL_killIntruder1501gracz)
            end
        end
    end
end

Zesra?e?, a nie napisa?e?. Dziwnie podobne, nie? Chyba do niczego innego, ni? zmienienia 'ZL' na 'Infection' nie wykorzysta?e? swojej klawiatury
A co do Twojego problemu, "18" to nie to samo co 18.

Postaw piwo autorowi tego posta
 

 
Tagi: zabija :: się :: wymagany :: skin
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