View Single Post
Old January 18th, 2013 (3:39 AM).
karatekid552's Avatar
karatekid552 karatekid552 is offline
What happens if I push it?....
    Join Date: Nov 2012
    Location: Do you really want to know? Really?
    Gender: Male
    Nature: Bold
    Posts: 1,766
    Originally Posted by SpadeEdge16 View Post
    Okay, so I don't know what's up, if I'm just not noticing something obvious with this or what, but it's happened to me before. This script won't work, that's it. The only way how I've been able to fix this problem if by switching "if 0x1" to "if 0x0", but on other scripts when I use "if 0x1" the same exact way, it works just fine. Why does this keep happening?

    #dynamic 0x800000
    #org @start
    checkflag 0x2B
    if 0x1 goto @done
    applymovement 0x1 @mom
    waitmovement 0x1
    msgbox @alert 0x6
    applymovement 0x1 @go
    waitmovement 0x1
    msgbox @mom1 0x6
    setflag 0x2B
    setflag 0x2C
    setflag 0x2D

    #org @done

    #org @alert
    = MOM: [player]!

    #org @mom1
    = You were supposed to be meeting\nPROFESSOR OAK outside so you could\lget your first POKEMON!\lGet out there so you're not\lkeeping him waiting any longer!

    #org @mom
    #raw 0x62
    #raw 0xFE

    #org @go
    #raw 0x1E
    #raw 0x20
    #raw 0x20
    #raw 0x20
    #raw 0x1E
    #raw 0x3
    #raw 0xFE

    It means your flag is already set. There is a good chance that low number flags like 0x2B are in use by the game just to keep track of stuff. I found a list of safe flags once, but since I can't remember them all, I do know that all of the flags in the 1000's are safe and will work just fine.

    As you probably already know, "if 0x1" means the if the flag is set, go to @done. "If 0x0" means if the flag is not set, go to wherever the pointer goes. So, if it checks the flag and it is set (0x1) but your script only says what to do if not set (If 0x0...) the script will just continue.

    Paired with Simba