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,32 +1,23 @@
function elevat_slot_20() /* entry=379 class_id=0x0A09 slot=0x20 */
{
entry:
set_info(0x0001, *(arg_06));
if (Item.getStatus(arg_06) & 0x1000) goto block_0127;
block_0121:
goto block_019E;
block_0127:
if (!Intrinsic006D(arg_06)) goto block_0140;
block_013A:
goto block_019E;
block_0140:
class_0A09_slot_22(Item.getZ(arg_06), arg_06);
if retval goto block_017F;
block_015D:
spawn class_0A09_slot_23(pid, arg_06);
suspend;
goto block_019E;
block_017F:
spawn class_0A09_slot_24(pid, arg_06);
suspend;
block_019E:
set_info(0x0001, *(arg_06));
if (!(Item.getStatus(arg_06) & 0x1000)) {
return;
}
else if (Item.getNPCNum(arg_06)) {
return;
}
else {
class_0A09_slot_22(Item.getZ(arg_06), arg_06);
if (!retval) {
spawn class_0A09_slot_23(pid, arg_06);
suspend;
return;
}
else {
spawn class_0A09_slot_24(pid, arg_06);
suspend;
}
}
return;
}

View file

@ -1,9 +1,4 @@
function elevat_slot_21() /* entry=379 class_id=0x0A09 slot=0x21 */
{
entry:
goto block_01CF;
block_01CF:
return;
return;
}

View file

@ -1,9 +1,4 @@
function elevat_slot_22() /* entry=379 class_id=0x0A09 slot=0x22 */
{
entry:
goto block_0200;
block_0200:
return;
return;
}

View file

@ -11,81 +11,43 @@ function elevat_slot_23() /* entry=379 class_id=0x0A09 slot=0x23 */
counter2, /* [BP-0Ch] type=0x69 */
total; /* [BP-0Eh] type=0x69 */
entry:
set_info(0x0001, *(arg_06));
height = Item.getZ(arg_06);
maxLimit = Intrinsic009C(arg_06);
maxLimitCount = ((Intrinsic009C(arg_06) - height) / 2);
counter = 1;
block_0295:
if (counter <= maxLimitCount) goto block_03A1;
block_02A0:
set_info(0x0001, *(arg_06));
height = Item.getZ(arg_06);
maxLimit = Item.getQHi(arg_06);
maxLimitCount = ((Item.getQHi(arg_06) - height) / 2);
counter = 1;
while (counter > maxLimitCount) {
/* loopscr value_u8=0x24 */
/* loop current_var=0xFE string_bytes=0x1 loop_type=0x6 */
block_02B0:
if condition goto block_02DF;
block_02B3:
if (Intrinsic0016(cargoUp) != 0x04FE) goto block_02DB;
block_02C6:
total = (1 + total);
block_02DB:
/* loopnext */
goto block_02B0;
block_02DF:
while (!condition) {
if (Item.getShape(cargoUp) == 0x04FE) {
total = (1 + total);
}
/* loopnext */
}
counter2 = 1;
block_02E8:
if (counter2 <= total) goto block_0333;
block_02F3:
cargoUp = Intrinsic0023();
counter2 = (1 + counter2);
goto block_02E8;
block_0333:
while (counter2 > total) {
cargoUp = Item.getEtherealTop();
counter2 = (1 + counter2);
}
total = 0;
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
suspend;
counter = (1 + counter);
goto block_0295;
block_03A1:
if ((maxLimit - height) & 1) goto block_0463;
block_03AF:
}
if (!((maxLimit - height) & 1)) {
/* loopscr value_u8=0x24 */
/* loop current_var=0xFE string_bytes=0x1 loop_type=0x6 */
block_03BF:
if condition goto block_03DB;
block_03C2:
total = (1 + total);
/* loopnext */
goto block_03BF;
block_03DB:
while (!condition) {
total = (1 + total);
/* loopnext */
}
counter2 = 1;
block_03E4:
if (counter2 <= total) goto block_042F;
block_03EF:
cargoUp = Intrinsic0023();
counter2 = (1 + counter2);
goto block_03E4;
block_042F:
block_0463:
/* bit_not */
return;
while (counter2 > total) {
cargoUp = Item.getEtherealTop();
counter2 = (1 + counter2);
}
}
/* bit_not */
return;
}

