Advanced Solids

Get help using Construct 2

Post » Wed Jan 29, 2014 6:15 am

How do I make the solid have collision on me, but not on the enemy? This is because I need the enemy to see me through the solid as I am in an enclosed space (pathfind can't find me, but I need him to attack the wall).
Check out my games on Google Play:
BEAST ATTACK (1,000,000+ downloads!)
ZOMBIE BASH (Android) (Launched Feb 17)
ZOMBIE BASH (iOS) (Launched March 17)
B
56
S
18
G
2
Posts: 440
Reputation: 5,640

Post » Wed Jan 29, 2014 7:29 am

Not sure that "solids" is the way to go, is it too simple just to set the enemy bullets to "angle towards position" where position is Target.X and Target.Y (and you are "Target")? I've used this before and it doesn't matter where you are and what's in between, those bullets come straight at you, maybe add a little randomiser such as Target.X+round(random(-16,16)), Target.Y+round(random(-16,16)), to give you a sporting chance?
There are 10 types of people in the World, those that understand binary and those who don't.
B
7
S
2
Posts: 93
Reputation: 797

Post » Wed Jan 29, 2014 8:06 am

Except I still need the enemy to walk around trees, rocks, and other enemies. If I do it the bullet way as you say, the enemy will just walk straight towards me and get stuck somewhere or walk right through it.
Check out my games on Google Play:
BEAST ATTACK (1,000,000+ downloads!)
ZOMBIE BASH (Android) (Launched Feb 17)
ZOMBIE BASH (iOS) (Launched March 17)
B
56
S
18
G
2
Posts: 440
Reputation: 5,640

Post » Wed Jan 29, 2014 8:16 am

Could you disable the solid while finding the path and re-enable it on path found?

Then make an event if the distance to the walls is close enough to start attacking the walls?
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Wed Jan 29, 2014 6:59 pm

On collision with objectX disable Solid on objectY? something like that...
B
49
S
12
G
10
Posts: 1,833
Reputation: 14,583

Post » Fri Jan 31, 2014 2:43 am

@LittleStain: If I disable solid, then I can walk through it. I don't want that.

@BluePhaze: Not sure what you mean :)
Check out my games on Google Play:
BEAST ATTACK (1,000,000+ downloads!)
ZOMBIE BASH (Android) (Launched Feb 17)
ZOMBIE BASH (iOS) (Launched March 17)
B
56
S
18
G
2
Posts: 440
Reputation: 5,640

Post » Fri Jan 31, 2014 5:40 am

You have a solid behavior on both objects, disable it on one of them when the objects collide or even better when overlapping so that they can pass through each other...
B
49
S
12
G
10
Posts: 1,833
Reputation: 14,583


Return to How do I....?

Who is online

Users browsing this forum: mageekm and 26 guests