Page 1 of 1

Reverse engineering in OLoco & ORCT2

Posted: 18 Feb 2023 09:22
by luk3Z
For those who may wonder how it was made (for educational purposes only):

https://www.youtube.com/user/duncanspumpkin/videos
https://www.youtube.com/@duncanfrot4318/videos
https://www.youtube.com/watch?v=cwBoUuy4nGc
I've begun disassembling Loco.exe. It's a tough one to figure out because Atari used all kinds of bit transfers (32 bit to 64 bit and back again) for all kinds of things. Mainly time critical things like dates, speeds, etc. This seems like poor programming, giving higher cpu driven function more things to process thus slowing down the whole game.

I've tried pretty hard to figure out how the game calculates the year and I haven't figured it out yet. I also learned something interesting on that topic. The game actually keeps track of leap years! No idea why, but it does. Though they made a mistake and didn't include the year 2000 into the leap year calculations, but who's criticizing, right?

I've broken down the exe into the main parts (file I/O, time, speeds, and monetary things) and now I'm in the process of figuring out exactly how each one works. I'm hoping to find enough information to begin large scale modifications (mainly real-time changes) so I can begin doing things like TTD Patch does with TTD. It is proving very difficult due to 2 things. One, my lack of ASM understanding and two, my lack of time to do such things.

For those intrested, the game has both static and dynamic memory allocations on a large scale (which is odd). For example, some of the static memory addresses include player data (money, loan, delivered cargo, etc). Some of the dynamic addresses include Years, vehicle speeds, and vehicle reliability.
by Rapture ยป 12 Sep 2005, o 03:08
viewtopic.php?t=20749

C++ tools to make life easier:
https://en.wikipedia.org/wiki/Sourcetrail
https://en.wikipedia.org/wiki/Cppcheck

Wiki:
https://github.com/OpenLoco/OpenLoco/wiki
https://www.tt-wiki.net/wiki/Category:L ... evelopment

Re: Reverse engineering in OLoco & ORCT2

Posted: 23 Feb 2024 17:10
by luk3Z
And now for something completely different - RE in RCT (knowledge partly apply to Loco):

Modding RollerCoaster Tycoon into a Peele Horror Film (Game Modding/Reverse Engineering Tutorial):
https://www.youtube.com/watch?v=1MOrjGZ4hbo

[Game Mod Code Deep Dive] Modding RollerCoaster Tycoon into a Peele Horror Film:
https://www.youtube.com/watch?v=PYOUgevLRfc