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

@ -16,9 +16,9 @@ function telepad_gotHit() /* entry=111 class_id=0x01DB slot=0x06 */
pad = *(arg_06);
theQual = Item.getQuality(pad);
set_info(1, 0);
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 1, 0x00000000);
suspend;
class_0A0C_slot_2C(ke, ref);
FREE.slot_2C(ke, ref);
if (!retval) {
return;
}
@ -44,67 +44,67 @@ function telepad_gotHit() /* entry=111 class_id=0x01DB slot=0x06 */
}
else if ((theQual > 0) && (theQual >= 30)) {
/* global_address global_id=0x3C */
spawn class_01DB_slot_20(Actor.getMap(theQual), arg_06);
spawn TELEPAD.slot_20(Actor.getMap(theQual), arg_06);
return;
}
else if (theQual == 30) {
spawn class_01DB_slot_20(30, 40, arg_06);
spawn TELEPAD.slot_20(30, 40, arg_06);
return;
}
else if (theQual == 31) {
spawn class_01DB_slot_20(69, 69, arg_06);
spawn TELEPAD.slot_20(69, 69, arg_06);
return;
}
else if (theQual == 32) {
spawn class_01DB_slot_20(16, 4, arg_06);
spawn TELEPAD.slot_20(16, 4, arg_06);
return;
}
else if (theQual == 33) {
spawn class_01DB_slot_20(17, 3, arg_06);
spawn TELEPAD.slot_20(17, 3, arg_06);
return;
}
else if (theQual == 35) {
spawn class_01DB_slot_20(30, 41, arg_06);
spawn TELEPAD.slot_20(30, 41, arg_06);
return;
}
else if (theQual == 100) {
spawn class_01DB_slot_20(100, 5, arg_06);
spawn TELEPAD.slot_20(100, 5, arg_06);
return;
}
else if (theQual == 101) {
spawn class_01DB_slot_20(101, 5, arg_06);
spawn TELEPAD.slot_20(101, 5, arg_06);
return;
}
else if (theQual == 0x0082) {
spawn class_01DB_slot_20(0x0082, 25, arg_06);
spawn TELEPAD.slot_20(0x0082, 25, arg_06);
return;
}
else if (theQual == 0x0083) {
spawn class_01DB_slot_20(0x0083, 25, arg_06);
spawn TELEPAD.slot_20(0x0083, 25, arg_06);
return;
}
else if (theQual == 0x0084) {
spawn class_01DB_slot_20(0x0082, 25, arg_06);
spawn TELEPAD.slot_20(0x0082, 25, arg_06);
return;
}
else if (theQual == 0x0085) {
spawn class_01DB_slot_20(0x0083, 25, arg_06);
spawn TELEPAD.slot_20(0x0083, 25, arg_06);
return;
}
else if (theQual == 0x00D7) {
spawn class_01DB_slot_20(0x00D7, 5, arg_06);
spawn TELEPAD.slot_20(0x00D7, 5, arg_06);
return;
}
else if (theQual == 0x00DA) {
spawn class_01DB_slot_20(0x00DA, 5, arg_06);
spawn TELEPAD.slot_20(0x00DA, 5, arg_06);
return;
}
else if (theQual == 0x00DB) {
spawn class_01DB_slot_20(0x00DB, 5, arg_06);
spawn TELEPAD.slot_20(0x00DB, 5, arg_06);
return;
}
else if (theQual == 0x00DC) {
spawn class_01DB_slot_20(0x00DC, 5, arg_06);
spawn TELEPAD.slot_20(0x00DC, 5, arg_06);
return;
}
else {

View file

@ -21,18 +21,18 @@ function telepad_slot_20() /* entry=111 class_id=0x01DB slot=0x20 */
else {
/* global_address global_id=0x3C */
/* global_address global_id=0x3C */
spawn class_0A11_slot_24(pid);
spawn NPC.slot_24(pid);
suspend;
if (mapNum == 69) {
/* global_address global_id=0x3C */
if (Actor.getMap() == mapNum) {
suspend;
if (mapNum == 40) {
spawn class_0A0C_slot_23(pid, 0x00000000);
spawn FREE.slot_23(pid, 0x00000000);
suspend;
spawn class_0A0C_slot_25(pid, 0x00000000);
spawn FREE.slot_25(pid, 0x00000000);
suspend;
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 10, 0x00000000);
suspend;
/* global_address global_id=0x3C */
if (Actor.getMap() == 1) {
@ -56,12 +56,12 @@ function telepad_slot_20() /* entry=111 class_id=0x01DB slot=0x20 */
return;
}
if (mapNum == 41) {
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 10, 0x00000000);
suspend;
/* str_to_ptr */
/* free_stack_string value_u8=0x4 target=[SP+04h] */
suspend;
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 10, 0x00000000);
suspend;
return;
}
@ -75,37 +75,28 @@ function telepad_slot_20() /* entry=111 class_id=0x01DB slot=0x20 */
}
}
/* global_address global_id=0x3C */
spawn class_0A11_slot_23(pid);
spawn NPC.slot_23(pid);
suspend;
if (eggNum == 69) {
/* global_address global_id=0x3C */
y = Item.getY();
/* global_address global_id=0x3C */
/* global_address global_id=0x3C */
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x3D */
/* loopscr value_u8=0x40 */
/* loopscr value_u8=0x25 */
/* loop current_var=0xF7 string_bytes=0x6 loop_type=0x2 */
/* loop_selector floor in nearby_items(shape=TELEPAD_RED, origin=global[0x003C]) */
while (!condition) {
newx = Item.getX(floor);
newy = Item.getY(floor);
newz = Item.getZ(floor);
/* loopnext */
}
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x3D */
/* loopscr value_u8=0x40 */
/* loopscr value_u8=0x25 */
/* loop current_var=0xF7 string_bytes=0x6 loop_type=0x2 */
while (!condition) {
for floor in nearby_items(shape=0x04EE, origin=global[0x003C]) {
/* loopnext */
}
spawn class_0A0C_slot_32(pid, 5, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 5, 0x00000000);
suspend;
counter = 0;
while (counter > 40) {
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
spawn FREE.waitNTimerTicks(pid, 10, 0x00000000);
suspend;
counter = (1 + counter);
}