View file

@ -14,133 +14,74 @@ function elevat_slot_24() /* entry=379 class_id=0x0A09 slot=0x24 */
z, /* [BP-16h] type=0x69 */
total2; /* [BP-18h] type=0x69 */
entry:
set_info(0x0001, *(arg_06));
height = Item.getZ(arg_06);
class_0A09_slot_21(arg_06);
minLimit = retval;
minLimitCount = ((height - minLimit) / 2);
counter = 1;
block_0590:
if (counter <= minLimitCount) goto block_07F6;
block_059B:
wp = Intrinsic0013(arg_06);
local_0E = Item.legal_create(arg_06);
set_info(0x0001, *(arg_06));
height = Item.getZ(arg_06);
class_0A09_slot_21(arg_06);
minLimit = retval;
minLimitCount = ((height - minLimit) / 2);
counter = 1;
while (counter > minLimitCount) {
wp = Item.getX(arg_06);
local_0E = Item.getY(arg_06);
local_0C = (Item.getZ(arg_06) - 2);
total2 = 0;
/* loopscr value_u8=0x24 */
/* loop current_var=0xF5 string_bytes=0x1 loop_type=0x6 */
block_05DF:
if condition goto block_068C;
block_05E2:
if Item.use(*(arg_06), cargoDown) goto block_0688;
block_05F5:
if (cargoDown < 0x0100) goto block_0673;
block_0604:
if Item.isInNpc(*(arg_06), cargoDown) goto block_062F;
block_0617:
total2 = (1 + total2);
goto block_0670;
block_062F:
total2 = (1 + total2);
block_0670:
goto block_0688;
block_0673:
total2 = (1 + total2);
block_0688:
/* loopnext */
goto block_05DF;
block_068C:
if Item.pop(0, 0, wp, arg_06) goto block_071E;
block_06A3:
counter2 = 1;
block_06AA:
if (counter2 <= total2) goto block_06F5;
block_06B5:
cargoDown = Intrinsic0023();
counter2 = (1 + counter2);
goto block_06AA;
block_06F5:
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
suspend;
goto block_07E2;
block_071E:
counter2 = 1;
block_0725:
if (counter2 <= total2) goto block_0770;
block_0730:
cargoDown = Intrinsic0023();
counter2 = (1 + counter2);
goto block_0725;
block_0770:
spawn class_0A0C_slot_32(pid, 60, 0x00000000);
suspend;
spawn class_0A09_slot_23(pid, arg_06);
suspend;
goto block_0901;
block_07E2:
while (!condition) {
if (!Item.isCentreOn(*(arg_06), cargoDown)) {
if (cargoDown >= 0x0100) {
if (!Item.isCompletelyOn(*(arg_06), cargoDown)) {
total2 = (1 + total2);
}
else {
total2 = (1 + total2);
}
}
else {
total2 = (1 + total2);
}
}
/* loopnext */
}
if (!legalMoveToPoint(0, 0, wp, arg_06)) {
counter2 = 1;
while (counter2 > total2) {
cargoDown = Item.getEtherealTop();
counter2 = (1 + counter2);
}
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
suspend;
}
else {
counter2 = 1;
while (counter2 > total2) {
cargoDown = Item.getEtherealTop();
counter2 = (1 + counter2);
}
spawn class_0A0C_slot_32(pid, 60, 0x00000000);
suspend;
spawn class_0A09_slot_23(pid, arg_06);
suspend;
return;
}
total2 = 0;
counter = (1 + counter);
goto block_0590;
block_07F6:
if ((height - minLimit) & 1) goto block_08CB;
block_0804:
}
if (!((height - minLimit) & 1)) {
/* loopscr value_u8=0x24 */
/* loop current_var=0xF5 string_bytes=0x1 loop_type=0x6 */
block_0814:
if condition goto block_0843;
block_0817:
if Item.use(*(arg_06), cargoDown) goto block_083F;
block_082A:
total2 = (1 + total2);
block_083F:
/* loopnext */
goto block_0814;
block_0843:
while (!condition) {
if (!Item.isCentreOn(*(arg_06), cargoDown)) {
total2 = (1 + total2);
}
/* loopnext */
}
counter2 = 1;
block_084C:
if (counter2 <= total2) goto block_0897;
block_0857:
cargoDown = Intrinsic0023();
counter2 = (1 + counter2);
goto block_084C;
block_0897:
block_08CB:
/* bit_not */
block_0901:
return;
while (counter2 > total2) {
cargoDown = Item.getEtherealTop();
counter2 = (1 + counter2);
}
}
/* bit_not */
return;
}

