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

Wysłany: 2017-12-23, 22:09


Grace

Kierowca Pralki






Wiek: 24
Na forum: 3437 dni
Posty: 168
Nick w MP: Grace

Piwa: 1031

Respekt: 35,8

Mam problem, ot?? event onClientResourceStart wgl sie nie wykonuje.
oto m?j kod:

function starts()
    outputChatBox("Resource started")
    setPlayerHudComponentVisible("all"false)
    showCursor(true)
    showChat(false)
    addEventHandler("onClientRender"getResourceRootElement(), drawPanel)
end
addEventHandler("onClientResourceStart"getResourceRootElement(), starts)


[ Dodano: 2017-12-23, 22:10 ]
Dodam, ?e zmienianie getResourceRootElement() na root, resourceRoot, getRootElement() nie dzia?a :(

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-23, 22:44


koxpl2x22

MAPPER-ALLEREK






Wiek: 23
Na forum: 4556 dni
Posty: 375
Nick w MP: ALLEREK

Piwa: 1726

Respekt: 142,5
Respekt: 142,5

Do czego odnosi si?

    addEventHandler("onClientRender"getResourceRootElement(), drawPanel)

?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-23, 22:52


Grace

Kierowca Pralki






Wiek: 24
Na forum: 3437 dni
Posty: 168
Nick w MP: Grace

Piwa: 1031

Respekt: 35,8


GUIEditor = {
    staticimage = {},
    label = {},
    button = {}
}
function drawPanel()
    GUIEditor.staticimage[1] = guiCreateStaticImage(sX*0/1280sY*0/720sX*1280/1280sY*720/720":truck_login/images/tlo.png"false)
    GUIEditor.login guiCreateEdit(sX*526/1280sY*322/720sX*228/1280sY*52/720""falseGUIEditor.staticimage[1])
    GUIEditor.pass guiCreateEdit(sX*525/1280sY*414/720sX*229/1280sY*53/720""falseGUIEditor.staticimage[1])
    guiEditSetMasked(GUIEditor.passtrue)
    GUIEditor.button[1] = guiCreateStaticImage(sX*579/1280sY*475/720sX*124/1280sY*32/720":truck_login/images/zaloguj.png"falseGUIEditor.staticimage[1])
    GUIEditor.button[2] = guiCreateStaticImage(sX*579/1280sY*509/720sX*124/1280sY*32/720":truck_login/images/zarejestruj.png"falseGUIEditor.staticimage[1])
    if data.info then GUIEditor.label[1] = guiCreateLabel(sX*483sY*248/720sX*314/1280sY*22/720"Dokona?e? pomy?lnej rejestracji!"falseGUIEditor.staticimage[1]) end
    guiSetFont(GUIEditor.label[1], "default-bold-small")
    guiLabelSetHorizontalAlign(GUIEditor.label[1], "center"false)    
end


to chyba nie chodzi o to, bo nawet wiadomo?? si? nie wysy?a ;c

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-23, 22:57


koxpl2x22

MAPPER-ALLEREK






Wiek: 23
Na forum: 4556 dni
Posty: 375
Nick w MP: ALLEREK

Piwa: 1726

Respekt: 142,5
Respekt: 142,5


addEventHandler"onClientResourceStart"getRootElement(),function()
  outputChatBox("Resource started")
    setPlayerHudComponentVisible("all"false)
    showCursor(true)
    showChat(false)
    addEventHandler("onClientRender"getResourceRootElement(), drawPanel)
end)

sprawd? to

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-23, 22:58


Grace

Kierowca Pralki






Wiek: 24
Na forum: 3437 dni
Posty: 168
Nick w MP: Grace

Piwa: 1031

Respekt: 35,8

Nic mi to nie daje, probowalem z root, i resourceRoot, nic a nic :(

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-23, 23:03


koxpl2x22

MAPPER-ALLEREK






Wiek: 23
Na forum: 4556 dni
Posty: 375
Nick w MP: ALLEREK

Piwa: 1726

Respekt: 142,5
Respekt: 142,5

Ale sprawdzi?e? to czy po prostu m?wisz z g?ry?
Je?li to nie dzia?a zmien
end)
na
end);
poniewa? tutaj widze co? takiego

Więcej informacji znajdziesz w Wikipedii MTA:

OnClientResourceStart


Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-23, 23:05


Grace

Kierowca Pralki






Wiek: 24
Na forum: 3437 dni
Posty: 168
Nick w MP: Grace

Piwa: 1031

Respekt: 35,8

Sprawdza?em ju? wszystko, nawet dodawalem do ko?ca ka?dej funckji ?rednik, nic nie pomaga?o

[ Dodano: 2017-12-23, 23:11 ]
Progress, wgl nie dzia?a mi strona client-side:
nawet jak mam:
 addCommandHandler("panel", function(plrcmd)
    outputChatBox("Uzywasz /panel, "..name)
end)


Nie dzia?a nic, sprawdza?em mete, zmienialem nazwy, o co tu chodzi XD

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-23, 23:22


koxpl2x22

MAPPER-ALLEREK






Wiek: 23
Na forum: 4556 dni
Posty: 375
Nick w MP: ALLEREK

Piwa: 1726

Respekt: 142,5
Respekt: 142,5

poka? meta.xml to ci odpowiem :)

Postaw piwo autorowi tego posta
 

 
Wysłany: 2017-12-24, 16:30


luki123luki123

Place Game






Wiek: 28
Na forum: 5275 dni
Posty: 1948
Nick w MP: LuKiO

Piwa: 6101

Respekt: 611
Respekt: 611Respekt: 611

xMaslo, po jakiego grzyba renderujesz obiekty CEGUI? Ich si? nie renderuje tylko funkcj? dx.......


GUIEditor = {
    staticimage = {},
    label = {},
    button = {}
}

    GUIEditor.staticimage[1] = guiCreateStaticImage(sX*0/1280sY*0/720sX*1280/1280sY*720/720":truck_login/images/tlo.png"false)
    guiSetVisibleGUIEditor.staticimage[1], false )
    GUIEditor.login guiCreateEdit(sX*526/1280sY*322/720sX*228/1280sY*52/720""falseGUIEditor.staticimage[1])
    GUIEditor.pass guiCreateEdit(sX*525/1280sY*414/720sX*229/1280sY*53/720""falseGUIEditor.staticimage[1])
    guiEditSetMasked(GUIEditor.passtrue)
    GUIEditor.button[1] = guiCreateStaticImage(sX*579/1280sY*475/720sX*124/1280sY*32/720":truck_login/images/zaloguj.png"falseGUIEditor.staticimage[1])
    GUIEditor.button[2] = guiCreateStaticImage(sX*579/1280sY*509/720sX*124/1280sY*32/720":truck_login/images/zarejestruj.png"falseGUIEditor.staticimage[1])
    if data.info then GUIEditor.label[1] = guiCreateLabel(sX*483sY*248/720sX*314/1280sY*22/720"Dokona?e? pomy?lnej rejestracji!"falseGUIEditor.staticimage[1]) end
    guiSetFont(GUIEditor.label[1], "default-bold-small")
    guiLabelSetHorizontalAlign(GUIEditor.label[1], "center"false)    


addEventHandler"onClientResourceStart"getRootElement(),function()
  outputChatBox("Resource started")
    setPlayerHudComponentVisible("all"false)
    showCursor(true)
    showChat(false)
    guiSetVisibleGUIEditor.staticimage[1], true )
end)


Postaw piwo autorowi tego posta
 

 
Tagi: onclientresourcestart :: nie :: działa
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