libertyernie / brawltools

BrawlBox and BrawlLib
http://forums.kc-mm.com/index.php?topic=67847.0
142 stars 31 forks source link

getting "unable to cast object type 'Brawl Lib.SSBB..." error #194

Closed nanogram closed 5 years ago

nanogram commented 6 years ago

I get this error when I try to edit home_eng.pac file for ssbb, its in files/system/homebutton

libertyernie commented 6 years ago

Can you either copy/paste the error or post a screenshot? If not, I might be able to take a look at some point.

nanogram commented 6 years ago

capture

nanogram commented 6 years ago

also, whenever I import new images(like above), brawlbox shrinks down A LOT this is before importing new image capture2 this after imported capture3

libertyernie commented 6 years ago

That shrinking problem is a known issue when using a high-DPI display. I've never figured out how to fix it.

nanogram commented 6 years ago

Yeah, I’m using a 4K laptop screen. But I also used a 1080 screen in the past and had the same issue with shrinking...

soopercool101 commented 5 years ago

That shrinking problem is a known issue when using a high-DPI display. I've never figured out how to fix it.

In case you don't already know, the issue is on the first line of the LoadImagesPreservingPaletteInfo function (the filestream declaration). Makes no sense to me as of why that would be the case, and the only way I've found of fixing it is removing the palette preservation functionality for PNGs entirely, but I know it's that line that causes the resize according to those who experience that glitch.

libertyernie commented 5 years ago

Nice tip. Also, it looks like even after removing LoadImagesPreservingPaletteInfo, I can still import palettes from indexed PNG files. Maybe GDI supports it now?

soopercool101 commented 5 years ago

From what I've seen, removing that function removes color smash support (the new method in which CSS portraits are made to share an image with different palettes), though I may be mistaken