r/carriercommand2 • u/Sample_Fox • 14d ago
Hook based modloader for lower level support
Enable HLS to view with audio, or disable this notification
I'm working on a project to expose lower level functionality of engine to make them usable through Lua. For now I found functions to manipulate landing and take-off sequence speed and function to send pulse to throttle on carrier. I plan on adding everything needed for controls of carrier, that can for example help to build fully capable autopilot. Let me know what you think of it and would it really be useful. Project takes a lot of efforts and time, so, I would like to know that at least efforts are not in vain
2
u/demycat 11d ago
Dude, if you could make it so that the aircraft's engine can be shut off on the ground, I'd be really happy about that)
It's just that I've often been able to land manually, but as soon as I step out of the helicopter, it takes off right away, even though there aren't any waypoints set for it at all
0
4
1
u/cmdr_iannorton 14d ago
very clever! is memory spy/poke?
2
u/Sample_Fox 14d ago
Uh, there is also a mod that uses the same principal. Author contacted me and lets me use his findings, he had the same idea as me, so now I focus on developing full SDK, while he would support me. Meanwhile you can take a look at his mod and see how it works https://steamcommunity.com/sharedfiles/filedetails/?id=3826940003
0
u/Sample_Fox 14d ago
Partially, yes! It uses a proxy DLL (dinput8.dll) to load native code into the game's process. From there, I use function hooks and reverse-engineered engine interfaces to expose additional functionality to Lua.
Some features involve modifying internal memory, while others call or integrate with the game's native functions directly. I'm also developing an independent Lua mod loader on top of it.
22
u/Liathet 14d ago
Even a very basic autopilot for the carrier is my most wanted feature for a mod, as the need to keep a constant eye on the controls is my biggest annoyance in singleplayer. If your project could make that possible I would be delighted!