How do I combine "And" vs "Or" blocks in an event?

0 favourites
  • 2 posts
From the Asset Store
14 amazing sound files of game events like Level Ups, Level Completes, object spawn, object taking etc.
  • I was trying to do something similar to the following:

    (hitboxPlay.Bullet.speed = 100 & hitboxPlay.Bullet.distanceTravelled = 500)  
    OR
    (hitboxPlayer Platform is on floor & hitboxPlayer.value =200)
    OR
    (hitboxPlayer Is overlapping endPoint & hitboxPlayer Platform is falling )
    [do something]
    [/code:a267fn3o]
    [img="https://drive.google.com/uc?export=download&id=0B8g2b8f9ktNBaWwzZnBIazk5R1U"]
    
    but I can not find any document or tutorial for this. Any way to combine "AND" vs "Or"?
  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • First two conditions on your screenshot can be written as an expression and combined into one condition.

    System ->Compare two values -> (hitboxPlay.Bullet.speed = 100 & hitboxPlay.Bullet.distanceTravelled = 500)  = 1[/code:2265h69r] 
    
    Unfortunately you can't do this with your other two AND blocks. (You probably know all this already)
    So no, this isn't possible. I face the same issues in my game and have to use workarounds like boolean variables or something else.
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)