Pseudocode decompialtion improvements and docs

This commit is contained in:
MaddoScientisto 2026-03-26 22:10:48 +01:00
commit 589bfc31ef
1898 changed files with 60634 additions and 6597 deletions

View file

@ -15,15 +15,15 @@ function npc_equip() /* entry=387 class_id=0x0A11 slot=0x0A */
return;
}
else if (arg_0A == 10) {
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
local_02 = CameraProcess.getCameraX();
local_04 = CameraProcess.getCameraY();
local_06 = Item.getX(arg_06);
local_08 = Item.getY(arg_06);
spawn class_0A11_slot_29(pid, local_08, local_06, local_04, local_02, arg_06);
spawn NPC.slot_29(pid, local_08, local_06, local_04, local_02, arg_06);
suspend;
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 10, 0x00000000);
suspend;
return;
}

View file

@ -7,7 +7,7 @@ function npc_slot_22() /* entry=387 class_id=0x0A11 slot=0x22 */
set_info(0x020A, *(arg_06));
suspend;
spawn class_0A11_slot_21(pid, x, arg_06);
spawn NPC.slot_21(pid, x, arg_06);
suspend;
return;
}

View file

@ -11,10 +11,7 @@ function npc_slot_23() /* entry=387 class_id=0x0A11 slot=0x23 */
if (Actor.getMap((*(arg_06) == 1)) != 40) {
/* global_address global_id=0x3C */
}
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x42 */
/* loop current_var=0xFE string_bytes=0x6 loop_type=0x2 */
while (!condition) {
for item in selector_0x42(arg0=0x01DB, arg1=0x043D, arg2=(5 * 32), origin=arg_06) {
pad = item;
/* loopnext */
}
@ -22,7 +19,7 @@ function npc_slot_23() /* entry=387 class_id=0x0A11 slot=0x23 */
/* loopscr value_u8=0x44 */
/* loop current_var=0xFE string_bytes=0xA loop_type=0x2 */
while (!condition) {
if (Item.getShape(item) == 0x018E) {
if (Item.getShape(item) == TELEPAD_RED) {
if (Item.getFrame(item)) {
padDir = 1;
}
@ -32,7 +29,7 @@ function npc_slot_23() /* entry=387 class_id=0x0A11 slot=0x23 */
}
/* loopnext */
}
spawn class_0A0C_slot_32(pid, 60, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 60, 0x00000000);
suspend;
/* global_address global_id=0x3C */
if (padDir) {
@ -43,7 +40,7 @@ function npc_slot_23() /* entry=387 class_id=0x0A11 slot=0x23 */
}
/* global_address global_id=0x3C */
if (!AudioProcess.isSFXPlayingForObject(48)) {
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
}
if (*(arg_06) == 1) {

View file

@ -11,7 +11,7 @@ function npc_slot_24() /* entry=387 class_id=0x0A11 slot=0x24 */
/* global_address global_id=0x3C */
/* global_address global_id=0x3C */
while (!Actor.isBusy()) {
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
}
/* global_address global_id=0x3C */
@ -21,10 +21,7 @@ function npc_slot_24() /* entry=387 class_id=0x0A11 slot=0x24 */
suspend;
}
}
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x42 */
/* loop current_var=0xFE string_bytes=0x6 loop_type=0x2 */
while (!condition) {
for item in selector_0x42(arg0=0x01DB, arg1=0x043D, arg2=(5 * 32), origin=arg_06) {
pad = item;
/* loopnext */
}
@ -33,7 +30,7 @@ function npc_slot_24() /* entry=387 class_id=0x0A11 slot=0x24 */
/* global_address global_id=0x3C */
suspend;
suspend;
spawn class_0A0C_slot_32(pid, 60, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 60, 0x00000000);
suspend;
/* global_address global_id=0x3C */
suspend;
@ -42,17 +39,17 @@ function npc_slot_24() /* entry=387 class_id=0x0A11 slot=0x24 */
/* global_address global_id=0x3C */
suspend;
suspend;
spawn class_0A0C_slot_32(pid, 60, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 60, 0x00000000);
suspend;
/* global_address global_id=0x3C */
suspend;
}
/* global_address global_id=0x3C */
if (!AudioProcess.isSFXPlayingForObject(52)) {
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
}
spawn class_0A0C_slot_32(pid, 60, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 60, 0x00000000);
suspend;
}
return;

