English Amiga Board

English Amiga Board (http://eab.abime.net/index.php)
-   Coders. Tutorials (http://eab.abime.net/forumdisplay.php?f=73)
-   -   Rewriting m68k code (http://eab.abime.net/showthread.php?t=67556)

RobSis 26 January 2013 15:06

Rewriting m68k code
 
Hello,

I'm trying to understand and rewrite piece of m68k assembler, disassembled from one old Atari ST game.

Could you try to help me? I'm more of a beginner, considering the assembler.

Here's the asm code http://pastebin.com/KJCnUbqK and here's what I rewritten so far to C language: http://pastebin.com/fAJ2F6aC

So far, I got the the MOVEA instruction and got lost...

Leffmann 26 January 2013 16:15

It simply generates a random name from three of the smaller words.

Specifically, A0 is a pointer to where it wants the name stored and D3 and D4 are states for its pseudo random number generator. It picks one word, stores at A0, capitalizes the first letter, then picks two more and append these to the end along with a null-byte.


All times are GMT +2. The time now is 03:33.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, vBulletin Solutions Inc.

Page generated in 0.04011 seconds with 11 queries