Advertiser Content


Visitor Messages

31 to 37 of 37
  1. Nisarg
    September 6th, 2017 8:17 AM
    By what name do u go there?
  2. Nisarg
    September 5th, 2017 8:56 AM
    I'll add you!
    I am seekiñg help from asmers....
  3. Nisarg
    September 4th, 2017 2:52 PM
    Are you on discord?
    Add me if u r. ^^
  4. colonelsalt
    August 31st, 2017 5:33 PM
    Dude, I'm eternally grateful. Your fix for JPAN's backsprite switch has really saved my hack from probably weeks of delay. I don't know where I would have even begun without finding it. Thanks so much, and keep up your ASM-ing!
  5. Touched
    May 2nd, 2017 9:53 AM
    I haven't tried it, but the npc_change_sprite function in there changes the palette, so you should be able to use one of those (either pal_path_for_npc or npc_load_two_palettes__and_record). Is that code 100% working? I want to edit my post so other people don't have the same issues.
  6. Touched
    April 30th, 2017 5:31 AM
    Sorry for the late reply. You aren't using it incorrectly, my code is just incorrect. Try this instead (I messed up some of the registers).


    .align 2

    push {r4-r6, lr}
    sub sp, #4

    ldr r4, variables

    @@ Determine npc state id from person id
    ldr r3, saveblock1_mapdata
    ldr r3, [r3]
    ldrb r0, [r4] @ person/local ID from var 0x8000
    ldrb r1, [r3, #5] @ current map
    ldrb r2, [r3, #4] @ current bank
    mov r3, sp
    ldr r5, npc_id_by_local_id_and_map_ret_success
    bl call_via_r5
    cmp r0, #0 @ failure check
    bne instant_npc_frame_switch_return

    @@ Get npc_state
    mov r0, sp
    ldrb r1, [r0] @ npc_id
    lsl r0, r1, #3 @ npc_states + 0x24 * npc_id
    add r0, r1
    lsl r0, #2
    ldr r1, npc_states
    add r6, r0, r1

    @@ Change Sprite
    mov r0, r6 @ npc_state
    ldrb r1, [r4, #2] @ sprite index from var 0x8001
    ldr r5, npc_change_sprite
    bl call_via_r5

    @@ Update direction to prevent graphical artifacts
    mov r0, r6
    ldrb r1, [r0, #0x18] @ npc direction
    lsr r1, #4
    ldr r5, npc_turn
    bl call_via_r5

    add sp, #4
    pop {r4-r6, pc}

    bx r5

    .align 2
    variables: .word 0x020370B8 @ script var 0x8000
    saveblock1_mapdata: .word 0x03005008
    npc_states: .word 0x02036E38
    npc_change_sprite: .word 0x081507BC + 1
    npc_turn: .word 0x0805F218 + 1
    npc_id_by_local_id_and_map_ret_success: .word 0x0805DF84 + 1
  7. FBI
    April 2nd, 2017 6:59 AM
    Sorry for the late reply. Glad you managed to fix it :)

About Me


Total Posts
Activity by Forum
Visitor Messages
General Information
  • Last Activity: 1 Day Ago 5:49 PM
  • Join Date: March 11th, 2016
  • Referrals: 0