Conversation Between jiangzhengwenjzw and Blah
76 to 89 of 89
  1. jiangzhengwenjzw
    January 17th, 2016 5:01 AM
    jiangzhengwenjzw
    Hey, my friend. view Skype please :p
  2. Blah
    October 24th, 2015 8:54 AM
    Blah
    yes, seems like you logged off though :c
  3. jiangzhengwenjzw
    October 24th, 2015 8:16 AM
    jiangzhengwenjzw
    I need you now for some information on skype :)
  4. jiangzhengwenjzw
    October 16th, 2015 8:03 AM
    jiangzhengwenjzw
    Would we have a talk on skype now? :P
  5. jiangzhengwenjzw
    October 9th, 2015 6:16 AM
    jiangzhengwenjzw
    Hello, I'm come here for help again. Could we have some talk on skype? I've provided some information there. :)
  6. Blah
    October 1st, 2015 6:10 AM
    Blah
    Yeah, I'll hop on, one sec!
  7. jiangzhengwenjzw
    September 30th, 2015 6:39 AM
    jiangzhengwenjzw
    Hi, long time no see! Would we have some talk on skype? :)
  8. jiangzhengwenjzw
    May 24th, 2015 6:46 AM
    jiangzhengwenjzw
    I've sent something you may be interested in on Skype.
  9. jiangzhengwenjzw
    May 13th, 2015 6:29 AM
    jiangzhengwenjzw
    Yeah, you're right and actually the first function is to edit the "msgbox" textbox's palette and the second is to edit the table which contains the pointer of palette of the other style of textbox,which is used in "yesnobox", "multichoice", "showpokepic" and other similar commands.

    For the intro part, I found a function that refreshed the I/O and I really can't find a way to made some conditional branch to make it do what I want to do in I/O because it's called some time before the oak's textbox (also called in titlescreen and so on)
  10. Blah
    May 13th, 2015 4:42 AM
    Blah
    There really isn't a good way to find it. The best way would be to look at the starting sequence of the game's code and try to find where specifically it's being called within the intro. Else, take a look at the location of the graphics of the textbox. Such information can be found in NSE or in some guides around the forum. Using that information you can set a BPR at the location of the image.
  11. jiangzhengwenjzw
    May 11th, 2015 6:01 AM
    jiangzhengwenjzw
    The general question: The introduction part before the main game(such as the oak's intro and naming part) contains some textboxes and I want them to be transparent ones.

    Then I will say all that I know: (How to make the textboxes in the game transparent, which also support transparent "showpokepic" and "multichoice" and so on has been already done by me and the offsets and parts of the routines are from another person)

    The free ram offset is 0x0203f4fe and we use 1,2,3,4,5 as five different palette and 0 to change it to the normal not transparent textbox.

    Firstly hack the normal textbox and the routine will be follow:

    .thumb
    main:
    push {r0}
    ldr r0, ram
    ldrb r0, [r0, #0x0]
    cmp r0, #0x0 @check the free ram
    bne new
    mov r0, #0x1F @restore the I/O
    ldr r1, offset
    strb r0, [r1, #0x0]
    strb r0, [r1, #0x1]
    mov r0, #0x40
    strb r0, [r1, #0x8]
    mov r0, #0x1E
    strb r0, [r1, #0x9]
    mov r0, #0x10
    strb r0, [r1, #0xA]
    mov r0, #0x0
    strb r0, [r1, #0xB]
    ldr r1, normal @get the normal palette
    b original

    new:
    mov r0, #0x3F @hack the I/O
    ldr r1, offset
    strb r0, [r1, #0x0]
    strb r0, [r1, #0x9]
    mov r0, #0x1F
    strb r0, [r1, #0x1]
    mov r0, #0x41
    strb r0, [r1, #0x8]
    mov r0, #0xF
    strb r0, [r1, #0xA]
    mov r0, #0xA
    strb r0, [r1, #0xB]
    ldr r1, ram
    ldrb r1, [r1, #0x0]
    cmp r1, #0x2 @some different palettes
    beq black2nd
    cmp r1, #0x3
    beq black3rd
    cmp r1, #0x4
    beq black4th
    cmp r1, #0x5
    beq black5th
    ldr r1, black1
    b original

    black2nd:
    ldr r1, black1
    add r1, #0x20
    b original

    black3rd:
    ldr r1, black1
    add r1, #0x40
    b original

    black4th:
    ldr r1, black1
    add r1, #0x60
    b original

    black5th:
    ldr r1, black1
    add r1, #0x80

    original:
    pop {r0} @original codes
    add r0,r0,r1
    pop {r1}
    bx r1

    .align 2
    ram: .word 0x0203f4fe
    normal: .word 0x08471dec @original palette
    black1: .word 0x08900000 @new palette offset
    offset: .word 0x04000048

    write it at some place and then change the bytes at 0x150448 to 00 4F 38 47 XX XX XX 08(+1 pointer of the compiled code)

    Then do something for the next hacking:
    repoint the table (0x50 bytes at 0x471e8c) to someplace and build a new table like this and change all of its palette pointers to our new palette offset.



    Then other textboxes: (I also use it to hack the I/O, but obviously it can be ignored as they are always used with the above hack)
    .thumb
    main:
    push {r0-r1, lr}
    ldr r0, ram
    ldrb r0, [r0]
    cmp r0, #0x0
    bne black
    ldr r5, paltable
    lsl r4, r4, #0x3
    pop {r0-r1, pc}


    black:
    mov r0, #0x3F
    ldr r1, offset
    strb r0, [r1, #0x0]
    strb r0, [r1, #0x9]
    mov r0, #0x1F
    strb r0, [r1, #0x1]
    mov r0, #0x41
    strb r0, [r1, #0x8]
    mov r0, #0xF
    strb r0, [r1, #0xA]
    mov r0, #0xA
    strb r0, [r1, #0xB]
    ldr r5, newtable
    lsl r4, r4, #0x3
    pop {r0-r1, pc}


    .align 2
    ram: .word 0x0203f4fe @free ram space
    paltable: .word 0x08910000 @the original table
    newtable: .word 0x08920000 @newtable, changed the palette pointers
    offset: .word 0x04000048 @I/O

    Then write the code at 0x471e8c(as the data are repointed)

    Then change bytes at 0x14FFEE to 21 F3 4D FF(to branch to 0x471e8c)

    Then all is done, and we can use writebytetooffset 0x(0,1,2,3,4,5) to hack the textbox.


    However, I can't find the function to branch from to hack the part before the main game and the I/O is always refreshed and it's obviously not good to edit the function because if you add breakpoints on it we will find it is called in many situations.

    So could you tell me how to do it? I really want to know it. I know the topic is kinda long, but I hope you can see it through and get what I know.

    Thank you very much! :)
  12. jiangzhengwenjzw
    March 28th, 2015 7:01 PM
    jiangzhengwenjzw
    OK, thank you very much! By the way, the link in your signature is broken, maybe you will want to fix it.
  13. Blah
    March 28th, 2015 6:58 PM
    Blah
    No, I don't mind at all. I'm a Uni student too, so I understand the struggles :)
  14. jiangzhengwenjzw
    March 28th, 2015 6:50 PM
    jiangzhengwenjzw
    Hello! I really want to join your workshop to learn some asm skills, but as I'm a univ student, I do not have enough time every week to do all the tasks (As the tasks will be more and more complex in the following weeks)
    Would you mind I join the skype room but only do some of the tasks or even nothing in some weeks? (for example, examinations week)