Vike4562 Posted December 3, 2014 Posted December 3, 2014 Witajcie Prosiłem o pomoc na Forum gtao.pl ale nikt nie pomógł, więc może tu ktoś będzie w stanie mi pomóc A mianowicie, pokazuje się Bad Argument ElementData Od razu powiem że funkcja działa prawidłowo, usuwa to co ma usuwać, tylko że daje Błąd, nie wiem dlaczego function usunWyswietlaneWiadomosci() for _,v in ipairs(getElementsByType("gui-staticimage")) do if getElementData(v,"Wiadomosc") then -- To zwraca błąd destroyElement(v) end end end ElementData jest nadawana w ten sposób, tylko że masowo function LadowanieListy(ID, pozWiadY, kolorWiadPasek, kolorWiadTekst, Nadawca, Tytul, Wiadomosc, Kiedy, Przeczytane) OdbiorczaWiadomosc = guiCreateStaticImage(0/1024*x, pozWiadY/768*y, 579/1024*x, 16/768*y, ":RPG/image/Modern Gui/"..kolorWiadPasek..".png", false, ScrollOdbiorczaListaWiadomosci) setElementData(OdbiorczaWiadomosc, "Wiadomosc", Wiadomosc) -- Tutaj jest nadawana ta ElementData.. setElementData(OdbiorczaWiadomosc, "Przeczytane", Przeczytane) -- I tam reszta funkcji end Proszę o pomoc
Bober Posted December 4, 2014 Posted December 4, 2014 sprawdz to: if isElement(v) and getElementData(v,"Wiadomosc") then
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now