S
shanedaman112
Guest
Ok, sorry for the beastly title, but it's basically the only way to say it. I'd say i'm pretty experienced in gml, but I just upgraded to gm:studio (humble bundle, surprise, surprise) and I need something equivalent to show_message_ext. I need to set a variable in the middle of a code. Like for example, midway into the step event, var1 = msg_choice("Pick","1","2","3"). If I was targeting the same variable every time that wouldn't be so bad because I could implement it directly into an object that displays the message (e.g. obj1.specificvar = choice). Problem is, I want to be able to pick up the code and stick it in any game, and use it on any variable in that game. show_message_ext had that universality.
So, the question here is, Is there a way to set a variable specified by obj1's code from obj2 with the same code run by obj2 each time? even if obj1 calls the script multiple times, assigning the script's return value to different vars? (e.g. "var1 = msg_choice(args)" then later in the code "var2 = msg_choice(args)") (run on sentence of the year). If there isn't a way to do that, is there a way to break a script, get the var, and resume the script where left off? Any way this message box is possible would be great, if not, I'll find some other way to get my input. The same concept here goes to text input.
So, the question here is, Is there a way to set a variable specified by obj1's code from obj2 with the same code run by obj2 each time? even if obj1 calls the script multiple times, assigning the script's return value to different vars? (e.g. "var1 = msg_choice(args)" then later in the code "var2 = msg_choice(args)") (run on sentence of the year). If there isn't a way to do that, is there a way to break a script, get the var, and resume the script where left off? Any way this message box is possible would be great, if not, I'll find some other way to get my input. The same concept here goes to text input.