You know. Gamemaker surprises me sometimes. It supports (simultaneously) the syntax of a bunch of different languages (Think of :=, =, and ==), and yet it can't handle multiple consecutive else statements. That seems especially odd, since it's written in Delphi, which supports multiple elses, so I would assume that Mr. O is at least aware of them, even if he doesn't use them regularly.
Anyway, the point is, I just tried to use multiple elses and it didn't accept them, and I'm sad, because now, what could (and should) have been one line is five lines.PS: I still need a way to fool windows into seeing a network drive as if it were local. Hmm… Actually, I wonder… I might be able to create a SymLink (yes, XP does support them, it just has ne inteface for setting them up) to a network folder and then Subst that as an extra drive. Perhaps it wouldn't be smart enough then to realize that the SymLink isn't local… Wish me luck. ^_^
O_o
if goodpeople=goodpeople2{x=30}else{x=40}else{x=50}The first statement returns false, so it goes to the second else, … the second else never returns false, so then the third else is ueslessso it should beif goodpeople=goodpeople2{x=30}else if goodpeople=goodpeople3{x=40}else{x=50}(Or a switch statement)
you gotta have:
if(something){do something}else if(something else){do something else}else if(another something else){do another something else}else{do another something else different}like that - it's always worked for me; or you could always use switch statements!I BEAT YOU DF!!
Crap.
yeah, like Chiken said.
Why add that to GML when you can simply put an if after an else to make it look like a else if?one word…google
Um, I've used consecutive else statements tons of times. You just have to add 'if', as was mentioned above.
Um, that's not at all what I meant. I understand that it can handle if then else if then else, and so on. I mean the word else <i>immediately</i> follows itself. as in…
<code>if something then if otherthing then x:=5 else else x:=23;</code>…where x should stay the same if something is true, but otherthing is not.you fail at coding