News:

MFG's Character of the Month: October 2026 Nominations

Main Menu

help using ||

Started by Odb718, March 04, 2013, 02:00:08 AM

Previous topic - Next topic

Odb718

I'm getting an error trying to use
[State 1525, HitUs]
type=hitdef
trigger1=time =1
trigger1= root,stateno = [0,29] || root,stateno = [1550, 1559]

the "|| root,stateno..." is the problem. The error doesnt specify it as the error, but it is. How can I get this to work. I'd like to avoid making a second hitdef because I'd have to have 4.
How can I make the OR happen?
vVv Gouken718 vVv SabreTooth718 vVv


Алексей

Wrap parenthesis around both statements. Like so:
(root,stateno = [0,29]) || (root,stateno = [1550, 1559])

There is a bug with bracket syntax ranges in mugen. Please note that this can happen with any operator, so just keep in the back of your mind that you have to wrap bracket ranges with parenthesis.

Additionally, you can make sure that you end your conditional statements with your bracket range blocks. This would mean that only one bracket range block could be used per line. I suggest the first solution though. It's simpler and works every time :)

-[Все слова это только слова.]-

Odb718

Thank you. Would have given up if you didnt tell me about that bug.
vVv Gouken718 vVv SabreTooth718 vVv


Алексей

No problem. I had this same issue and it drove me crazy until I figured it out. :D

-[Все слова это только слова.]-