2 sprites of same family collide smaller one destroyed

Get help using Construct 2

Post » Fri Oct 07, 2016 8:06 pm

Okay, I've searched around and am really struggling with this game. I am making a game where you are a caveman and you can ride a smaller dinosaur. The dinosaur can eat eggs to get bigger, then can eat other dinosaurs if it's bigger than them.

I want the other dinosaur drones to be able to eat each other too. How can I have 2 dinosaurs of the same family collide, then the smaller one gets eaten, and the bigger one gets a little bigger? Is this possible, or do I need to do it all individually and write a eating script for each individual dinosaur?

Thanks for any help you can give.
B
16
S
9
G
4
Posts: 20
Reputation: 3,564

Post » Fri Oct 07, 2016 8:32 pm

Which part are you struggling on?

I'm not 100% sure of details about objects/families colliding with one of their own but have seen several tutorials/threads on it.... here is one

Once you get the 'picking' sorted out it should be straightforward, right?
ImageImageImage
B
39
S
22
G
11
Posts: 492
Reputation: 9,925

Post » Fri Oct 07, 2016 8:43 pm

Give them family instance variables where 1 is small, 2 is bigger, 3 is biggest or something. When they collide compare the variables, whichever is bigger destroys the other one.
B
46
S
16
G
74
Posts: 2,089
Reputation: 44,187


Return to How do I....?

Who is online

Users browsing this forum: Cub3D, David181, yiuyiu6666 and 25 guests