Rules in rules, with collisions?

DrGlickertDrGlickert Member Posts: 1,135
edited November -1 in Working with GS (Mac)
I honestly don't know if the title has anything to do with my question, but here it goes.

I have 3 balls and 1 block actor.

I want the balls to have a different effect on the block actor when it collides with a ball. I'm struggling to find the best way to efficiently do various behaviors with slight variations based on what ball hits the block.

SO... my question is; does this work?

---
RULE: When Block overlaps with actor TAG Balls:
Do behaviors (award points, etc).
Within this rule: When Block Overlaps with actor TYPE: Ball1
Do behaviors of ball 1,
within top rule: when Block Overlaps with actor TYPE: Ball2
Do behaviors of ball 2,
within top rule: when Block Overlaps with actor TYPE: Ball3
Do behaviors of ball 3,
----

OR, do I have to create 3 separate rules for each ball type?

----
Rule 1: Block overlaps/collides with ball1:
Do ball 1 behaviors
Rule 2: Block overlaps/collides with ball2:
Do ball 2 behaviors
Rule 3: Block overlaps/collides with ball3:
Do ball 3 behaviors
----
Each rule will have some similarities and some slight variations. I'm just trying to keep things organized. Does this make sense?

Comments

  • DrGlickertDrGlickert Member Posts: 1,135
    Nevermind. I just wiped up a prototype and it works like a charm. I think I spend more time asking my questions then I do just prototyping things.

    I'll learn one day.
Sign In or Register to comment.