POP EDITION LEVEL HELP

David
The Prince of Persia
The Prince of Persia
Posts: 2877
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: POP EDITION LEVEL HELP

Post by David »

I tried it, and: The problem is that GIMP saves BMP files that have bigger header than those exported by PR.
PR expects 0x28 (40) byte headers, but GIMP saves 0x6C (108) byte headers. (see here)
The first problem is that PR does not accept BMP files if the size of their headers are not 40 bytes.
The second problem is that PR does not show any error message when this happens.
Norbert, I just fixed both problems in my copy of PR.
(Did you make the images of your mod with GIMP? If you did, then did you meet this bug?)
Kamil, thanks for pointing it out. :)

Solution:
In GIMP, when you export to BMP, use the "Export... (Shift-Ctrl-E)" menu item, and not the "Export to whatever.bmp (Ctrl-E)" or "Overwrite whatever.bmp".
After you press Export, click "Replace". Then a small window will appear.
It contains a "[+] compatibility settings". Open it, and check the "don't write colorspace information" checkbox. Click "Export".
kamil9595pl
Sheikh
Sheikh
Posts: 36
Joined: July 31st, 2013, 5:28 pm

Re: POP EDITION LEVEL HELP

Post by kamil9595pl »

david what format save please?
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5786
Joined: April 9th, 2009, 10:58 pm

Re: POP EDITION LEVEL HELP

Post by Norbert »

Image
(mirror)

I didn't test this yet, but this is what David suggests.
kamil9595pl
Sheikh
Sheikh
Posts: 36
Joined: July 31st, 2013, 5:28 pm

Re: POP EDITION LEVEL HELP

Post by kamil9595pl »

