VOGONS


First post, by augnober

User metadata
Rank Member
Rank
Member

When running Star Control 2, DOSBox shares a palette problem with many newer graphics cards (the problems started appearing on some graphics cards at least as long ago as the Pentium133 era). This is something I've looked into before, and have patched (hacked starcon2.exe) to correct on offending systems. The quickest way to reliably encounter this problem is to start the game and fly your ship towards Earth. You'll be intercepted by an alien ship and you'll see that the colours are completely screwed up.

This seems to be an issue where older VGA cards shared some undocumented functionality which stopped being found in later cards. If you're interested in implementing the behaviour seen on the older graphics cards (which will fix Star Control 2 in DOSBox), here's what I found:
Normally, to set the palette on standard VGA, you:
1. To port 0x3c8, output the first colour to change
2. Output rgb values to 0x3c9 for each colour in sequence

Star Control 2 however outputs to port 0x3c7 instead (0x3c7 is normally the port that you output to to indicate that you're about to READ palette information.. not set). The difference is almost that simple. However, inexplicably, rather than outputting the first colour to change to 0x3c7, it outputs this value minus one. Amazingly, this code set the palette correctly on videocards of the time... but unfortunately, doesn't work in DOSBox or most current videocards.

Perhaps there are other games that exhibit this behaviour... Probably not. Star Control 2 often makes "Best PC Games Ever" lists though, so it may be worthy of a fix 😀

Reply 1 of 10, by augnober

User metadata
Rank Member
Rank
Member

Just a bit of extra information..
I'm seeing the palette problem on DOSBox 0.62 (win32). I don't think my other specs, etc. are relevant for this. I just went in and ran the game without doing any funny stuff.

Reply 2 of 10, by priestlyboy

User metadata
Rank Oldbie
Rank
Oldbie

Palette problem is with the game. If I remember correctly you have to boot the game with the switch "/g:bios" I think.

It's a known problem and isn't because of DOSBox. (I have a full version that I got on a demo CD.)

Last edited by priestlyboy on 2004-10-03, 03:38. Edited 1 time in total.

Ieremiou
----------
Helping Debug DOSBox.

Reply 3 of 10, by augnober

User metadata
Rank Member
Rank
Member

I remember reading that on a message board after I got my Pentium133 with Matrox Millenium 2 (10 years ago now, I guess). I'm pretty sure it was working fine with no flags before I upgraded, so there may still be the option of emulating those older cards so that the flag's not needed. I suppose it's not as necessary though so long as it works properly in DOSBox with the flag.

Reply 4 of 10, by priestlyboy

User metadata
Rank Oldbie
Rank
Oldbie

It does I just tested it 😉

From the manual (which was sooo nicely provided by the Demo Guys)

Garbled Graphics or Blank Screen
Star Control II supports VGA or MCGA graphics only. If your computer
does not have these graphic cards and a color monitor, this game will
not work on your system. If you do have these and still experience a
blank screen or garbled graphics, see the Booting Clean section below.
Graphic Adapter Fix Certain computers, (i.e. Tandy 4850 EP) have
unusual video hardware. Therefore, colors in the game might not look
quite right. If you experience this problem, try running the game as
STARCON2 /g:BIOS. This will force the program to update the color
palette using the BIOS functions. Since most BIOS calls are far slower
than custom routines, a minor performance penalty may be noticed when
using this option.

Note: Any command line additions can only be made if you are launching
the game without using the front-end menu.

Last edited by priestlyboy on 2004-10-03, 03:42. Edited 1 time in total.

Ieremiou
----------
Helping Debug DOSBox.

Reply 7 of 10, by priestlyboy

User metadata
Rank Oldbie
Rank
Oldbie

I do agree it would be nice. But they may or may not do it since it's not urgent and the fact that the game is setup to alleviate these kinds of problems. On a sidenote just incase anybody wanted to know how to force StarCon2 to pick their favorite Soundcard here are the Commandline codes.

Specifying Sound Card on the Command Line
Star Control II automatically detects supported sound cards
(inside your computer) when you load the program. However, there
are some peripheral sound devices which are not detected. For
these devices, you willhave to add a code to the command line:
STARCON2 /s:DEVICENAME where DEVICENAME is one of the following:

Code Sound Device
DISNEY1 Disney Sound Source on parallel port #1.
DISNEY2 Disney Sound Source on parallel port #2.
LPT1 Covox Speech Thing or other sound peripheral on
parallel port #1.
LPT2 Covox Speech Thing or other sound peripheral on
parallel port #2.

If you want to specify explicitly your sound board, follow the above
convention with one of the following codes:

Code Sound Device
INTERNAL Internal speaker
ADLIB An Adlib sound board
SBLASTER A Soundblaster
PAS A Pro Audio Spectrum
SM2 A Sound Master II
ASC An ASC Media Master
MICRO Microsoft Windows
GRAVIS Gravis Ultrasound

If you want NO sound, use the code SILENT.

Ieremiou
----------
Helping Debug DOSBox.

Reply 8 of 10, by red_avatar

User metadata
Rank Oldbie
Rank
Oldbie

One note: the /g:BIOS tag doesn't work with the popular abandonware version on the net - it has a starcon2.com crack that will run the game without the need for the starmap. Luckily, I bought the original Starcon 2 in mint condition (still in plastic wrap) on ebay for a dollar or two 😁 and it works fine using the starmap.

Reply 9 of 10, by augnober

User metadata
Rank Member
Rank
Member

In that case, I guess there is some use in the hack I did. For the benefit of people at home, here's what I did (try it - It's fun for the whole family!):

in starcon2.exe,
find "mov dx, 03c7"... replace it with "mov dx, 03c8"
a couple lines down, change one of the "inc dx" instructions to "nop"
look up roughly 10 to 20 lines. change the "dec bx" to "nop"

That's all. That's from my memory, so it's not very specific.. but I'm certain I didn't forget any steps. It's a fairly easy hack which can be done using "Hacker's View" (aka HIEW) or whatever.

Reply 10 of 10, by priestlyboy

User metadata
Rank Oldbie
Rank
Oldbie

My version is cracked as well. I don't need a star map either. Runs perfectly with the /g:bios switch. 😜
It was cracked by the developers as far as I can tell.

Ieremiou
----------
Helping Debug DOSBox.