mirror of
https://github.com/open-goal/jak-project
synced 2026-09-07 03:30:01 -04:00
[decomp] add mips2c converter (#842)
* mips 2 c basic version, not yet tested * calling works without crashing, but the function doesn't * it works * add test * cleanup and actually add the test * dont use mips2c by default for font * clean up formatting
This commit is contained in:
@@ -17,6 +17,7 @@
|
||||
#include "kprint.h"
|
||||
#include "common/symbols.h"
|
||||
#include "common/goal_constants.h"
|
||||
#include "game/mips2c/mips2c_table.h"
|
||||
|
||||
namespace {
|
||||
// turn on printf's for debugging linking issues.
|
||||
@@ -785,6 +786,11 @@ void link_control::finish() {
|
||||
if (ofh->object_file_version == 3) {
|
||||
// todo check function type of entry
|
||||
|
||||
// setup mips2c functions
|
||||
for (auto& x : Mips2C::gMips2CLinkCallbacks[m_object_name]) {
|
||||
x();
|
||||
}
|
||||
|
||||
// execute top level!
|
||||
if (m_entry.offset && (m_flags & LINK_FLAG_EXECUTE)) {
|
||||
call_goal(m_entry.cast<Function>(), 0, 0, 0, s7.offset, g_ee_main_mem);
|
||||
|
||||
Reference in New Issue
Block a user