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

Wysłany: 2013-05-11, 22:06


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

Tak w skr?cie zrobi?em gui w kt?rym b?dzie si? pokazywa? czy gracz ma prawo jazdy (i inne) czy nie (element data). Ale nie mog? tego sprawdzi?, bo podczas ?adowania skryptu wyskakuje b??d:= expected near ' (2 linijka)

Nie mam poj?cia o co z tym chodzi.I prosz? sprawd?cie te? czy dobrze zbudowa?em t? funkcje, bo nie jestem pewien. Ma ona dzia?a? tak.

Ja wpisuj? /dowod X i graczowi o nicku "X" pokazuje si? gui.


function showplayercmdnick )?
? ?     if nick then
? ? ? ?     local aplayer getPlayerFromName nick )
? ? ? ?     if aplayer then
guiSetVisible(GUIEditor_Window[1], true)
? showCursor(true)
else
outputChatBox("Nie ma takiego gracza"Player)
end
end
end
addCommandHandler("dowod"show)


Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-11, 22:56


Riot

3X






Wiek: 29
Na forum: 5729 dni
Posty: 1123
Nick w MP: Riot/3X

Piwa: 286

Respekt: 123
Respekt: 123

"hendryczek11" napisał/a:

Ja wpisuj? /dowod X i graczowi o nicku "X" pokazuje si? gui.


Tak to dzia?a? nie bedzie. Client wykonuje si? tylko danemu graczowi, kt?ry np. wpisa? ta komend?.

Musisz to zrobi? tak:

Server:
function test(playercmdnick)
local gracz getPlayerFromName(nick)
if gracz then
triggerClientEvent(gracz"pokazKomus"getRootElement())
end
end 
addCommandHandler("dowod"test)


Client:
function pokaz()
guiSetVisible(GUIEditor_Window[1], true)
showCursor(true)
end
addEvent("pokazKomus"true)
addEventHandler("pokazKomus"getRootElement(), pokaz)


Powinno dzia?a?, ale pisane na szybko :|

Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-11, 23:14


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

2 linijka (ten sam b??d co wcze?niej) Co on oznacza ? Jak mam takie b??dy eliminowa? ?



function Poka2 ()
? ? guiSetVisible(GUIEditor_Window[1], false)
? ? guiSetVisible(GUIEditor_Window[2], true)
? end
addEventHandler("onClientGUIClick"GUIEditor_Button[1], Poka2false)


Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-11, 23:20


Piorun







Wiek: 32
Na forum: 6712 dni
Posty: 1837
Nick w MP: Piorun

Piwa: 516

Respekt: 480,7
Respekt: 480,7

Poka? dok?adnie kt?ra to linijka i b??d (by? mo?e zerkasz nie do tego pliku co powiniene?).

Podpis
Możesz mnie znaleźć na: Facebook
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-11, 23:27


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

Masz racj?, nie wiem jak to si? sta?o.... Przepraszam za pomy?k?.

Ostatnia linijka.

GUIEditor_Label[9] = guiCreateLabel(0.25,0.6573,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[9],0,0,0)
guiSetFont(GUIEditor_Label[9],"default-bold-small")
    guiSetVisible(GUIEditor_Label[9], false)


Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-12, 00:38


Piorun







Wiek: 32
Na forum: 6712 dni
Posty: 1837
Nick w MP: Piorun

Piwa: 516

Respekt: 480,7
Respekt: 480,7

 guiSetVisible(GUIEditor_Label[9], false)

Tu jest b??d? Jaki?

Podpis
Możesz mnie znaleźć na: Facebook
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-12, 20:21


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

Przepraszam ?e dopiero teraz, ale by?em strasznie zaj?ty. Troch? poprzestawia?em i pokombinowa?em i pozby?em si? poprzedniego b??du, ale przeni?s? si? on gdzie indziej, mam jeszcze UTF-8 Ale to nie on blokuje skrypt.





88-function Poka2 ()
89-? ? guiSetVisible(GUIEditor_Window[1], false)
90-? ? guiSetVisible(GUIEditor_Window[2], true)
91-? end
92-addEventHandler("onClientGUIClick"GUIEditor_Button[1], Poka2false)



