99Instances2Go's Forum Posts

  • If you need differend objects, then you best have accces to familys. Looping trough families is the same as looping truough instances ...

    Condition:

    Pick a group of objects.

    Pick the array

    Action

    Array > set size > width = object.count - 1, Height = amount of variables you need to store

    Z must be at least 1 .. Zero will make an unusable array

    Condition:

    System > For > name = "index", start = 0, end = object.count - 1 (because it is zero based)

    Now the loopcounter is the expression loopindex("index"), we use that as IID of an object and as X index in the array.

    You need Y indexes for the variables.

    So

    Sub condition

    System > Pick nth instance > object = object, instance = loopindex("index")

    Actions

    Array > set at XY > X = loopindex("index") , Y =0, value = Object.X

    Array > set at XY > X = loopindex("index") , Y =1, value = Object.Y

  • I would make 2 animations.

    Animation 1 = ship that breaks up towards complete transparantion. Lets say, if the nose breaks off, this animation has on that place nothing.

    Animation 2 = all the parts. Animation speed set to zero.

    When the ship gets destroyd. You start animation 1.

    When animation 1 is at frame 0, spawn the sprite with animation 2. Set its frame to the first part. Move it in a direction that you want to.

    When animation 1 is at frame 1, spawn the sprite with animation 2. Set its frame to the second part ..

    And so on.

    Destroy object with first animation on animation end.

    Destroy the spawn parts with a timer behaviour.

    Ofcourse you will have to us 'once while true' with the frame comparing.

  • Dope vectors ?

    Just store an index on the X axis. (index of random positions)

    The X position on Y axis = 0

    The Y position on Y axis = 1

  • I think Paster is your solution.

    A plugin by R0J0hound

  • Why not shift the guns origin on the X-as ?

    Then you can spawn the gun on the players position.

    You can pin it.

    Or set it to that position every tick.

    Mirror it when you mirror the player.

  • Well, yeah, actualy that is a foolish wish. (excuse the word). You have to stay in the context.

    You move the objects with physics, then you got to change its motions with physics. Stopping it = changing its motion.

    Any other way will break the physics world.

    Because the physics world depends on tweening little changes that happen in little steps over time. Every action has a reaction. Nothing, absolutly nothing can change position in zero time, that would be magic and break the physics world.

    If you change things in zero time. You are in the quantum world. (or in some Fairy World) With totaly differend rules. As you know, both worlds are not compatible (yet).

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Ah yes.

    You can also use an animation to present frames as stills.

    Just set the speed of the animation to zero.

    Now you can use sprite > action > Set frame

    Notice that everywhere there is an index (a frame"s number = an index) it is ZERO BASED.

  • The link does not work.

    Question: is it realy needed to have differend objects ? You can not do it with instances of the same object ?

    If you need differend objects, then you best have accces to familys. Looping trough families is the same as looping truough instances ...

    Condition:

    Pick a group of objects.

    Pick the array

    Action

    Array > set size > width = object.count - 1, Height = amount of variables you need to store

    Z must be at least 1 .. Zero will make an unusable array

    Condition:

    System > For > name = "index", start = 0, end = object.count - 1 (because it is zero based)

    Now the loopcounter is the expression loopindex("index"), we use that as IID of an object and as X index in the array.

    You need Y indexes for the variables.

    So

    Sub condition

    System > Pick nth instance > object = object, instance = loopindex("index")

    Actions

    Array > set at XY > X = loopindex("index") , Y =0, value = Object.instancevariable1

    Array > set at XY > X = loopindex("index") , Y =1, value = Object.instancevariable2

    Array > set at XY > X = loopindex("index") , Y =2, value = Object.X

    Array > set at XY > X = loopindex("index") , Y =3, value = Object.UID

  • Dont use the wrap ? Use two inmovable physics objects to mark the bondarys?

  • Oh, and you might need two instance variables, if not for this level, i think certainly for the next levels.

    Instead of only Pushed, PushedByBox & PushedByPLayer. Might as wel calculate that in now.

  • Renember that is a dirty trick.

    (**whispers** dont tell anyone that timescaling and platform are not the best friends, because that is gossip)