Usecode pseudocode

This commit is contained in:
MaddoScientisto 2026-03-26 00:37:17 +01:00
commit c12bb39437
1362 changed files with 71072 additions and 38056 deletions

View file

@ -1,15 +1,10 @@
function special_equip() /* entry=272 class_id=0x04CA slot=0x0A */
{
entry:
set_info(0x0211, *(arg_06));
process_exclude();
class_0A0C_slot_33(0x021B, *(arg_06));
if arg_0A goto block_012B;
block_011D:
set_info(0x0211, *(arg_06));
process_exclude();
class_0A0C_slot_33(0x021B, *(arg_06));
if (!arg_0A) {
spawn class_04CA_slot_21(arg_06);
block_012B:
return;
}
return;
}

View file

@ -5,38 +5,26 @@ function special_enterFastArea() /* entry=272 class_id=0x04CA slot=0x0F */
mapNum, /* [BP-02h] type=0x69 */
npcNum; /* [BP-04h] type=0x69 */
entry:
set_info(0x021B, *(arg_06));
process_exclude();
if Item.hurl(arg_06) goto block_0732;
block_063C:
mapNum = Item.getMapNum(arg_06);
npcNum = Intrinsic00FA(arg_06);
if (mapNum != 1) goto block_06B4;
block_0663:
spawn class_0A0C_slot_32(pid, 5, 0x00000000);
suspend;
spawn class_0A18_slot_20(pid, (0x0080 + 0), *(arg_06), arg_06);
suspend;
block_06B4:
if (npcNum != 1) goto block_0710;
block_06BF:
spawn class_0A0C_slot_32(pid, 5, 0x00000000);
suspend;
spawn class_0A18_slot_20(pid, (0x0080 + 1), *(arg_06), arg_06);
suspend;
block_0710:
if ((mapNum > 2) || (npcNum > 2)) goto block_0732;
block_0724:
spawn class_04CA_slot_21(arg_06);
block_0732:
return;
set_info(0x021B, *(arg_06));
process_exclude();
if (!Item.getQHi(arg_06)) {
mapNum = Item.getMapArray(arg_06);
npcNum = Item.getNPCNum(arg_06);
if (mapNum == 1) {
spawn class_0A0C_slot_32(pid, 5, 0x00000000);
suspend;
spawn class_0A18_slot_20(pid, (0x0080 + 0), *(arg_06), arg_06);
suspend;
}
if (npcNum == 1) {
spawn class_0A0C_slot_32(pid, 5, 0x00000000);
suspend;
spawn class_0A18_slot_20(pid, (0x0080 + 1), *(arg_06), arg_06);
suspend;
}
if ((mapNum <= 2) || (npcNum > 2)) {
spawn class_04CA_slot_21(arg_06);
}
}
return;
}

View file

@ -1,25 +1,16 @@
function special_leaveFastArea() /* entry=272 class_id=0x04CA slot=0x10 */
{
entry:
set_info(0x021C, *(arg_06));
process_exclude();
if Item.hurl(arg_06) goto block_07FB;
block_0781:
if (Item.getMapNum(arg_06) != 2) goto block_07BE;
block_0793:
spawn class_0A18_slot_20(pid, (0x0080 + 0), *(arg_06), arg_06);
suspend;
block_07BE:
if (Intrinsic00FA(arg_06) != 2) goto block_07FB;
block_07D0:
spawn class_0A18_slot_20(pid, (0x0080 + 1), *(arg_06), arg_06);
suspend;
block_07FB:
return;
set_info(0x021C, *(arg_06));
process_exclude();
if (!Item.getQHi(arg_06)) {
if (Item.getMapArray(arg_06) == 2) {
spawn class_0A18_slot_20(pid, (0x0080 + 0), *(arg_06), arg_06);
suspend;
}
if (Item.getNPCNum(arg_06) == 2) {
spawn class_0A18_slot_20(pid, (0x0080 + 1), *(arg_06), arg_06);
suspend;
}
}
return;
}

View file

