Great game. I know this is a year old but you could
a. make it so the player bounces (it rotates based on the angle that it hits the top)
b. stun the player (like when they get hit by an enemy)
Of course you could always add parentheses for clarity, which in some cases is a good idea, althought most times it’s best to just split the expression into multiple expressions and take advantage of naming variable.
But for simple logic expressions like the one you mentioned, this is just something programmers are expected to just learn early on.
It isn’t ambiguous. Operators have an order of precedence in all programming languages, and they are almost always the same as they all follow mathematical notation’s conventions.
The operators in your example, in order:
[<=
, not
, and
].
That is the order in which those operators will always be evaluated. If you wanted to change thar order, you have to use parentheses. So to make and
evaluate before not
, you need to write it like:
if not (invincible and hp <=0).
EDIT: This reference sheet.
I love this game!! I’d never played any sort of solitaire before and honestly they never seemed appealing at all, but the art made me really curious and the gameplay is quite addictive. I spent a couple of hours last night just figuring it out and now I’m consistently winning about a third of the time.
I love that you made your own rules and deck. Thank you for this.
Hey NvrSkip!
Thank you so much for playing. That’s actually how a Game Over is looking so far in RAADS… I’m very ashamed of it but I didn’t have time to include a Game Over Screen and a restart button, you have to reload the page to play again.
You did really well in your first playthrough though!
I’m glad enjoy it, hope you keep racking up those scores