Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

NeptuneKul

RTS character color questions...

This topic is 5992 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I know it''s through palette to change the colors of different players. Let''s say the game is going to run under 16 or 24 bit mode, the bitmaps are 256 color with 8 bit palette table, one object with one bitmap and with the standard palette table, all the other 7 colors of the same object need to change the palette dynamically. All my offscreen surfaces should also be 16 or 24 bits right? How to blit those offscreen surfaces to the primary surface with different colors? Must I store all the 8 colors of the same object to 8 different offscreen surfaces? If I made any wrong assumption, just point me out.. Thank you!

Share this post


Link to post
Share on other sites
Advertisement
For directdraw your best bet would be to use 8 bit surfaces and write a custom blit routine that replaces the color you use for these pixels with the player color (best written in asm).

If you were willing to use dx 8 then you could load 8 bit textures and modify the texture palette to get the appropiate effect (D3DDevice::SetTexturePalette or something like that). Change the entry you use to the appropiate player color for each blit maybe sort them by player.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!