View Single Post
Old January 31st, 2013 (6:41 PM).
thetripplenine's Avatar
thetripplenine thetripplenine is offline
    Join Date: Jan 2013
    Location: California
    Age: 19
    Gender: Male
    Nature: Bold
    Posts: 98
    Originally Posted by DrFuji View Post
    But if the flag isn't set that's then it goes to to the pointer rather than the other way around. The if command was comparing the flag's status to 0x0 rather than 0x1.

    I'm not entirely sure what could be causing the problem though. Have you decompiled the script to see if any commands are messed up (since you're working with already inserted scripts), Nossab Blue?

    There's no need to have the script branch off to the @take section if you want everything to activate. You can also turn the play by using the applymovement command but instead of using the mother's Event Number, use 0xFF (which is the player's). The running shoes are given by setting the flag 0x8C0. Finally, the command 'giveitem' always displays an automatic message whenever you use it. If you want it to be silent then it would be better to use 'additem' instead.

    All-in-all, this script should be closer to what you want:

    #dynamic 0x9C0000
    #org @start
    checkflag 0x8C0 // Changed to 0x8C0 since it is going to be set later on during the script anyway
    if 0x1 goto @done
    applymovement 0x0 @move
    applymovement 0xFF @turn // Added movement command for the player so they will face the mother
    waitmovement 0x0
    msgbox @1 0x6 // Moved the @take section of the script here
    additem 0x4 0x5 // Changed to additem
    msgbox @received2 0x6
    additem 0xD 0x5 // Changed to additem
    msgbox @received3 0x6
    setflag 0x8C0 // In Pokemon Emerald the Running Shoes are activated by the flag 0x8C0
    msgbox @received 0x6
    applymovement 0x0 @move_back
    waitmovement 0x0
    #org @done
    #org @move
    #raw 0x08
    #raw 0x08
    #raw 0x0B
    #raw 0x0B
    #raw 0x0B
    #raw 0x0B
    #raw 0x0B
    #raw 0xFE
    #org @move_back
    #raw 0x0A
    #raw 0x0A
    #raw 0x0A
    #raw 0x0A
    #raw 0x0A
    #raw 0x09
    #raw 0x09
    #raw 0x03
    #raw 0xFE
    #org @turn // Player movements
    #raw 0x2
    #raw 0xFE
    #org @1
    = Wait [player]! You cannot be a recruit\nwithout the propper attier.
    #org @received
    = [Player] received the \c\h01ÊRUNNING\nSHOES!
    #org @received2
    = [Player] received \c\h01ÊPokéballs!
    #org @received3
    = [Player] received \c\h01ÊPotions![/spoiler]
    Thanks for helping me with all those times i needed help :D and now.