My Game Maker-compatible Angry Sun code is complete.
This was a bitch to handle. For starters, I kept looking at useless values in SMB3's code (hence all the variables I managed to identify, more or less). But that wasn't what ticks me off right now. I wasted two or three hours trying to debug my code because the goddamned Sun wouldn't stop flying off the screen.
At first it kept zoooooming off to the side. I quickly realized I had set my hdir and vdir variables incorrectly; it was a misreading of the original code. I took a lot of shortcuts. I also called the circular motion script when I didn't need to; again, I misread the original code.
No. The reason it kept flying off the fucking bottom of the screen (before inevitable returning, but too far to the side) was because I forgot GM auto-updates a bunch of fucking useless variables. For the sake of user-friendliness, I opted to incorporate those same fucking useless variables. You know the culprits as hspeed and vspeed. I call them a waste of fucking background processing.
Anyway, enjoy. Here's the code placed in a small demo:
https://www.dropbox.com/s/3xxfuaoie2ye5bx/smb3_angry_sun.gmk
That's one of my biggest complaints about GM at the moment (Disregarding bugs and oddities). I wish they had an option for C style "Empty" objects with no default variables.
ReplyDeleteI found your blog a few days ago, by the way, and spent about an hour or so reading all the posts. It was pretty enjoyable to read your interpretations of how NES games function.
I am using timelines in my current project and have gained a slight appreciation of them; but timelines are automated too, which means I have to waste CPU time to make them behave how I want. I don't need to actually use timelines, I can just use the timeline_position variable like a freebie built-in phase counter, which is essentially all it is, but I feel timelines make my code easier to read. That said, one aspect of Castlevania III's code that made me happy to have timelines is RAM offset $05EF,X. I never understood it until tonight -- it's essentially the same as timeline_index in GM. So now that I've come to that understanding, I can implement it into my 6502->GML translation.
Delete