Palette swapping, 128X128 shapes.

NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Forum rules
NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Locked
Kennedy

Palette swapping, 128X128 shapes.

Post by Kennedy »

Here is an idea for Exult Studio that would be neat. The ability to swap certain colors for others. For example you could swap the color blue and replace it with red, green, yellow, or whatever. This was done in the Duke Nukem and Shadow Warrior games as well as Daggerfall. This would allow more variety to play. Also is it possible to make shapes that are 128 by 128 in size with Exult Studio? This would be nice because then you wouldn't need fole shapes for each of the Guardian's generators in BG and the turtle in SI.
SB-X
Posts: 980
Joined: Thu May 14, 2020 1:34 pm

Re: Palette swapping, 128X128 shapes.

Post by SB-X »

I don't understand the reason to change colors. You mean swap colors on individual shapes in the studio? You can use an art program on them.
drcode
Site Admin
Posts: 2267
Joined: Thu May 14, 2020 1:34 pm

Re: Palette swapping, 128X128 shapes.

Post by drcode »

You can already modify the palette colors in ExultStudio. Click on 'palettes.flx' and modify some of the colors.
Kennedy

Re: Palette swapping, explained

Post by Kennedy »

What I mean was you would make a blue shirt, then there would be an option as to which palette the shirt would use. Palette 0 which would be the default would leave the shirt blue, but lets say you use a diferent palette the shirt could be made green, yellow, red, or various other colors. This way you would only need one graphic for the shirt, but by assigning a diferent palette number you could have several colors of shirts. So each object in the world would then have a palette number.

Not sure if I'm explaining this right.
Telemachos

Re: Palette swapping, explained

Post by Telemachos »

Problem is that 256 color graphics modes can only have one active palette at a time so what you're suggesting is only possible in 16 or 24bit graphics modes..

- Telemachos
wjp
Site Admin
Posts: 1708
Joined: Thu May 14, 2020 1:34 pm

Re: Palette swapping, explained

Post by wjp »

We have talked about entirely switching to 16/24 bit graphics at one point. This would allow us to, for example, use the proper daytime palette for gumps even when it's night, so that text in them is actually readable. Something for version 2.0, maybe :-)
SB-X
Posts: 980
Joined: Thu May 14, 2020 1:34 pm

Re: Palette swapping, explained

Post by SB-X »

It is a "good" side effect though that at night-time you can't see the contents of your backpack. You wouldn't be able to see in it in real life either. Before you switch to high color, maybe you can just switch the palette temporarily whenever someone looks at a sign.
Kuroshi
Posts: 67
Joined: Thu May 14, 2020 1:34 pm

Re: Palette swapping, explained

Post by Kuroshi »

At night in real life you might have trouble seeing the contents of your backpack without light, but if you were in a videogame you probably wouldn't have a hard time saving. =)
drcode
Site Admin
Posts: 2267
Joined: Thu May 14, 2020 1:34 pm

Re: Palette swapping, explained

Post by drcode »

Note that Exult gives you a lighter palette (dusk/dawn) when you're looking at inventory, even if you're standing in the dark.
Kennedy

Re: Palette swapping, explained

Post by Kennedy »

Duke Nukem, Shadow Warrior, and Daggerfall all had 256 colors. The way I think they did "palette swapping" was to assign certain colors to certain slots, like blues had slots 16 to 31, then the game checked to see which "palette" the object was set to, if the number was different it would use colors from other slots like 48 to 63 to replace those for that particular object. I hope this helps.

Also are 128X128 size shapes possible with Exult Studio, or is that to large for it to handle?
drcode
Site Admin
Posts: 2267
Joined: Thu May 14, 2020 1:34 pm

Re: Palette swapping, explained

Post by drcode »

128x128: I think ExultStudio can handle it, but I'm not sure if Exult's renderer will deal with it correctly.
Locked