Hi all,
I was just wondering if how to have and and and or within the same event. For example.
if button1 && button2 == Down || button3 && button5 == up {
-----------;
}
Thank you so much,
Hayden
Develop games in your browser. Powerful, performant & highly capable.
You can't have a mix of AND+OR with several combined conditions, you probably need to use a boolean variable:
Is button1 up Is button2 up Set b=true else Is button3 up Is button4 up Set b=true If b then .........
But if you are comparing some property that can be accessed in expression, or an instance variable, then you can do it in one line:
if ((Button1.isUp & Button2.isUp) | (Button3.isUp & Button4.isUp))