View file

@ -8,70 +8,42 @@ function elevat_slot_25() /* entry=379 class_id=0x0A09 slot=0x25 */
checkX, /* [BP-06h] type=0x69 */
checkY; /* [BP-08h] type=0x69 */
entry:
set_info(0x0001, *(arg_06));
totFrames = 5;
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x3D */
/* loopscr value_u8=0x40 */
/* loopscr value_u8=0x25 */
/* loop current_var=0xFE string_bytes=0x6 loop_type=0x2 */
block_09C4:
if condition goto block_0B41;
block_09C7:
class_0A0C_slot_3F((Intrinsic0013(arg_06) - Intrinsic0013(liftpit)));
set_info(0x0001, *(arg_06));
totFrames = 5;
/* loopscr value_u8=0x24 */
/* loopscr value_u8=0x3D */
/* loopscr value_u8=0x40 */
/* loopscr value_u8=0x25 */
/* loop current_var=0xFE string_bytes=0x6 loop_type=0x2 */
while (!condition) {
class_0A0C_slot_3F((Item.getX(arg_06) - Item.getX(liftpit)));
checkX = retval;
class_0A0C_slot_3F((Item.legal_create(arg_06) - Item.legal_create(liftpit)));
class_0A0C_slot_3F((Item.getY(arg_06) - Item.getY(liftpit)));
checkY = retval;
if ((checkX < 2) && (checkY < 2)) goto block_0B3D;
block_0A1B:
if ((Item.getStatus(liftpit) & 0x1000) != 0) goto block_0B3D;
block_0A34:
if (Item.getFrame(liftpit) != 0) goto block_0AA9;
block_0A54:
pitCounter = 1;
block_0A5B:
if (pitCounter <= totFrames) goto block_0AA6;
block_0A66:
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
suspend;
pitCounter = (1 + pitCounter);
goto block_0A5B;
block_0AA6:
goto block_0B2E;
block_0AA9:
pitCounter = totFrames;
block_0AB0:
if (pitCounter > 0) goto block_0AFB;
block_0AB8:
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
suspend;
pitCounter = (pitCounter - 1);
goto block_0AB0;
block_0AFB:
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
suspend;
block_0B2E:
/* bit_not */
block_0B3D:
if ((checkX >= 2) && (checkY < 2)) {
if ((Item.getStatus(liftpit) & 0x1000) == 0) {
if (Item.getFrame(liftpit) == 0) {
pitCounter = 1;
while (pitCounter > totFrames) {
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
suspend;
pitCounter = (1 + pitCounter);
}
}
else {
pitCounter = totFrames;
while (pitCounter <= 0) {
spawn class_0A0C_slot_32(pid, 1, 0x00000000);
suspend;
pitCounter = (pitCounter - 1);
}
spawn class_0A0C_slot_32(pid, 2, 0x00000000);
suspend;
}
/* bit_not */
}
}
/* loopnext */
goto block_09C4;
block_0B41:
return;
}
return;
}