does not work it gave nothing, please help me here I die:((((((((((((((((
Last edited by kamil9595pl on August 2nd, 2013, 9:34 pm, edited 1 time in total.
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5786
Joined: April 9th, 2009, 10:58 pm

Re: POP EDITION LEVEL HELP

Post by Norbert »

kamil9595pl, as promised I've analyzed the files you've sent me.

Your problem is that you save the images as RGB images.
You should save them as indexed images, that have their own colormaps.

Image
(mirror)

See page 7 of this document.
When you edit images, only use the Colormap window for selecting colors.

You need to get yourself a new copy of the game, and start from scratch.
Use PR to extract the images, use GIMP and only use the Colormap window to select images.
Then simply save the image over the original image, and use PR to import the changes.
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5786
Joined: April 9th, 2009, 10:58 pm

Re: POP EDITION LEVEL HELP

Post by Norbert »

David, I'm unaware of the problem you describe, and the problem that kamil9595pl is running into is caused by something different (see my previous post).
I used GIMP 2.6 for Prince of Wateria.
I will make a test change to the BMP file kamil9595pl is trying to change with GIMP 2.8, to see if I run into the problem you mentioned.
If I can replicate the problem and your recent changes to PR fix that problem, you/we should of course release PR 1.3.1 :)
kamil9595pl
Sheikh
Sheikh
Posts: 36
Joined: July 31st, 2013, 5:28 pm

Re: POP EDITION LEVEL HELP

Post by kamil9595pl »

why there you have nothing ''COLOR MAP''
? is it my fault? or what I'm doing wrong, please describe exactly: (
Attachments
bez tytułu.JPG
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5786
Joined: April 9th, 2009, 10:58 pm

Re: POP EDITION LEVEL HELP

Post by Norbert »

Norbert wrote:I will make a test change to the BMP file kamil9595pl is trying to change with GIMP 2.8, to see if I run into the problem you mentioned.
David, I did run into the problem. By default, GIMP 2.8 saves to a different version of BMP than it did before.
Please send me a package with the changes you made to PR.
(Including an EXE file, please. Before you compile it, you can change PR_VERSION in src/include/common.h to "v1.3.1".)
I'll release it as PR 1.3.1.

As a side note, no matter how I save with GIMP 2.8 (even when I check "Do not write color space information"), I'm unable to import "single stack main.bmp" back into VDUNGEON.DAT, not with PR 1.1 either.
I'll give it another try when PR 1.3.1 is available. (I know I ran into the same problem as you because feh no longer loads the BMP file.)
kamil9595pl
Sheikh
Sheikh
Posts: 36
Joined: July 31st, 2013, 5:28 pm

Re: POP EDITION LEVEL HELP

Post by kamil9595pl »

I have made this color already ''RGB COLOR'' does not work

how do I save: (please help: (
David
The Prince of Persia
The Prince of Persia
Posts: 2877
Joined: December 11th, 2008, 9:48 pm
Location: Hungary

Re: POP EDITION LEVEL HELP

Post by David »

Norbert wrote:As a side note, no matter how I save with GIMP 2.8 (even when I check "Do not write color space information"), I'm unable to import "single stack main.bmp" back into VDUNGEON.DAT, not with PR 1.1 either.
Oh my. If I save the BMP *with* color space information, and try to reopen it, GIMP opens it as an RGB image, instead of indexed. If I save it again, GIMP converts it into RGB.

But the BMP (after the first save) *is* indexed.
Open it with a hex editor, and find offset 0x1C. It stores the bits-per-pixel of the image.
For 16-color images (like the wall), it is 0x04.
(And offset 0x0E is the header size.)

So this seems to be a GIMP bug.
The good news is that it is already known in the GIMP Bugzilla:
https://bugzilla.gnome.org/show_bug.cgi?id=674391#c16 wrote: My reasoning for saying that there is a fault in GIMP is that when an indexed
file is saved with the colour space information
not only is it not recognised
as an indexed file by other programs it is not recognised as an indexed file by
GIMP
- instead GIMP "Image/Image Properties" shows it as an RGB file rather
than indexed color (16 colors) as it does if the colour space information isn't
saved. If GIMP is saving the file with the colour space information correctly
it isn't reading it correctly - I suspect the save operation.
Anyway, if you always save without colour space information, then everything should work.
https://bugzilla.gnome.org/show_bug.cgi?id=674391#c14 wrote: Looking at the source code last night I realised that if, when I export the
16-colour indexed bitmap, I select "Compatibility Options" and select "Do not
write color space information"
the extra header bytes aren't written (the pixel
data starts at offset 0x76) and the resulting file is recognised correctly (so
far as I can tell) as a 16-colour indexed bitmap by GIMP and the other programs
I have tried so far. This provides a work-around for my current needs and may
help others.
Norbert wrote:When you edit images, only use the Colormap window for selecting colors.
But what if he wants to use different colors?
kamil9595pl
Sheikh
Sheikh
Posts: 36
Joined: July 31st, 2013, 5:28 pm

Re: POP EDITION LEVEL HELP

Post by kamil9595pl »

Please pictures numbered as then because I do not understand too well j POLISH : ( PLEASE :(

please throw someone exactly pictures of gimp: ( numbered :(
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5786
Joined: April 9th, 2009, 10:58 pm

Re: POP EDITION LEVEL HELP

Post by Norbert »

David wrote:If I save the BMP *with* color space information, and try to reopen it, GIMP opens it as an RGB image, instead of indexed. If I save it again, GIMP converts it into RGB.
OMG, how many things could we possibly run into while trying to help someone change graphics.... :shock:
David wrote:But what if he wants to use different colors?
People who want that need to do many mental exercises to boost their IQs and then carefully read and follow the instructions.
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5786
Joined: April 9th, 2009, 10:58 pm

Re: POP EDITION LEVEL HELP

Post by Norbert »

kamil9595pl wrote:please throw someone exactly pictures of gimp: ( numbered :(
kamil9595pl, you need to:
1. Start with a new PoP1 (download the ZIP)
2. Only work with the Colormap
3. Always save with this checkbox checked
kamil9595pl
Sheikh
Sheikh
Posts: 36
Joined: July 31st, 2013, 5:28 pm

Re: POP EDITION LEVEL HELP

Post by kamil9595pl »

which map colors?
What did I do wrong?
how much bits save?
J SET RGB COLOR?
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5786
Joined: April 9th, 2009, 10:58 pm

Re: POP EDITION LEVEL HELP

Post by Norbert »

I will create a video that shows what to do.
Locked