How do I do a death drop

Just started using Construct 2? Post your questions here

Post » Sat Nov 14, 2015 9:49 pm

After death i need to make drop, but i have same sprites on level and Construct just say you need to make instance of the object.
B
5
Posts: 10
Reputation: 249

Post » Sat Nov 14, 2015 10:35 pm

Image
Maybe it's will be help
B
5
Posts: 10
Reputation: 249

Post » Sun Nov 15, 2015 6:52 am

How is the death being handled (are you initiating an animation or are you destroying the object or...)? I assume you're dropping items to be used?

With as much info as is available my first idea is:
-object health less or = 0 :
--object -> spawn item at object.x object.y,
--object -> destroy object.

If you want multiple kinds of drops then you may want to randomly generate a number (say between 1-100) and then setup something to check ranges of numbers that would allow for certain specific drops.
B
69
S
40
G
24
Posts: 356
Reputation: 18,314

Post » Sun Nov 15, 2015 10:48 am

It's not working
Image
Event Sheet
Image
B
5
Posts: 10
Reputation: 249

Post » Sun Nov 15, 2015 12:18 pm

Read the error message? You need to have at least 1 instance of the drop in a layout for construct 2 to know what it should be like.
B
17
S
6
G
1
Posts: 41
Reputation: 1,725

Post » Sun Nov 15, 2015 1:11 pm

Maukka wrote:Read the error message? You need to have at least 1 instance of the drop in a layout for construct 2 to know what it should be like.

I want a, when i click on CanDo, Money substract -5, Tower1 spawn on CanDo.X CanDo.Y, CanDo destroy, but i have same CanDo and i don't know how instanse show the object, i mean i don't understand how i can do this
B
5
Posts: 10
Reputation: 249

Post » Sun Nov 15, 2015 1:20 pm

You need to place the Tower1 object somewhere, it's fine if it's outside the play area as long as it's somewhere where you can change the size of it and set instance variables and so on.

Instance basically means a copy of a object so if you have 2 tower1s one will be instance 1 and other instance 2
B
17
S
6
G
1
Posts: 41
Reputation: 1,725

Post » Sun Nov 15, 2015 1:41 pm

Maukka wrote:You need to place the Tower1 object somewhere, it's fine if it's outside the play area as long as it's somewhere where you can change the size of it and set instance variables and so on.

Instance basically means a copy of a object so if you have 2 tower1s one will be instance 1 and other instance 2

Can you build example? i mean project in construct 2
B
5
Posts: 10
Reputation: 249

Post » Sun Nov 15, 2015 2:04 pm

Making an example would overcomplicate it - you just have to place your sprite on the layout
B
62
S
23
G
10
Posts: 647
Reputation: 10,578

Post » Sun Nov 15, 2015 2:22 pm

@stargame25

If you don't understand, post a link to your .capx and we'll fix it for you.
If your vision so exceeds your ability, then look to something closer.
Moderator
B
136
S
31
G
86
Posts: 5,490
Reputation: 59,766

Next

Return to Beginner's Questions

Who is online

Users browsing this forum: kainrazial and 3 guests