animation bug?

Get help using Construct 2

Post » Fri Sep 15, 2017 10:02 am

Message: OBLIVION can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?
okay so for some reason my animation upon death isnt working. however the exact same script works for the enemy. so why not my player. here is a screenshot

https://ibb.co/cdNkb5
B
7
S
2
Posts: 105
Reputation: 889

Post » Fri Sep 15, 2017 10:25 am

So what's happening?
Does your Explosion object move to player's position, but not switching to "explode" animation? Or does it get destroyed with the player?
You can test this - run your project in debug mode (Ctrl-F4), select Explosion object on the left panel, then allow your player to die. See what happens with the Explosion sprite.
Image

Did I help to fix a problem in your game? You can buy me a cup of coffee :)
B
17
S
9
G
72
Posts: 1,095
Reputation: 39,253

Post » Fri Sep 15, 2017 4:51 pm

it says the animation is playing but only see a box nothing else.
B
7
S
2
Posts: 105
Reputation: 889

Post » Fri Sep 15, 2017 5:12 pm

Can you post the capx ?

Maybe there's a problem with the "health = 0", with your player's health going into the negatives, thus preventing the animation to start.

But without a capx, and with such a small screenshot it's hard to tell.
B
6
Posts: 38
Reputation: 337

Post » Sat Sep 16, 2017 3:21 am

@OBLIVION
If the Explosion object is not destroyed and is moved to the correct position, then it's either invisible, or transparent (opacity=0), or behind some other object, or animation is stopped on an empty frame. You should be able to check all these things in Debug mode.
Are you using any effects or blend mode on your explosion? If yes, then remove them for testing.
Image

Did I help to fix a problem in your game? You can buy me a cup of coffee :)
B
17
S
9
G
72
Posts: 1,095
Reputation: 39,253

Post » Sat Sep 16, 2017 8:08 am

Message: OBLIVION can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?
thanks guys. here is the capx file. really not sure whats happening here.

https://drive.google.com/file/d/0B_wGto ... sp=sharing
B
7
S
2
Posts: 105
Reputation: 889

Post » Sat Sep 16, 2017 8:10 am

Message: OBLIVION can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?
https://drive.google.com/file/d/0B_wGtoNKF4qgVDZlbzEzTTZsbms/view?usp=sharing
B
7
S
2
Posts: 105
Reputation: 889

Post » Sat Sep 16, 2017 8:23 am

okay so i think the issue is where the player is destroyed at the end then all objects go with it. so the question is how do i assign the object to the player but then still keep it on the layer upon death (tried global)
B
7
S
2
Posts: 105
Reputation: 889

Post » Sat Sep 16, 2017 8:25 am

when the player dies it just moves the object to the top left of the layer as if my player was their. need to somehow anchor it to the position before death
B
7
S
2
Posts: 105
Reputation: 889

Post » Sat Sep 16, 2017 11:01 am

You need to save your project as a single file (.capx) and share this capx file. Not the .caproj file.

Did you add Player and Explosion to the same container? Don't do it. If you destroy one object, all other objects in this container also get destroyed.
Image

Did I help to fix a problem in your game? You can buy me a cup of coffee :)
B
17
S
9
G
72
Posts: 1,095
Reputation: 39,253

Next

Return to How do I....?

Who is online

Users browsing this forum: acousticputty, Google [Bot] and 32 guests