frame

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Register

How do I use the spawn and Animation blocks in my game

I'm trying to make a game where enemies infinitely spawn and you keep score of them, But I'm having trouble using the spawn and animation blocks. anyone know how?
Tagged:

Comments

  • edited October 8
    In animation ~
    Inputs are simple start, stop and go to.
    Start: starts the animation
    Stop: stops that animation
    Go to: goes to a specific frame in the animation (does not require start or stop)

    You can make many different animations, what is picked in the block is whats gonna play.
    For the buttons; you have a loop (which runs the animation forever) and a stop on last frame when finished (If loop is not on, the animation will stop on its last frame instead of stopping).
    Priority is given if you play several animations at the same time for some reason with several blocks.What ever is set to a higher number will play over the others (I wouldn't worry about this if I were you).

    Outputs are also simple play and stop
    Play outputs when you start an animation
    Stop outputs when you stop
    (Go to doesn't use an output)

    Note: Using Once ---> start (loop) is probably what your going for on the enemy.

    In Spawn ~
    Inputs are X, Y and Spawn
    X is where the object will spawn on the X axes (In Pixels, not grid)
    Y is where the object will spawn on the Y axes (In Pixels, not grid)
    Spawn simply spawns the object

    Select what object you want to spawn
    You can set the X and Y, but inputting these before you activate spawn also works.
    When Inputting the numbers input the X and Y before spawning.
    Its very important that you know these only spawn in pixels and NOT the grid.

    Output is out
    Out is caused after activating Spawn

    Note: If you want a specific spot, you can find it easier using an extractor on an object for where you want to spawn.
  • Okay, After reading this I understand how to use them both, but How do I connect them to other blocks to get them to work. So when the game starts, they spawn in and the animation triggers?
  • Yes, using Once will trigger every time you spawn (to the spawned object). \|/
    A once won't trigger again after use. They trigger when that Object now exist/spawned.

    They can spawn at any time you want, you just need to trigger it.
    Like if you want to spawn every 5 seconds you could go:
    Once ---> Timer (50 [loop]) ---> Spawn

    Connecting them to other blocks is like a chain reaction. It holds no special value (1) when either block outputs. When inputting, the only one that matters is the X and Y for position. Other than that, all inputs and outputs is just a single simple trigger.
Sign In or Register to comment.

flowlab.io

| make games in your browser
@ 2017 Flowlab.io, All rights reserved.

Contact us

Get In Touch