Razertune's Forum Posts

  • Holy cow! It seems something is constantly spitting out Breathe sprites!

    Thanks for telling me to go debug! I've never used it until now.

  • DogeDev

    That could be a temporal solution, though I've found another fix for now. I edited the event instead to play the sound during the third frame of the Beast Ready Animation. That doesn't seem to cause a problem. Still need that Trigger Once sub-event to not cause looping.

  • [Beast]

    ----+ Beast: On animation "Idle" finished

    -----> Beast: Set animation to "Ready" (play from beginning)

    ----+ Beast: On animation "Ready" finished

    -----> Beast: Set animation to "Idle" (play from beginning)

    ----+ Beast: Animation frame = 3

    ----+ Beast: Is animation "Ready" playing

    --------+ System: For each Beast

    ---------> System: Create object Breathe on layer 5 at (Beast.BBoxRight +5, Beast.BBoxBottom +10)

    ----+ Breathe: On any animation finished

    -----> Breathe: Destroy

    And the creation of Breathe plays the sound growl.

    That's all the other code somehow involved with the playing of the audio file.

  • As mentioned, if I was to ensure only one Breathe sprite exists at one time and also remove the Trigger Once sub-event, the Growl sound loops until the Breathe sprite disappears.

    I'm not sure what I'm doing wrong. Otherwise it's the preview function that messes the sound up, but I wouldn't know.

  • Hi

    This is hopefully a simple issue for someone glimpsing past my post.

    So I have a sound file imported named Growl.

    A sprite named Breathe is continuously created and disappears after its two frames are finished.

    What I've done is this:

    ----+ Breathe: On created

    --------+ System: Trigger once

    ---------> Audio: Play Growl not looping at volume 0 dB (tag "")

    All is nice and dandy. But if another Breathe sprite is created while one already exists, the sound seem to loop until both instances are gone.

    How do I prevent this loop from occuring? The System: Trigger once, only prevents one sound alone from looping.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Another headsup. It seems like the spinning animation issue have solved itself somehow. Not sure how but all is joy now.

  • I want to believe that the random spinning animation has something to do with the bird animation finishes going through its four frames and repeats. Even if I set the birds 8 Direction Set Angle properties to 'No', and apply a 'Set angle to 90 degrees' and '..0 degrees' function on the corresponding Every Tick and Else events, the animation still seem to stop and spin before looping through the frames.

  • Thank you both for the assistance!

    I will keep your advice in mind when comparing cords. Another thing. How do I disable the current simulated movement before replacing it with another direction? Do I just use Stop 8 Direction?

    dop2000 I've decided to use your suggestion. It seems to work out really well. There's only one minor thing with this execution. After the bird changes movement towards right, it moves for about 3 times its tile size before stopping for almost a second and starts spinning the animation violently before proceeding as normal. In the end taking the last turn and simulates moving up. I've set the 8Direction Set Angle to 90 intervals.

  • On start of layout a sprite(bird) is created that has simulated 8 direction movement based on an instance list. From start the bird simulates movement downwards. At the same time another sprite(airspace) is created and is every tick placed beneath the bird sprite. This airspace sprite only serves the purpose of ensuring the bird doesn't reach the solid ground closer than 16 pixels. On collision with solid, the airspace sprite gets destroyed, and on that trigger, the bird sprite simulates moving right instead.

    Now here is my issue.

    I would like this sprite to change the simulated movement upwards when it reaches the X cord of BBoxRight of a third sprite(nest) that's already existing in the level. However I'm not entirely sure how to go about this.. I've tried to experiment with the compare X function, however there's surely something I'm missing in my execution. I guess what I've done is creating an event that compares X cord of bird sprite with BBoxRight x cord of nest sprite, but nothing triggers the bird to simulate movement upwards.

    All chime ins are appreciated.

  • I've managed to solve my problem.

    I kept the "Create object Fire on layer 5 at (Person2.BBoxRight +5, Person2.BBoxBottom +10)".

    The only thing I did was applying a sub-event saying "For each Person2", Create Object Fire.

    I thank all of you that took your time to read my post.

  • Hello

    So I have a sprite (Person2) looping through an animation. During the second from last frame a new object (sprite) is created (Create object Fire on layer 5 at (Person2.BBoxRight +5, Person2.BBoxBottom +10).

    This newly spawned object is destroyed as soon as the animation that triggered the creation is finished.

    My issue is that if I were to "copy and paste" this character multiple times into the level, only one of these Person2's will have this object (Fire) placed/created beside it. I guess that my problem is that every created object (Fire) is simultaneously placed at one of these Person2's. If so, I have no idéa how Construct determines where to position it.

    If I were to let every unique Person2 have a different Initial Frame in their properties, a new Fire object could easily be created beside the creator origin on different ticks (and be individually destroyed too.) However, this could in practice turn a bit tedious. And I would prefer to have every Person2 behave excatly the same during the level, since the timing aspect is essential within the game.

    As the title describes. How would I go about to be able to have multiple Person2's animating on the same tick/second while also creating their own individual Fire beside them?

    Thanks in advance