Thats cool. I'll try to explain.

When you create a BMAP from a file, the name is lost. End of story.

So if you use a BMAP in a panel, there is NO way to get the original filename.
Code:
PANEL* mainpan = {   ...  bmap = testobjekt;  ...  }


But, if you use a image filename in the panel, like this
Code:
PANEL* mainpan = {   ...  bmap = "Mountainroad.png";  ...  }

then the filename CAN be salvaged.

[in both these examples Ive used global panel definitions, this applies to pan_create()-created panels too]

I wont explain the "how" of my piece of code, unless you ask, as it is pretty advanced struct and pointer stuff.
But basically the engine creates a temporary BMAP based on the filename, and my code just gets that temp name,
and turns it back into a filename as a string.


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial