Flex2 icon indicating copy to clipboard operation
Flex2 copied to clipboard

Add support for sprite linking and detecting duplicates.

Open Nichloya opened this issue 1 year ago • 4 comments

Please, add option for linking sprites.

My mapping uses links to one sprite Map_GiantBall_2C:

Map_GiantBall_0:   dc.w Map_GiantBall_12-Map_GiantBall
Map_GiantBall_2:   dc.w Map_GiantBall_2C-Map_GiantBall
Map_GiantBall_4:   dc.w Map_GiantBall_2C-Map_GiantBall
Map_GiantBall_6:   dc.w Map_GiantBall_2C-Map_GiantBall
Map_GiantBall_8:   dc.w Map_GiantBall_2C-Map_GiantBall
Map_GiantBall_A:   dc.w Map_GiantBall_2C-Map_GiantBall
Map_GiantBall_C:   dc.w Map_GiantBall_2C-Map_GiantBall
Map_GiantBall_E:   dc.w Map_GiantBall_12-Map_GiantBall
Map_GiantBall_10:   dc.w Map_GiantBall_E2-Map_GiantBall

After saving in Flex2 links have been replaced with duplicates:

Map_GiantBall_2:   dc.w Map_GiantBall_2C-Map_GiantBall
Map_GiantBall_4:   dc.w Map_GiantBall_46-Map_GiantBall
Map_GiantBall_6:   dc.w Map_GiantBall_60-Map_GiantBall
Map_GiantBall_8:   dc.w Map_GiantBall_7A-Map_GiantBall
Map_GiantBall_A:   dc.w Map_GiantBall_94-Map_GiantBall
Map_GiantBall_C:   dc.w Map_GiantBall_AE-Map_GiantBall
Map_GiantBall_E:   dc.w Map_GiantBall_C8-Map_GiantBall
Map_GiantBall_10:   dc.w Map_GiantBall_E2-Map_GiantBall

The same thing happens to DPLC too

It will be great if you add option for autolinking optimisation to

Nichloya avatar Nov 27 '24 17:11 Nichloya

Good idea! I'll try and do this

kirjavascript avatar Nov 27 '24 18:11 kirjavascript

It would be great if the Flex2 tried to optimize mappings. Duplicates take up space in the ROM. And that's troubling.

TheBlad768 avatar Nov 28 '24 17:11 TheBlad768

There are optimizations that take place, just not deduping (yet)

Traditionally, you would do this by hand - but it should be automatable

kirjavascript avatar Nov 28 '24 22:11 kirjavascript

I understand that...

I had to fix the mapping links for Sonic + Super Sonic by hand since Flex2 can't do it

And the problem is that if I reuse Flex2, my work is just erased. And there are other big objects here

If I fix the links for mappings, Flex2 keeps duplicates again. And I'll feel like I've wasted my time...

TheBlad768 avatar Nov 29 '24 00:11 TheBlad768