I
IncuTyph
Guest
So, I'm looking at code that's ripped from Earthbound (it was more like a demo using EB's code, but wasn't finished) to try and learn some things, but I have a question regarding how something works. There's an end step event for the player object for party movement that calls upon a script called get_flag, seen here on this line:
When I go to see what that script actually does, it simply reads:
I'm honestly a bit confused on what's happening with this. There wasn't a list of flags that I could find, so I'm not exactly sure where the 28 is coming from, or what it does. Am I missing something that would help me understand, or am I just not 'getting it'? I was hoping to use it to help me visualize the concept of flags, since, to be frank, reading straight from a manual doesn't seem to help me understand things. The examples given in the manual don't always make it any easier to understand. I kinda have to see it in action for real to make connections in my brain to actually learn for some reason. I guess I'm a visual learner? I don't know. Anyway though, I had an idea for flags for my own project, but getting stuck on understanding the above situation, I'm not sure if what I was going to go with was going to work now. Any help or advice is appreciated though!
GML:
var more;
more = get_flag(28) + 1
GML:
///get_flag(flag)
return global.flag[argument0]