var/icon/i = icon('TitleScreen.png')
w = i.Width()
h = i.Height()
if(!w || !h)
world.log << "ERROR: Width or Height of title screen bugged out!"
//more code to finish up title screen
Like 25% of the time this code will fail to get the width & height of a PNG image for no apparent reason using this same exact code with the same exact image (TitleScreen.png) but it happens with any png. I think this is a BYOND bug but is there something I can do to this code to more reliably get the width & height of this PNG? Thanks.
The other 75% of the time it fetches the width & height just fine and displays the title screen. There is no apparent reason.