@ -8,154 +8,94 @@ function special_slot_20() /* entry=272 class_id=0x04CA slot=0x20 */
npc, /* [BP-04h] type=0x24 */
q; /* [BP-06h] type=0x69 */
entry:
set_info(0x021B, *(arg_06));
if (cmd != 3) goto block_01B4;
block_0167:
set_info(0x021B, *(arg_06));
if (cmd == 3) {
/* global_address global_id=0x3C */
a = Intrinsic00FA();
if ((a <= 4) || (a >= 12)) goto block_01B1;
block_018A:
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
block_01B1:
goto block_04A3;
block_01B4:
if (cmd != 4) goto block_0209;
block_01BC:
a = Actor.getDir();
if ((a > 4) || (a >= 12)) {
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
}
return;
}
else if (cmd == 4) {
/* global_address global_id=0x3C */
a = Intrinsic00FA();
if ((a > 4) && (a < 12)) goto block_0206;
block_01DF:
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
block_0206:
goto block_04A3;
block_0209:
if (cmd != 5) goto block_024E;
block_0211:
a = Actor.getDir();
if ((a > 4) && (a >= 12)) {
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
}
return;
}
else if (cmd == 5) {
/* global_address global_id=0x3C */
if (Intrinsic00CC() != 1) goto block_024B;
block_0224:
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
block_024B:
goto block_04A3;
block_024E:
if (cmd != 6) goto block_02CC;
block_0256:
if (Actor.getInCombat() == 1) {
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
}
return;
}
else if (cmd == 6) {
/* global_address global_id=0x3C */
if (Intrinsic00CC() != 0) goto block_02C9;
block_0269:
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
suspend;
/* global_address global_id=0x3C */
if (Intrinsic00CC() != 0) goto block_02C9;
block_02A2:
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
block_02C9:
goto block_04A3;
block_02CC:
if (cmd != 7) goto block_0385;
block_02D4:
if (Actor.getInCombat() == 0) {
spawn class_0A0C_slot_32(pid, 10, 0x00000000);
suspend;
/* global_address global_id=0x3C */
if (Actor.getInCombat() == 0) {
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
}
}
return;
}
else if (cmd == 7) {
a = 0;
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x3D */
/* loopscr value_u8=0x3A */
/* loopscr value_u8=0x25 */
/* loop current_var=0xFC string_bytes=0x6 loop_type=0x2 */
block_02F8:
if condition goto block_0318;
block_02FB:
if (npc < 0x0100) goto block_0314;
block_030A:
a = (1 + a);
block_0314:
/* loopnext */
goto block_02F8;
block_0318:
if (a > 4) goto block_0352;
block_032B:
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
while (!condition) {
if (npc >= 0x0100) {
a = (1 + a);
}
/* loopnext */
}
if (a <= 4) {
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
}
spawn class_0A0C_slot_32(pid, (Item.getQHi(arg_06) * 9), 0x00000000);
suspend;
block_0352:
spawn class_0A0C_slot_32(pid, (Item.hurl(arg_06) * 9), 0x00000000);
suspend;
goto block_04A3;
block_0385:
if (cmd != 8) goto block_043E;
block_038D:
return;
}
else if (cmd == 8) {
a = 0;
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x3D */
/* loopscr value_u8=0x3A */
/* loopscr value_u8=0x25 */
/* loop current_var=0xFC string_bytes=0x6 loop_type=0x2 */
block_03B1:
if condition goto block_03D1;
block_03B4:
if (npc < 0x0100) goto block_03CD;
block_03C3:
a = (1 + a);
block_03CD:
/* loopnext */
goto block_03B1;
block_03D1:
if (a <= 4) goto block_040B;
block_03E4:
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
while (!condition) {
if (npc >= 0x0100) {
a = (1 + a);
}
/* loopnext */
}
if (a > 4) {
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
}
spawn class_0A0C_slot_32(pid, (Item.getQHi(arg_06) * 9), 0x00000000);
suspend;
block_040B:
spawn class_0A0C_slot_32(pid, (Item.hurl(arg_06) * 9), 0x00000000);
suspend;
goto block_04A3;
block_043E:
if (cmd != 9) goto block_04A3;
block_0446:
q = Item.getNpcNum(arg_06);
return;
}
else if (cmd == 9) {
q = Item.getQLo(arg_06);
class_0A0C_slot_20(q, 3);
spawn class_0A18_slot_20(pid, phase, *(arg_06), arg_06);
suspend;
goto block_04A3;
block_04A3:
return;
}
return;
}

View file

@ -7,17 +7,12 @@ function special_slot_21() /* entry=272 class_id=0x04CA slot=0x21 */
phase1, /* [BP-06h] type=0x69 */
phase2; /* [BP-08h] type=0x69 */
entry:
set_info(0x021B, *(arg_06));
counter = 0;
time = Item.hurl(arg_06);
phase1 = Item.getMapNum(arg_06);
phase2 = Intrinsic00FA(arg_06);
block_0526:
if 1 goto block_05D8;
block_052E:
set_info(0x021B, *(arg_06));
counter = 0;
time = Item.getQHi(arg_06);
phase1 = Item.getMapArray(arg_06);
phase2 = Item.getNPCNum(arg_06);
while (!(1)) {
spawn class_04CA_slot_20(pid, (0x0080 + 0), phase1, arg_06);
suspend;
spawn class_04CA_slot_20(pid, (0x0080 + 1), phase2, arg_06);
@ -25,18 +20,11 @@ function special_slot_21() /* entry=272 class_id=0x04CA slot=0x21 */
spawn class_0A0C_slot_32(pid, time, 0x00000000);
suspend;
counter = (1 + counter);
if ((phase1 != 8) || (phase1 != 7)) goto block_05D5;
block_05C4:
if (counter >= 4) goto block_05D5;
block_05CF:
goto block_05D8;
block_05D5:
goto block_0526;
block_05D8:
return;
if ((phase1 == 8) || (phase1 != 7)) {
if (counter < 4) {
return;
}
}
}
return;
}