Conversation Between Blah and chrunch
1 to 15 of 33
  1. chrunch
    September 2nd, 2015 11:22 PM
    chrunch
    Well I feel pretty stupid now, the hidecoins was the remnants of an earlier version of the script and I forgot to remove it. Thanks, it works great!
  2. Blah
    September 2nd, 2015 4:51 AM
    Blah
    Waitspecial is the PKSV equivalent to waitstate, so yes that's not the issue. I don't think this has anything to do with the routine, as myself and others don't seem to have problems. I think it's your script.
    closeonkeypress
    hidecoins 0x0 0x0
    are unnecessary. Also for the comparisons I think it may be better to do something like a copy var, since irc lastresult is overwritten by the compare. Have you tested it in a case where you're not using the show coins?
  3. chrunch
    September 2nd, 2015 1:44 AM
    chrunch
    I've been trying to get your scrolling multichoice routine to work, and although I've been successful with the actual multichoice, it seems once I've used it, subsequent textboxes don't show up correctly. Apart from a slight delay, they still act normally, its just they aren't visible until I reenter the map. My script is in the spoiler below if it helps (I bolded the part which uses the box):
    Spoiler:
    #dynamic 0x800000

    #org @start
    lock
    faceplayer
    msgbox @string1 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x1 goto @snippet1
    msgbox @string2 MSG_NORMAL
    release
    end

    #org @snippet1
    buffernumber 0x0 0x4051
    msgbox @string3 MSG_KEEPOPEN
    goto @snippet2

    #org @snippet2
    setvar 0x8000 0x0
    setvar 0x8001 0xB
    setvar 0x8004 0x0
    special 0x158
    waitstate
    compare LASTRESULT 0x0
    if 0x1 goto @snippet3
    compare LASTRESULT 0x1
    if 0x1 goto @snippet4
    compare LASTRESULT 0x2
    if 0x1 goto @snippet5
    compare LASTRESULT 0x3
    if 0x1 goto @snippet6
    compare LASTRESULT 0x4
    if 0x1 goto @snippet7
    compare LASTRESULT 0x5
    if 0x1 goto @snippet12
    compare LASTRESULT 0x6
    if 0x1 goto @snippet13
    compare LASTRESULT 0x7
    if 0x1 goto @snippet14
    compare LASTRESULT 0x8
    if 0x1 goto @snippet15
    compare LASTRESULT 0x9
    if 0x1 goto @snippet16
    compare LASTRESULT 0xA
    if 0x1 goto @snippet17

    closeonkeypress
    hidecoins 0x0 0x0
    msgbox @string2 MSG_NORMAL
    release
    end

    #org @snippet3
    hidecoins 0x0 0x0
    bufferitem 0x1 0x6F
    buffernumber 0x2 0x8
    compare 0x4051 0x8
    if 0x0 goto @snippet9
    checkitemroom 0x6F 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x8
    giveitem 0x6F 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet4
    hidecoins 0x0 0x0
    bufferitem 0x1 0x3F
    buffernumber 0x2 0x10
    compare 0x4051 0x10
    if 0x0 goto @snippet9
    checkitemroom 0x3F 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x10
    giveitem 0x3F 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet5
    hidecoins 0x0 0x0
    bufferitem 0x1 0x40
    buffernumber 0x2 0x10
    compare 0x4051 0x10
    if 0x0 goto @snippet9
    checkitemroom 0x40 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x10
    giveitem 0x40 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet6
    hidecoins 0x0 0x0
    bufferitem 0x1 0x41
    buffernumber 0x2 0x10
    compare 0x4051 0x10
    if 0x0 goto @snippet9
    checkitemroom 0x41 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x10
    giveitem 0x41 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet7
    hidecoins 0x0 0x0
    bufferitem 0x1 0x43
    buffernumber 0x2 0x10
    compare 0x4051 0x10
    if 0x0 goto @snippet9
    checkitemroom 0x43 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x10
    giveitem 0x43 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet9
    msgbox @string8 MSG_NORMAL
    release
    end

    #org @snippet10
    msgbox @string9 MSG_NORMAL
    release
    end

    #org @snippet11
    msgbox @string2 MSG_NORMAL
    release
    end

    #org @snippet12
    hidecoins 0x0 0x0
    bufferitem 0x1 0x46
    buffernumber 0x2 0x10
    compare 0x4051 0x10
    if 0x0 goto @snippet9
    checkitemroom 0x46 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x10
    giveitem 0x46 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet13
    hidecoins 0x0 0x0
    bufferitem 0x1 0x42
    buffernumber 0x2 0x10
    compare 0x4051 0x10
    if 0x0 goto @snippet9
    checkitemroom 0x42 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x10
    giveitem 0x42 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet14
    hidecoins 0x0 0x0
    bufferitem 0x1 0xE3
    buffernumber 0x2 0x30
    compare 0x4051 0x30
    if 0x0 goto @snippet9
    checkitemroom 0xE3 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x30
    giveitem 0xE3 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet15
    hidecoins 0x0 0x0
    bufferitem 0x1 0xE2
    buffernumber 0x2 0x30
    compare 0x4051 0x30
    if 0x0 goto @snippet9
    checkitemroom 0xE2 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x30
    giveitem 0xE2 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet16
    hidecoins 0x0 0x0
    bufferitem 0x1 0xBA
    buffernumber 0x2 0x30
    compare 0x4051 0x30
    if 0x0 goto @snippet9
    checkitemroom 0xBA 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x30
    giveitem 0xBA 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @snippet17
    hidecoins 0x0 0x0
    bufferitem 0x1 0xC5
    buffernumber 0x2 0x60
    compare 0x4051 0x60
    if 0x0 goto @snippet9
    checkitemroom 0xC5 0x1
    compare LASTRESULT 0x0
    if 0x1 goto @snippet10
    msgbox @string5 MSG_YESNO
    compare LASTRESULT 0x1
    if 0x0 goto @snippet11
    subvar 0x4051 0x60
    giveitem 0xC5 0x1 MSG_OBTAIN
    msgbox @string6 MSG_NORMAL
    goto @snippet1

    #org @string1
    = Welcome, welcome!\pDo you want to trade in your BP\nfor prizes?

    #org @string2
    = Come back any time!

    #org @string3
    = [black_fr]Current balance: [buffer1]BP

    #org @string5
    = Are you sure? A [buffer2]\nwill be [buffer3] BP.

    #org @string6
    = Would you like to make another\npurchase?

    #org @string8
    = Sorry, you need more BP to buy a\n[buffer2].

    #org @string9
    = It appears that you don't have\nany space.


    Only thing I can think of is maybe waitstate is the wrong command to use, your script uses "waitspecial" but that's not in XSE so I assumed waitstate was the equivalent.
  4. chrunch
    April 22nd, 2015 12:34 AM
    chrunch
    There's a problem with your adjusting market prices by percentage routine (or it might be intentional). It works fine for the most part, but let's say I want to give the player a 10% discount. the -10% applies to selling items too. Its not the biggest problem but it would be an annoyance for anyone trying to sell at that shop.
  5. Blah
    March 29th, 2015 9:30 AM
    Blah
    They edit bytes in the map header. The bytes are read by the game to determine what to do ect. If you want to edit what a specific map type does, then it'd probably require some ASM work.
  6. chrunch
    March 28th, 2015 11:53 PM
    chrunch
    Yup, looks like that's what they are. Haven't tested 0x7E6 and up but below that are definitely trainer flags.

    Is it ok if I ask you about something else too? About the map "types" which you can see in A-map (things like village, city, route, underground, underwater, etc.) I noticed when using the underwater type, it seems to disable surfing. Do you have information on what the types do, or anything on how to edit them?
  7. Blah
    March 26th, 2015 6:04 AM
    Blah
    Upto flag 0x7E6 might be trainer flags. Try to set flag 0x700 and do a battle with trainer 0x200.

    The remaining few flags after 0x7E6 may be temporary, if they aren't, then it's likely unused.
  8. chrunch
    March 25th, 2015 10:00 PM
    chrunch
    I have, they don't appear to be. At least they don't reset if you leave the map or load a save game.
  9. Blah
    March 25th, 2015 6:01 AM
    Blah
    Hmm, I'm a little surprised no one has found any data about them. Have you tried using them in scripts and confirmed that they are not temporary variables?
  10. chrunch
    March 25th, 2015 3:46 AM
    chrunch
    Hey, just wondering if I could make a little request: would you be able to find out if the flags 0x700 to 0x7FF do anything, and if they'd be safe to use? Just asking because I noticed those flags aren't listed anywhere, I'm actually pretty interested in them. No problem if you don't have time, I'm just curious haha
  11. Blah
    February 9th, 2015 7:40 AM
    Blah
    Hi, you'd need to change the three lines prior:
    mov r0, #0xFF
    lsl r0, r0, #0x1
    add r0, r0, #0x4
    Each of these lines are doing small mathematical operations to register 0, which in the end holds the flag value.

    mov r0, #0xFF
    This line will set r0, to 0xFF. Sadly you can't just mov r0, #0xsomeFlagValue because 0xFF is the maximum value you can have in a register via the mov command.


    lsl r0, r0, #0xvalue
    Here we're doing a binary shift. Binary shifting a number to the left is the same as adding a 0 in binary. I.e multiplying by 2. As you may be able to guess, this this exponention. That is lsl r0, r0, #0x2 is the same as r0 = r0 * 4. That would imply that lsl r0, r0, #0x3 is the same as r0 = r0 *8. I think you see the pattern.

    add r0, r0, #0x4
    FInally, I'm just adding a constant value (0x4 here) to get the flag I want. This is similar to the move command as in it's limited. That's why we can't really do something like mov r0, #0x0; add r0, r0, #0xflag number.


    So those are the values you need to change. How much of it you need to change depends on the flag number.
  12. chrunch
    February 8th, 2015 10:25 PM
    chrunch
    Hi again! I was just wondering if I could ask you a question about this routine. I want to change the flag used to activate it, is it enough to just change the "0x202" on line 10, or do I need to do something else?
  13. chrunch
    December 6th, 2014 3:19 AM
    chrunch
    Well what I actually meant was how the national dex fixed the problem. :P I doubt I'll be able to fix it completely (no clue what I'm meant to be doing) but thanks for all the help anyways!
  14. Blah
    December 4th, 2014 11:03 PM
    Blah
    It's not that the national dex is "fixed", there's without a doubt, a flag check somewhere if a Pokemon's species index exceeds a particular amount. What is the Pokedex's default size in hex? You need to find a line that compares a register to that value, and then goes off to do a flag check.
  15. chrunch
    December 4th, 2014 10:05 PM
    chrunch
    Yeah, it asks if you want a nickname and says it got added to the pokedex. I would assume that it says it got placed in a box too, although I haven't tested it.

    I'm sure I made all the necessary changes, I'm not really sure what to do now honestly. Is there anything I can do to find out how the national dex fixed it?