Prev: $3326 Up: Map Next: $3472
$33BF: Restore a character buffer from page 0
Used by the routines at $0800, $15B3, $17E5, $191B, $1EE3, $2241, $2696, $27D2, $29C8, $2B52, $2E13, $35EF, $3AB4, $3AD5 and $BE09.
$33BF LDA #$60 Place the base address of the current character's buffer at $4E.
$33C1 STA $4E
$33C3 LDA #$78
$33C5 STA $4F
$33C7 LDX $60
$33C9 BEQ $33D0
$33CB INC $4F
$33CD DEX
$33CE BNE $33CB
$33D0 LDY #$00 Copy the character's animatory state from $26 to byte $60 of his buffer.
$33D2 LDA $26
$33D4 STA ($4E),Y
$33D6 INY Y=$01.
$33D7 LDA $FC Copy the character's x-coordinate from $FC to byte $61 of his buffer.
$33D9 STA ($4E),Y
$33DB INY Y=$02.
$33DC LDA $FB Copy the character's y-coordinate from $FB to byte $62 of his buffer.
$33DE STA ($4E),Y
$33E0 INY Y=$03.
$33E1 LDA $29 Collect the primary command routine address from $29 and place it in bytes $63 and $64 of the character's buffer.
$33E3 STA ($4E),Y
$33E5 INY
$33E6 LDA $2A
$33E8 STA ($4E),Y
$33EA INY Y=$05.
$33EB LDA $A6 Copy the contents of $A6 into byte $65 of the character's buffer.
$33ED STA ($4E),Y
$33EF INY Y=$06.
$33F0 LDA $A7 Copy the contents of $A7 into byte $66 of the character's buffer.
$33F2 STA ($4E),Y
$33F4 INY Y=$07.
$33F5 LDA $A8 Copy the contents of $A8 into byte $67 of the character's buffer.
$33F7 STA ($4E),Y
$33F9 INY Y=$08.
$33FA LDA $A9 Copy the contents of $A9 into byte $68 of the character's buffer.
$33FC STA ($4E),Y
$33FE INY Y=$09.
$33FF LDA $AA Collect the interruptible subcommand routine address from $AA and place it into bytes $69 and $6A of the character's buffer.
$3401 STA ($4E),Y
$3403 INY
$3404 LDA $AB
$3406 STA ($4E),Y
$3408 INY Y=$0B.
$3409 LDA $AC Copy the contents of $AC into byte $6B of the character's buffer.
$340B STA ($4E),Y
$340D INY Y=$0C.
$340E LDA $AD Copy the contents of $AD into byte $6C of the character's buffer.
$3410 STA ($4E),Y
$3412 INY Y=$0D.
$3413 LDA $AE Copy the contents of $AE into byte $6D of the character's buffer.
$3415 STA ($4E),Y
$3417 INY Y=$0E.
$3418 LDA $AF Copy the contents of $AF into byte $6E of the character's buffer.
$341A STA ($4E),Y
$341C INY Y=$0F.
$341D LDA $B0 Collect the uninterruptible subcommand routine address from $B0 and place it into bytes $6F and $70 of the character's buffer.
$341F STA ($4E),Y
$3421 INY
$3422 LDA $B1
$3424 STA ($4E),Y
$3426 INY Y=$11.
$3427 LDA $B2 Copy the contents of $B2 into byte $71 of the character's buffer.
$3429 STA ($4E),Y
$342B INY Y=$12.
$342C LDA $B3 Copy the contents of $B3 into byte $72 of the character's buffer.
$342E STA ($4E),Y
$3430 INY Y=$13.
$3431 LDA $B4 Copy the contents of $B4 into byte $73 of the character's buffer.
$3433 STA ($4E),Y
$3435 INY Y=$14.
$3436 LDA $B5 Copy the contents of $B5 into byte $74 of the character's buffer.
$3438 STA ($4E),Y
$343A INY Y=$15.
$343B LDA $3B Collect the address reached in the character's command list from $3B and place it into bytes $75 and $76 of the character's buffer.
$343D STA ($4E),Y
$343F INY
$3440 LDA $3C
$3442 STA ($4E),Y
$3444 INY Y=$17.
$3445 LDA $3D Collect the start address of the character's command list from $3D and place it into bytes $77 and $78 of the character's buffer.
$3447 STA ($4E),Y
$3449 INY
$344A LDA $3E
$344C STA ($4E),Y
$344E INY Y=$19.
$344F LDA $FF Copy the contents of $FF into byte $79 of the character's buffer.
$3451 STA ($4E),Y
$3453 INY Y=$1A.
$3454 LDA $3F Copy the contents of $3F into byte $7A of the character's buffer.
$3456 STA ($4E),Y
$3458 INY Y=$1B.
$3459 LDA $39 Collect the continual subcommand routine address from $39 and place it into bytes $7B and $7C of the character's buffer.
$345B STA ($4E),Y
$345D INY
$345E LDA $3A
$3460 STA ($4E),Y
$3462 INY Y=$1D.
$3463 LDA $4E Copy the contents of $4E (i.e. $60) into the unused byte $7D of the character's buffer.
$3465 STA ($4E),Y
$3467 INY Y=$1E.
$3468 LDA $4E Copy the contents of $4E (i.e. $60) into the unused byte $7E of the character's buffer.
$346A STA ($4E),Y
$346C INY Y=$1F.
$346D LDA $4E Copy the contents of $4E (i.e. $60) into the unused byte $7F of the character's buffer.
$346F STA ($4E),Y
$3471 RTS
Prev: $3326 Up: Map Next: $3472