Dopisz? jeszcze co? czego wcze?niej nie napisa?em. Po wpisaniu komedy otwiera si? 1-sze okno w kt?rym jest kr?tka informacja, i po klikni?ciu Buttonu[1] zamyka si? windows[1], a otwiera si? windows[2].

Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-12, 21:00


Riot

3X






Wiek: 29
Na forum: 5729 dni
Posty: 1123
Nick w MP: Riot/3X

Piwa: 286

Respekt: 123
Respekt: 123

U?ywasz Notepad++? Zakladka Format > Koduj w UTF-8 (Bez BOOM). Ten b??d wyskakuje gdy u?yjesz polskich znak?w, b?dziesz je musia? sobie poprawi? bo wyskocz? Ci "krzaczki" (chyba ?e skopiujesz tre?? ca?ego pliku, zmienisz kodowanie i nadpiszesz, mniej roboty).

Mo?liwe ?e jak zmienisz kodowanie to i b??d zniknie.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-12, 21:27


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

UTF-8 znik?, ale ten drugi b??d nie. Wstawiam gui.



GUIEditor_Window = {}
GUIEditor_Button = {}
GUIEditor_Label = {}
GUIEditor_Image = {}
GUIEditor_Label = {}

GUIEditor_Window[1] = guiCreateWindow(414,173,472,426,"",false)
  guiSetVisible(GUIEditor_Window[1], false)
GUIEditor_Button[1] = guiCreateButton(0.7394,0.9108,0.2267,0.0681,"Otw??rz",true,GUIEditor_Window[1])
guiSetFont(GUIEditor_Button[1],"default-bold-small")
GUIEditor_Button[2] = guiCreateButton(0.0339,0.9108,0.2267,0.0681,"Wyjd??",true,GUIEditor_Window[1])
guiSetFont(GUIEditor_Button[2],"default-bold-small")
GUIEditor_Image[2] = guiCreateStaticImage(0.5127,0.0634,0.4534,0.8286,"dowod.png",true,GUIEditor_Window[1])


GUIEditor_Window[2] = guiCreateWindow(414,173,472,426,"",false)
    guiSetVisible(GUIEditor_Window[2], false)
GUIEditor_Image[2] = guiCreateStaticImage(0.036,0.061,0.9301,0.8357,"dowodopen.png",true,GUIEditor_Window[2])
GUIEditor_Label[1] = guiCreateLabel(478,104,5,5,"",false,GUIEditor_Window[2])
  guiSetVisible(GUIEditor_Label[1], false)
GUIEditor_Button[3] = guiCreateButton(0.7394,0.9108,0.2267,0.0681,"Wyjd??",true,GUIEditor_Window[2])
guiSetFont(GUIEditor_Button[1],"default-bold-small")
GUIEditor_Label[2] = guiCreateLabel(0.1441,0.1056,0.322,0.0352,"PRAWDZIWY",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[2],0,0,0)
guiSetFont(GUIEditor_Label[2],"default-bold-small")
  guiSetVisible(GUIEditor_Label[2], false)
GUIEditor_Label[20] = guiCreateLabel(0.1441,0.1056,0.322,0.0352,"FA??SZYWY",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[20],0,0,0)
guiSetFont(GUIEditor_Label[20],"default-bold-small")
GUIEditor_Label[3] = guiCreateLabel(0.2225,0.1831,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[3],0,0,0)
  guiSetVisible(GUIEditor_Label[20], false)
guiSetFont(GUIEditor_Label[3],"default-bold-small")
GUIEditor_Label[30] = guiCreateLabel(0.2225,0.1831,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[30],0,0,0)
  guiSetVisible(GUIEditor_Label[3], false)
guiSetFont(GUIEditor_Label[30],"default-bold-small")
  guiSetVisible(GUIEditor_Label[30], false)
