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

Wysłany: 2014-11-16, 10:36


Vike4562

LUA <3






Wiek: 28
Na forum: 4937 dni
Posty: 144
Nick w MP: Vike4562

Piwa: 32

Respekt: 61

Witajcie :P Zrobi?em wiadomo?ci kt?re wy?wietlaj? si? w staticimage, jest do nich przypisana ElementData, wszystko dzia?a jak nale?y lecz jest BadArgument tego:
if getElementData(v,"Wiadomosc"then

Dlaczego?

Od razu powiem ?e ElementData jest przypisana do tego i to dzia?a, bo jak usun? ten if to usuwa mi ca?e GUI RPG xD ( jest zrobione na staticimage )

function usunWyswietlaneWiadomosci(
    for _,v in ipairs(getElementsByType("gui-staticimage")) do
        if getElementData(v,"Wiadomosc"then
            destroyElement(v)
        end
    end
end


Oczywi?cie za pomoc leci :arrow: :arrow: :piwo:

Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2014-11-16, 11:43


MeeShuffle

Programista/Grafik






Wiek: 32
Na forum: 4395 dni
Posty: 2758
Nick w MP: Shuffle

Piwa: 8575

Respekt: 535,3
Respekt: 535,3

  for _,v in ipairs(getElementsByType("gui-staticimage")) do


co to za argument p?tli?

Podpis

https://shufflecode.pl
Static Codes and Graphics - Join our discord!
Postaw piwo autorowi tego posta
 

 
Wysłany: 2014-11-16, 11:53


Vike4562

LUA <3






Wiek: 28
Na forum: 4937 dni
Posty: 144
Nick w MP: Vike4562

Piwa: 32

Respekt: 61

Robi p?tle na wszystkie stworzone

Więcej informacji znajdziesz w Wikipedii MTA:

GuiCreateStaticImage


Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2014-11-16, 13:36


MeeShuffle

Programista/Grafik






Wiek: 32
Na forum: 4395 dni
Posty: 2758
Nick w MP: Shuffle

Piwa: 8575

Respekt: 535,3
Respekt: 535,3

theType: The type of element you want a list of. This is the same as the tag name in the .map file, so this can be used with a custom element type if desired. Built in types are:
"player": A player connected to the server
"ped": A ped
"water": A water polygon
"sound": A playing sound
"vehicle": A vehicle
"object": An object
"pickup": A pickup
"marker": A marker
"colshape": A collision shape
"blip": A blip
"radararea": A radar area
"team": A team
"spawnpoint": A spawnpoint
"remoteclient": A remote client connected to the server
"console": The server Console
"projectile": A projectile

[ Dodano: 2014-11-16, 13:36 ]
2 sprawa - destroyElement nie u?ywa si? w c-side na gui.

Podpis

https://shufflecode.pl
Static Codes and Graphics - Join our discord!
Postaw piwo autorowi tego posta
 

 
Wysłany: 2014-11-16, 14:23


Vike4562

LUA <3






Wiek: 28
Na forum: 4937 dni
Posty: 144
Nick w MP: Vike4562

Piwa: 32

Respekt: 61

https://wiki.multitheftauto.com/wiki/Element/GUI/Static_image
U?ywa, nie u?ywa, dzia?a.

Ja si? tylko pytam dla czego wyskakuje BadArgument skoro dzia?a wszystko prawid?owo?

Podpis
Postaw piwo autorowi tego posta
 

 
Wysłany: 2014-11-16, 14:54


MeeShuffle

Programista/Grafik






Wiek: 32
Na forum: 4395 dni
Posty: 2758
Nick w MP: Shuffle

Piwa: 8575

Respekt: 535,3
Respekt: 535,3

Nadawanie poka?.

Podpis

https://shufflecode.pl
Static Codes and Graphics - Join our discord!
Postaw piwo autorowi tego posta
 

 
Wysłany: 2014-11-16, 15:23


Vike4562

LUA <3






Wiek: 28
Na forum: 4937 dni
Posty: 144
Nick w MP: Vike4562

Piwa: 32

Respekt: 61

Wiadomosc "Tekst kt?ry gracz tam napisa?"
OdbiorczaWiadomosc guiCreateStaticImage(0/1024*xpozWiadY/768*y579/1024*x16/768*y":RPG/image/Modern Gui/"..kolorWiadPasek..".png"falseScrollOdbiorczaListaWiadomosci)
setElementData(OdbiorczaWiadomosc"Wiadomosc"Wiadomosc)


Podpis
Postaw piwo autorowi tego posta
 

 
Tagi: getelementdata
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