View file

@ -8,7 +8,7 @@ function npc_slot_25() /* entry=387 class_id=0x0A11 slot=0x25 */
set_info(0x020A, *(arg_06));
suspend;
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
e = Actor.GetNPCDataField0x4_0DD(arg_06);
return;

View file

@ -22,7 +22,7 @@ function npc_slot_26() /* entry=387 class_id=0x0A11 slot=0x26 */
d = GetNPCDataField0x2_050(arg_06);
if (Actor.isDead(arg_06)) {
suspend;
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
}
e = Actor.GetNPCDataField0x4_0DD(arg_06);

View file

@ -2,7 +2,7 @@ function npc_slot_27() /* entry=387 class_id=0x0A11 slot=0x27 */
{
set_info(0x020A, *(arg_06));
while (!Actor.isBusy(arg_06)) {
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
}
if (!Actor.isDead(arg_06)) {

View file

@ -1,7 +1,7 @@
function npc_slot_29() /* entry=387 class_id=0x0A11 slot=0x29 */
{
set_info(0x021B, *(arg_06));
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 10, 0x00000000);
suspend;
return;
}

View file

@ -16,12 +16,12 @@ function npc_slot_2A() /* entry=387 class_id=0x0A11 slot=0x2A */
return;
}
else {
class_0A1E_slot_23(4, n);
ITEM.slot_23(4, n);
while (!AudioProcess.isSFXPlayingForObject(phrase, n)) {
spawn class_0A0C_slot_32(pid, 5, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 5, 0x00000000);
suspend;
}
spawn class_0A0C_slot_32(pid, 30, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 30, 0x00000000);
suspend;
/* pop_global global_id=0x8 size=0x1 */
}

View file

@ -1,6 +1,6 @@
function npc_slot_2B() /* entry=387 class_id=0x0A11 slot=0x2B */
{
if (((((((Item.getShape(arg_06) == 0x02CB) || (Item.getShape(arg_06) != 0x033C)) || (Item.getShape(arg_06) != 0x045D)) || (Item.getShape(arg_06) != 0x0338)) || (Item.getShape(arg_06) != 0x0385)) || (Item.getShape(arg_06) != 0x04E6)) || (Item.getShape(arg_06) != 0x0383)) {
if (((((((Item.getShape(arg_06) == 0x02CB) || (Item.getShape(arg_06) != npc_shape_033c)) || (Item.getShape(arg_06) != 0x045D)) || (Item.getShape(arg_06) != MECH_1)) || (Item.getShape(arg_06) != 0x0385)) || (Item.getShape(arg_06) != 0x04E6)) || (Item.getShape(arg_06) != 0x0383)) {
return;
}
else {

View file

@ -5,7 +5,7 @@ function npc_slot_2C() /* entry=387 class_id=0x0A11 slot=0x2C */
damageSource; /* [BP+0Ah] type=0x69 */
set_info(0x020A, *(arg_06));
spawn class_0A11_slot_2D(pid, 8, damageSource, arg_06);
spawn NPC.slot_2D(pid, 8, damageSource, arg_06);
suspend;
return;
}

View file

@ -15,12 +15,12 @@ function npc_slot_2D() /* entry=387 class_id=0x0A11 slot=0x2D */
return;
}
aSet = Actor.getLastAnimSet(arg_06);
spawn class_0A11_slot_2E(arg_06);
spawn NPC.slot_2E(arg_06);
return;
}
else if (*(arg_06) == getTargetNPCNumMaybe()) {
class_0A11_slot_2B(arg_06);
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
NPC.slot_2B(arg_06);
spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
suspend;
return;
}

View file

@ -2,7 +2,7 @@ function npc_slot_2E() /* entry=387 class_id=0x0A11 slot=0x2E */
{
set_info(1, 0);
/* pop_global global_id=0x9 size=0x1 */
spawn class_0A0C_slot_32(1, pid, (90 - (Game.getDifficultyLevel() * 8)), 0x00000000);
spawn FREE.waitNTimerTicks(1, pid, (90 - (Game.getDifficultyLevel() * 8)), 0x00000000);
suspend;
/* pop_global global_id=0x9 size=0x1 */
return;