Technical questions

Discuss Chaos Strikes Back, the "expansion pack" for Dungeon Master.
This forum may contain spoilers.
Forum rules
Please read the Forum rules and policies before posting.
Post Reply
Flora

Technical questions

Post by Flora »

ok so paul if I understand it well you did have the 680x0 assembler and convert it to x86 assembler or was it at a higher level?

On the other hand how did you manage the sound?
Flora

Re: Technical questions

Post by Flora »

I am asking that for my personal culture as well as to understand exactly how you managed this tour de force
User avatar
Paul Stevens
CSBwin Guru
Posts: 4318
Joined: Sun Apr 08, 2001 6:00 pm
Location: Madison, Wisconsin, USA

Re: Technical questions

Post by Paul Stevens »

I started with the Winston file A_192.ST It
looked like this: A couple hundred thousand numbers.

48e7
0088
287a
ffda
307c
fa00
4a6c
d12c
6628
4228
001b
117c
008b
0021
117c
0008

I wrote a 68000 disassembler and found the code
and data segements more-or-less by trial and error
(no mean feat in itself) and produced:

000b4c 48e7 0088 MOVEM.L A04,-(A7)
000b50 287a ffda MOVE.L $-36 (=0x000b2c),A4
000b54 307c fa00 MOVE.W #64000,A0
000b58 4a6c d12c TST.W -11988(A4)

Then I looked at each instruction, figured out what it
did and wrote the following by hand

void TAG000b4c(UI16 P1)
{
unsigned int A0;
A0 = 0xfffffa00;
if (d.Word11988 == 0)
etc.

Then I compiled and ran it.
Flora

Re: Technical questions

Post by Flora »

so it is:
680x0 machine code -> 680x0 assembler -> C/C++
is that correct?
User avatar
Paul Stevens
CSBwin Guru
Posts: 4318
Joined: Sun Apr 08, 2001 6:00 pm
Location: Madison, Wisconsin, USA

Re: Technical questions

Post by Paul Stevens »

That is correct.
Flora

Re: Technical questions

Post by Flora »

Man it must have been a nightmare.
that is a great job anyway.

For the sounds the backengeenering worked as well or do you have to include some tricks?
User avatar
Paul Stevens
CSBwin Guru
Posts: 4318
Joined: Sun Apr 08, 2001 6:00 pm
Location: Madison, Wisconsin, USA

Re: Technical questions

Post by Paul Stevens »

The sounds were relatively straight-forward. I will tell
you what I think I remember. Some details may be
wrong.

The Atari had some sort of log-scale digital-to-analog
converter for the sounds. CSB had 4-bit samples which
were fed to the D-to-A converter. About all I had to do
was build a lookup table to convert the samples on the
same log scale to 8-bit samples. Then I build a wavefile
header to put on front of the samples and sent it off
to Windows, telling Windows that it was an in-memory
copy of a .WAV file.
Flora

Re: Technical questions

Post by Flora »

yeah that was smart and nice.

Did you get any money for that? :)
Post Reply