#Empty XML table
1 messages ยท Page 1 of 1 (latest)
haven't tried that. i also don't remember how to print the type, i'm still trying to figure that out
it takes a frame or two before you can access the xml you just set.
i didn't just set it though
and this WAS working yesterday
And you're sure it's there? It's shown in the save/atom?
is that included file stil there too?
yeah
timing related stuff can break randomly
type(something) returns the type BTW, a string
varName = "Hello world!"
print("varName = \n"..logString(type(varName)).."\n"..varName)
varName =
string
Hello World!
no, it's either nil or a table :P
type is table
just in the fucking cosmic case some freaky character broke log printing, you can do e.g.
local size = 0
for _ in pairs(xmlTable) do
size = size + 1
end
print('Size is ' .. size)
but I reaaaaly doubt it
yeah, and what if you do the getXmlTable again inside that Wait you had there?
after 3 seconds or something it was, right?
I wonder if something in your defaults is breaking the xml so that it doesn't throw an error but also doesn't render, so that you end up with "no" xml
ohh, it doesn't render?
yeah, sure. ill check
if you replace your whole xml with just <Panel/> what do your logs show then?
i removed everything from defaults, still returns nil
im gonna remove everything now, and add jsut a panel
wow! stil nil!!
just to be very sure.
Nothing in your code is actually writing xml at any point?
not at this point, no
i am obtaining getXmlTable in order to write xml, but it's not happening at this point
and i can't now, because this is weirdly broken
shoot up a save
it's probably something dumb that we just overlooked
a minimal save :P
ok, that means my json file, right?
yeah, or if it can be reproduced on a single object, it can be a json of this saved object
sadly, this is all global ui xml
BTW I love this threads thing
it would be a nightmare to both parties continued on the main channel
yeah, thanks for doing this!
yes agreed!
where do I look for this log?
which script I mean
ohhh crap it probably folded down to a require
i feel like you're asking me which "file" the script is in? its in the "UI Functions" file, the addXmlViaCode function
yeah, it's just I don't have your source files tree and for me it just collapses into requires
oh, ok
grr and I can't expand them via Ctrl+Z anymore
would you WANT me to send you my "files"?
do you also see that in the console tab
I dunno wtf is going on, I replaced it all with a simple panel + text
no, i don't get any errors
unless i try to access the xmlTable variable (which is nil)
I removed everything in Global UI with a simple Text and it's still not rendering and erroring in console
now, i just opened a new save, made a new ui xml
and printed the getXmlTable just fine, in that new save
without any of my code
do you really have @ and > symbols in your xml classes?
I'm not saying this is the cause, but your xml is pretty involved (I already knew it would be by your previous posts in #scripting to be fair)
yes, i do. it creates nested classes which greatly simplifies the xml for me
i haven't made any changes to the xml today
and this WAS working yesterday
with the @, the >, and everything else
can someone check if it shows any Global XML for you?
I've deleted everything
and I stil get the fucking console error posted above
not sure if I want to now ๐
i had one persistent bug in TTS and after taking weeks of getting it fixed I'm not prepared to risk another
@opal canopy did you change or edit any custom assets?
between when it worked and now
yes, i did
as in, UI assets
i did, yes
!!
which ones?
like 83 of them
lol
yep I removed them all and it works now
oh, awesome! what should i do?
I guess remove them :D
and maybe re-check after every upload
soo have fun doing that 83 times?
PS. you can do that in the save file instead of clicking dot dot dot -> delete on every single one via UI first
in the json? ok
honestly I have no idea
I noticed this error
yeah, i'm seeing that now too
or use .setCustomAssets() or the second parameter in setXmlTable() or setXml()
then apparently that does something with custom assets
aaand thet's the extent of knowledge we can ever have
post a Nolt ticket maybe if you nail down which one did that
lol! how do i find these in the json? sorry
ok, yeah, i see it now
make that
yeah .setCustomAssets wouldn't even need deleting them first, Bone is right, I brainfarted
you know what? its ok
you weren't wrong though, both methods are useful to know
i'd rather start with it in working condition ๐
I also looked through your UI assets menu and every single one of them correctly loaded a thumbnail
so it's probably not a simple as a broken link etc
maybe a weird filename screws that up?
yes, i found a weird file name
ill fix it,
but i'm still getting errors on my end
my table is still null
hang on... it didn't save...
there
it works now! ill just reload my custom assets and see what happens! ๐
in the JSON file, there was an error with a bad mix of an ' and a " in the Grimms' Fairy Tales asset
how's it possible
did you add them manually into the JSON?
possible charset / regional character difference in the filename?
no, i added them using setCustomAsset
i myself must've messed it up though in the table
wowza, you think the parser would catch that with some other error
agreed
good spot though
ohh man I thought you had it right in the table, and some weird char in name made it read malformed like that
I would've spent the night trying to break TTS ins some fun way using that if that was the case lol
that entire line is pretty crappy in the JSON though
indeed! i fixed it. would NEVER have thought of that, dzi. thank you SO MUCH!