GUIEditor_Label[4] = guiCreateLabel(0.2225,0.27,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[4],0,0,0)
guiSetFont(GUIEditor_Label[4],"default-bold-small")
  guiSetVisible(GUIEditor_Label[4], falseGUIEditor_Label[40] = guiCreateLabel(0.2225,0.27,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[40],0,0,0)
guiSetFont(GUIEditor_Label[40],"default-bold-small")
  guiSetVisible(GUIEditor_Label[40], false)
GUIEditor_Label[5] = guiCreateLabel(0.2225,0.3521,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[5],0,0,0)
guiSetFont(GUIEditor_Label[5],"default-bold-small")
  guiSetVisible(GUIEditor_Label[5], false)
GUIEditor_Label[50] = guiCreateLabel(0.2225,0.3521,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[50],0,0,0)
guiSetFont(GUIEditor_Label[50],"default-bold-small")
  guiSetVisible(GUIEditor_Label[50], falseGUIEditor_Label[6] = guiCreateLabel(0.25,0.4366,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[6],0,0,0)
guiSetFont(GUIEditor_Label[6],"default-bold-small")
 guiSetVisible(GUIEditor_Label[6], false)
GUIEditor_Label[60] = guiCreateLabel(0.25,0.4366,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[60],0,0,0)
guiSetFont(GUIEditor_Label[60],"default-bold-small")
  guiSetVisible(GUIEditor_Label[60], false)
GUIEditor_Label[7] = guiCreateLabel(0.25,0.5047,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[7],0,0,0)
guiSetFont(GUIEditor_Label[7],"default-bold-small")
    guiSetVisible(GUIEditor_Label[7], false)
GUIEditor_Label[70] = guiCreateLabel(0.25,0.5047,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[70],0,0,0)
guiSetFont(GUIEditor_Label[70],"default-bold-small")
    guiSetVisible(GUIEditor_Label[70], falseGUIEditor_Label[8] = guiCreateLabel(0.25,0.5822,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[8],0,0,0)
guiSetFont(GUIEditor_Label[8],"default-bold-small")
    guiSetVisible(GUIEditor_Label[8], falseGUIEditor_Label[80] = guiCreateLabel(0.25,0.5822,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[80],0,0,0)
guiSetFont(GUIEditor_Label[80],"default-bold-small")
    guiSetVisible(GUIEditor_Label[80], falseGUIEditor_Label[9] = guiCreateLabel(0.25,0.6573,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[9],0,0,0)
guiSetFont(GUIEditor_Label[9],"default-bold-small")
    guiSetVisible(GUIEditor_Label[9], false)
GUIEditor_Label[90] = guiCreateLabel(0.25,0.6573,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[90],0,0,0)
guiSetFont(GUIEditor_Label[90],"default-bold-small")
    guiSetVisible(GUIEditor_Label[90], false)


Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-13, 15:21


Piorun







Wiek: 32
Na forum: 6712 dni
Posty: 1837
Nick w MP: Piorun

Piwa: 516

Respekt: 480,7
Respekt: 480,7

Co? tu nie gra .. pokazujesz b??dy, kt?re powinny zdarzy? si? w linijce, w kt?rej nie ma b??du oO .. zapewne znowu zerkasz do z?ego pliku.

Podpis
Możesz mnie znaleźć na: Facebook
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-13, 16:06


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

Nie no b??d wyskakuje tu gdzie pokaza?em, mam stron? serewera i clienta = "Dowod.lua"


Pokarz? wszystko...


Client = Dowod.lua

GUIEditor_Window = {}
GUIEditor_Button = {}
GUIEditor_Label = {}
GUIEditor_Image = {}
GUIEditor_Label = {}

GUIEditor_Window[1] = guiCreateWindow(414,173,472,426,"",false)
  guiSetVisible(GUIEditor_Window[1], false)
GUIEditor_Button[1] = guiCreateButton(0.7394,0.9108,0.2267,0.0681,"Otw??rz",true,GUIEditor_Window[1])
guiSetFont(GUIEditor_Button[1],"default-bold-small")
GUIEditor_Button[2] = guiCreateButton(0.0339,0.9108,0.2267,0.0681,"Wyjd??",true,GUIEditor_Window[1])
guiSetFont(GUIEditor_Button[2],"default-bold-small")
GUIEditor_Image[2] = guiCreateStaticImage(0.5127,0.0634,0.4534,0.8286,"dowod.png",true,GUIEditor_Window[1])


GUIEditor_Window[2] = guiCreateWindow(414,173,472,426,"",false)
    guiSetVisible(GUIEditor_Window[2], false)
GUIEditor_Image[2] = guiCreateStaticImage(0.036,0.061,0.9301,0.8357,"dowodopen.png",true,GUIEditor_Window[2])
GUIEditor_Label[1] = guiCreateLabel(478,104,5,5,"",false,GUIEditor_Window[2])
  guiSetVisible(GUIEditor_Label[1], false)
GUIEditor_Button[3] = guiCreateButton(0.7394,0.9108,0.2267,0.0681,"Wyjd??",true,GUIEditor_Window[2])
guiSetFont(GUIEditor_Button[1],"default-bold-small")
GUIEditor_Label[2] = guiCreateLabel(0.1441,0.1056,0.322,0.0352,"PRAWDZIWY",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[2],0,0,0)
guiSetFont(GUIEditor_Label[2],"default-bold-small")
  guiSetVisible(GUIEditor_Label[2], false)
GUIEditor_Label[20] = guiCreateLabel(0.1441,0.1056,0.322,0.0352,"FA??SZYWY",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[20],0,0,0)
guiSetFont(GUIEditor_Label[20],"default-bold-small")
GUIEditor_Label[3] = guiCreateLabel(0.2225,0.1831,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[3],0,0,0)
  guiSetVisible(GUIEditor_Label[20], false)
guiSetFont(GUIEditor_Label[3],"default-bold-small")
GUIEditor_Label[30] = guiCreateLabel(0.2225,0.1831,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[30],0,0,0)
  guiSetVisible(GUIEditor_Label[3], false)
guiSetFont(GUIEditor_Label[30],"default-bold-small")
  guiSetVisible(GUIEditor_Label[30], false)
GUIEditor_Label[4] = guiCreateLabel(0.2225,0.27,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[4],0,0,0)
guiSetFont(GUIEditor_Label[4],"default-bold-small")
  guiSetVisible(GUIEditor_Label[4], falseGUIEditor_Label[40] = guiCreateLabel(0.2225,0.27,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[40],0,0,0)
guiSetFont(GUIEditor_Label[40],"default-bold-small")
  guiSetVisible(GUIEditor_Label[40], false)
GUIEditor_Label[5] = guiCreateLabel(0.2225,0.3521,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[5],0,0,0)
guiSetFont(GUIEditor_Label[5],"default-bold-small")
  guiSetVisible(GUIEditor_Label[5], false)
GUIEditor_Label[50] = guiCreateLabel(0.2225,0.3521,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[50],0,0,0)
guiSetFont(GUIEditor_Label[50],"default-bold-small")
  guiSetVisible(GUIEditor_Label[50], falseGUIEditor_Label[6] = guiCreateLabel(0.25,0.4366,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[6],0,0,0)
guiSetFont(GUIEditor_Label[6],"default-bold-small")
 guiSetVisible(GUIEditor_Label[6], false)
GUIEditor_Label[60] = guiCreateLabel(0.25,0.4366,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[60],0,0,0)
guiSetFont(GUIEditor_Label[60],"default-bold-small")
  guiSetVisible(GUIEditor_Label[60], false)
GUIEditor_Label[7] = guiCreateLabel(0.25,0.5047,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[7],0,0,0)
guiSetFont(GUIEditor_Label[7],"default-bold-small")
    guiSetVisible(GUIEditor_Label[7], false)
GUIEditor_Label[70] = guiCreateLabel(0.25,0.5047,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[70],0,0,0)
guiSetFont(GUIEditor_Label[70],"default-bold-small")
    guiSetVisible(GUIEditor_Label[70], falseGUIEditor_Label[8] = guiCreateLabel(0.25,0.5822,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[8],0,0,0)
guiSetFont(GUIEditor_Label[8],"default-bold-small")
    guiSetVisible(GUIEditor_Label[8], falseGUIEditor_Label[80] = guiCreateLabel(0.25,0.5822,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[80],0,0,0)
guiSetFont(GUIEditor_Label[80],"default-bold-small")
    guiSetVisible(GUIEditor_Label[80], falseGUIEditor_Label[9] = guiCreateLabel(0.25,0.6573,0.322,0.0352,"POSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[9],0,0,0)
guiSetFont(GUIEditor_Label[9],"default-bold-small")
    guiSetVisible(GUIEditor_Label[9], false)
GUIEditor_Label[90] = guiCreateLabel(0.25,0.6573,0.322,0.0352,"NIEPOSIADA",true,GUIEditor_Window[2])
guiLabelSetColor(GUIEditor_Label[90],0,0,0)
guiSetFont(GUIEditor_Label[90],"default-bold-small")
    guiSetVisible(GUIEditor_Label[90], false)

function Poka2 ()
  Â  guiSetVisible(GUIEditor_Window[1], false)
  Â  guiSetVisible(GUIEditor_Window[2], true)
  end
addEventHandler("onClientGUIClick"GUIEditor_Button[1], Poka2false)

function pokaz()
guiSetVisible(GUIEditor_Window[1], true)
showCursor(true)
end
addEvent("pokazKomus"true)
addEventHandler("pokazKomus"getRootElement(), pokaz)





function wyjdz1 ()
  Â guiSetVisible(GUIEditor_Window[1], false)
  Â showCursor(false)
 end
addEventHandler("onClientGUIClick"GUIEditor_Button[2], wyjdz1false)




function wyjdz2 ()
  Â guiSetVisible(GUIEditor_Window[2], false)
  Â showCursor(false)
 end
addEventHandler("onClientGUIClick"GUIEditor_Button[3], wyjdz2false)


function s1 (playercmdsprawdz)
if sprawdz then
local data getElementData(getPlayerFromName(sprawdz), "Prawo jazdy Kategorii A")
if data == true then
  Â  guiSetVisible(GUIEditor_Label[3], true) 
else
  Â  guiSetVisible(GUIEditor_Label[30], true)
end
end
end
addEventHandler("onClientGUIClick"GUIEditor_Button[1], s1false)


Server = "Serwer.lua"

function test(playercmdnick)
local gracz getPlayerFromName(nick)
if gracz then
triggerClientEvent(gracz"pokazKomus"getRootElement())
end
end 
addCommandHandler("dowod"test)



Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-14, 14:32


Oski

LUA Scripter






Wiek: 30
Na forum: 5246 dni
Posty: 428
Nick w MP: Oski

Piwa: 56

Respekt: 75,1

W pliku clienta kt?ry poda?e? s? jeszcze elementy konwertowania z?ego kodowania.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-14, 18:01


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

Chodzi o te: ? ? ?
Jak si? ich pozby??

Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-14, 18:51


Tostuch







Wiek: 27
Na forum: 4931 dni
Posty: 483
Nick w MP: Tost

Piwa: 137

Respekt: 110
Respekt: 110

Zwyczajnie usun?? -.-

Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-05-18, 18:42


hendryczek11







Wiek: 30
Na forum: 4903 dni
Posty: 49
Nick w MP: Heniek



Respekt: 50

Mam ju? gui, wy?wietla si? wszystko tak jak trzeba (To nie by? b??d z tymi znaczkami), ale ?le sprawdza element data. Wydaj? dobie prawo jazdy (bez b??d?w w debugu)
No i jak pr?buj? to sprawdzi? to zawsze wychodzi mi ?e nie mam prawa jazdy.
Pokarz? kody.


Cient, Wydawanie prawa:
function KatB()
    local player guiGridListGetItemText (GUIEditor_Grid[2], guiGridListGetSelectedItem (GUIEditor_Grid[2]), 1)
        setElementData(getPlayerFromName(player), "Prawo jazdy Kategorii B"true)
          outputChatBox("Wydales? Prawo Jazdy Kategorii B",player2552000true )
    end
addEventHandler"onClientGUIClick"GUIEditor_Button[7], KatBfalse)





Dow?d, Client:
function s2 (playercmdsprawdz) 
if sprawdz then 
local data getElementData(getPlayerFromName(nick), "Prawo jazdy Kategorii B")    -----B??d
if data == true then 
guiSetVisible(GUIEditor_Label[4], true)  -----posiada
else 
guiSetVisible(GUIEditor_Label[40], true) -----Nie posiada
end 
end 
end 
addEventHandler("onClientGUIClick"GUIEditor_Button[1], s2false)



Dow?d, Server:
function test(playercmdnick)
local gracz getPlayerFromName(nick)
if gracz then
triggerClientEvent(gracz"pokazKomus"getRootElement())
end
end 
addCommandHandler("dowod"test)




Podpis
Postaw piwo autorowi tego posta
 

 
Tagi: nowe :: gui :: stare :: zmory
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






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