16 Bit Fpg -> 8 Bit Fpg


Quiest

I like turtles!
Joined
Sep 2, 2004
Messages
3,411
Age
40
Location
Dteuschland ;)
Everytime I convert my 16 bit fpgs to 8 bit fpgs, FPGEdit says "The generated palette has a precision of [ 100% ]", and the sprites look as normal as they should.

But only in FPGEdit.

When I run the game, all colors are weird!

The only thing that works is the MetalSlug intro.
Why does this work, but every other sprite is messed up?


Of course I changed the set_mode(320,240,16); to set_mode(320,240,8).

Any ideas, how I can make this work correctly?



EDIT: Here is a screenshot of what it looks like:
error5ob.jpg



Oh, and I noticed, that when I load the game directly in the level (without intro&charselect screen) the background&foreground have the right colors, but the player, etc. are still messed up. Thats some damn weird problem.

May this have something to do with using different fpgs palette?
Does FPGEdit create a different palette for each fpg?
If thats the case, what can I do?
 
Quiest posted on Mar 25 2005 at 02:11 PM said:
Everytime I convert my 16 bit fpgs to 8 bit fpgs, FPGEdit says "The generated palette has a precision of [ 100% ]", and the sprites look as normal as they should.

But only in FPGEdit.

When I run the game, all colors are weird!

The only thing that works is the MetalSlug intro.
Why does this work, but every other sprite is messed up?


Of course I changed the set_mode(320,240,16); to set_mode(320,240,8).

Any ideas, how I can make this work correctly?



EDIT: Here is a screenshot of what it looks like:
error5ob.jpg



Oh, and I noticed, that when I load the game directly in the level (without intro&charselect screen) the background&foreground have the right colors, but the player, etc. are still messed up. Thats some damn weird problem.

May this have something to do with using different fpgs palette?
Does FPGEdit create a different palette for each fpg?
If thats the case, what can I do?

I found it easier to start with 8bit FPG

all the pics onscreen need to be the same pallette...

you can have different pallettes for different levels... (thats why the intro is ok)

i only know how to do it with paintshop pro.

open up the pic with the pallette that you want to use and then save the pallette in image options...

IMAGE>PALLETTE>SAVE PALLETTE

then open up a new image and import the pallette into that one...

IMAGE>PALLETTE>LOAD PALLETTE

hope it helps

in return Quiest...

do you know how to limit my ships movements to certain coordinates? im making a shooter... i just want my ship to move backwards and forwards about the middle two quarters - at the minute the ship goes over my bordersat the edge of the screen!!!


sPaCe :D
 
Last edited by a moderator:
Yeah, it's a palette problem, once you load the first FPG(the intro fpg) Fenix sets that fpg's palette and uses that for the game. If you have another fpg with a different palette it will be displayed with the wrong palette(the only way to display all 8 bit graphics correctly is to have them all use the same palette, so Fenix assumes the palettes are the same in any extra fpg's). FPG Edit creates a palette with the colours in your graphics, and therefore to get the best results every palette is different. All in all, only option is to put everything in one fpg before converting so you'll only have one palette generated. :)

Sorry there is no better news! :)

Whoops: just too slow ;)
 
Okay, does the palette change when you unload the first loaded fpg?

I thought of just making one fpg with all different graphics and then converting it to 8bit and simply load / unoad that fpg to use the palette with all colors. Will that work?

If I have to go the Paintshop way, It will be so much work :( I have to edit every single image and fpg...

And the boundaries for your ship should be quite simple, spaceboy, just use something like this in a loop in your ship process:

Code:
   if(x<0)x=0;end;
   if(x>320)x=320;end;
   if(y<0)y=0;end;
   if(y>240)y=240;end;

These are the boundaries for the complete screen, change the values to make them fit to the movement area you want for your ship.
 
Quiest posted on Mar 25 2005 at 03:06 PM said:
Okay, does the palette change when you unload the first loaded fpg?

I thought of just making one fpg with all different graphics and then converting it to  8bit and simply load / unoad that fpg to use the palette with all colors. Will that work?

If I have to go the Paintshop way, It will be so much work :( I have to edit every single image and fpg...

And the boundaries for your ship should be quite simple, spaceboy, just use something like this in a loop in your ship process:

Code:
   if(x<0)x=0;end;
   if(x>320)x=320;end;
   if(y<0)y=0;end;
   if(y>240)y=240;end;

These are the boundaries for the complete screen, change the values to make them fit to the movement area you want for your ship.

wow thank-you ... that is very simple i was looking far too complicated!

its so strange some things i can get my head round easy...

erm the FGP problem...

you have to unload the fpg at the end of the level

do you have Paintshop? If not PM me...

although it would be better to make a universal pallette for the whole level
you could cheat..

if your sprites have a similar pallette to the background then it shouldnt be a problem... all you r sprites will have the same pallette - so open up just one sprite - the one which is likely to have the widest pallette and grab it - then use this on the background so you should have to change a few pallettes..

Metal slug looks so great... you either have way too much spare time - or your a natural :lol: I on the other hand have neither :p

sPaCe :ph34r:
 
Last edited by a moderator:
Quiest posted on Mar 25 2005 at 05:06 PM said:
Okay, does the palette change when you unload the first loaded fpg?

I guess that's the only problem, it doesn't change. I don't really think you'll have to make all those changes.

If I got what you meant right, you have two fpg's with two different palettes.

Have you tried loading the new palette after the second fpg (the in-game one) is loaded? I mean something like this:

Code:
//In 8 bit mode:
load_fpg("intro.fpg");
//...
unload_fpg("intro.fpg");
load_pal("ingame.fpg");
load_fpg("ingame.fpg");
//...
 
Last edited by a moderator:
that would only work if one fpg is used at a time, when you use more0 than one simultaniously merge those before converting to 8 bit.
 
Yeah as Moogle says, I use more fpgs at a time (to keep memory use down), so it wouldn`t work.

But even if I won`t, it wouldn`t work, as I`m already doing this (after the intro, unload it`s fpg, and load the charselection fpg but the palette stays. I tried my idea with the palette fpg, but it didn`t work, but I may just have used the wrong sprites...
 
What do you mean? FPGEdit can make a palette out of an fpg-file, do you mean this?
Didn`t try it, but I have yet to make a fpg out of all sprites I use, and extract the palette out of that.

But will there be a loss of colors, even if I get the perfect palette?
I think so... which makes me sad :(
 
Quiest posted on Mar 26 2005 at 11:59 AM said:
What do you mean? FPGEdit can make a palette out of an fpg-file, do you mean this?
Didn`t try it, but I have yet to make a fpg out of all sprites I use, and extract the palette out of that.

But will there be a loss of colors, even if I get the perfect palette?
I think so... which makes me sad :(
i believe the load_pal(); function creates a pallete suited to the fpg featured in between the brackets..
 
Last edited by a moderator:
load_pal() is used in Fenix to force Fenix to use a specified palette, you can specify an fpg, a map, or even a png(I think) and it will switch to the palette in the given file. Imagine this(same as Segata's example):

Code:
fpg = Load_FPG("number1.fpg");
//Palette is changed to the palette in number1.fpg
unload_fpg(fpg);
//Still using number1.fpg's palette
fpg = Load_FPG("number2.fpg");
//Still using number1.fpg's palette
load_pal("number2.fpg");
//Now using number2.fpg's palette
 
Back
Top