How do I a game with multiple instances independently?

Get help using Construct 2

Post » Thu Apr 10, 2014 1:20 pm

Im developing a game based of war with gangs, top view based.

The instances are:
* cops: controled by IA. Moves in randomic direction over a map of a caotic street.
* gangster: moves in randomic direction. Shot controled by player.
* Molotov: bomb fired by gangster.
* Pathfire: instance (bullet) with a image of molotov moving.

When the gangster animation with 60 frames reaches #50 frame pin a molotov in the hand of gangster and set a variable to molotv with the same id (variable id) of gangster. The engine controls to loop for last position to #51 position to avoid create multiples molotovs to same gangster.
When clicked first time the gangster stop and turn to mouse position (target).
When clicked the second time spawn a pathfire (bullet) from gangster to hit the cop + destroy the molotv in the hand of ganster

Here is the trouble: When i destroy the molotov instance from a gangster ... all the molotovs in the scene, from other gangsters are destroyd.

I would like to destroy only the molotov in the hand of gangster that fired.

action - gangster clicked > spawn a pathfire to (moouse.x,mouser.y)
| > set animation frame to 1 ans start again
------- = > destroy molotv

Its not working. (Sorry my bad english)
Posts: 6
Reputation: 1,407

Post » Thu Apr 10, 2014 1:56 pm

Try using the pick event, not sure..Pick by evaluate, or pick by comparison, and check if it equals, this way you only pick the correct molotov
Please tag me with @caiorosisca if your post is refering to me :). I don't always follow the topics I answer.
Posts: 272
Reputation: 1,643

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 4 guests