simple problem.

Get help using Construct 2

Post » Fri Mar 29, 2013 9:21 am

bit of a noobie one but it has been a while since i last sued construct and i'm rushed for a deadline (today =/)

right so then game i'm using follows the basics of the tutorial but the tutorial does not tell me how to go to a layout when All the monsters have been killed, i can do it so when 1 monster dies it will go to the "win" layout but i need to make it so it's when all the monsters die, there all the same sprite so i thing that makes things harder


Thanks for reading Bammy :)
B
4
Posts: 19
Reputation: 463

Post » Fri Mar 29, 2013 9:38 am

DO A BAR-
Are talking about the platformer tutorial?
Anyways, you can use the global variables for the system to know when you killed all the monsters. Let's say there are 9 monsters.We'll call the variable "enemies killed".
You can use the "When destroyed" thing to check if the monster is dead. Then, you are going to use this:
System-> Add to global variable
The full event will look like this:
Enemy:When Destroyed-->Add 1 to global variable "enemies killed"
Now, we need to add the event that will jump you to the layout when "enemies killed" is equal to 9. That, of course, is what you can do.
HARMLESS SIGNATURE THAT IS VIEWED BY OTHERS AS OFFENSIVE AND CONTROVERSIAL
B
14
S
3
G
3
Posts: 356
Reputation: 4,362

Post » Fri Mar 29, 2013 10:06 am

it worked thanks a million ! :)
B
4
Posts: 19
Reputation: 463

Post » Fri Mar 29, 2013 10:14 am

Good Luck.
HARMLESS SIGNATURE THAT IS VIEWED BY OTHERS AS OFFENSIVE AND CONTROVERSIAL
B
14
S
3
G
3
Posts: 356
Reputation: 4,362

Post » Fri Mar 29, 2013 11:55 am

Hi B,

For one kind of monster (=same sprite, many instances) you can also add an event that checks for the sprite count = 0, e.g.:

Add Event -> System.Compare Two Values -> Sprite.Count = 0

Cheers,
Greg
B
17
S
3
G
3
Posts: 79
Reputation: 3,698


Return to How do I....?

Who is online

Users browsing this forum: makkancs and 25 guests