'Shades of Magenta' Enable WC1's Dynamic Cockpits
UnnamedCharacter has discovered another nifty developer trick in the code of Wing Commander. By observing what gets loaded into active memory while playing the game, he noticed how certain palette colors become blanked out and then revert back to magenta/red as the ship takes damage. This is how parts of the cockpit flicker when taking damage! Here he is to walked through the details:Shades of MagentaThe following images are two different representation of the game palette. The first image represents the colors as extracted from the GAME.PAL file and the second represents the colors as extracted from game memory. Notice how several of the magenta colors have been blacked out when loaded into memory.
At first I found that curious: Does the game not use those colors? Often time magenta is used to indicate a transparent color, but several of them? Then I remembered what seemed like an oddity of the radar screens in the cockpit image of each ship.
When all put together and observing the behaviour of the game it becomes clear. When taking a hit on your ship, the space background turns to red and so does the radar area representing the location hit. Instead of redrawing the individual sections of the radar screen, the specific color position in the palette is change and every time the screen is redrawn, the appropriate color is shown.
What a clever way to provide a wonderful bit of feedback to help a pilot know where enemy fire is coming from.
Follow or Contact Us