You mean the muzzle flash? You need to tell Construct 2 to spawn a different sprite (the muzzle flash) from the a point on the tip of the gun. If you check the tutorials you will find very useful tips on how to do this and many-many more useful stuff. Also, have a look at the ghost shooter example. It does exactly that.
Here is the link for the Ghost Shooter tutorial, it is very helpful and, among other things, it tackles this subject.
https://www.scirra.com/tutorials/37/beginners-guide-to-construct-2
Try not to use the "On X button released". Instead use the "8direction is moving" and the inversion of it to change from "Walk" to "Look" animations. Use an instance variable to set the direction that the player is facing.
See the updated capx.
You may want to check my graduate project, it's not a game but more than an interactive, visual narration in the form of a platformer.
See a short trailer here:
And the relative topic here: https://www.scirra.com/forum/memories_t103976
Can you share your capx? Or a simplified version of it..?
Develop games in your browser. Powerful, performant & highly capable.
I used the same 2 frames just for convenience. You will not use frames but animations after all. My point was to eliminate the animation change when moving diagonally.
I am re-attaching the file with some changes, the logic is exactly the same.
Just unzip the capx file and you'll get the project structure
I haven't look the Zelda game, but I think that you want something similar to this, and, if not, you can figure out the logic and work it out.
You can use the Pin Behavior. See the attached example (use latest beta of C2, v169 or higher).
Can you rephrase your question? I can't understand what you're asking. Perhaps show us some sketches (attach some pictures) of the game mechanic that you are trying to create?
You're welcome!
Latest beta v169
https://www.scirra.com/construct2/releases
Hmmm, I must have a split personality, but you are welcome
Member since 24 Apr, 2013