vee41's Recent Forum Activity

  • You can get the angle with expression: angle(player.x, player.y, orbiter.x, orbiter.y). You could spawn a new bullet object at the orbiter object, and set it's angle towards angle(player.x, player.y, orbiter.x, orbiter.y)

  • Here are two approaches you could try:

    a) you could use more sophisticated generation algorithm (google) that would make sure that such path happens.

    b) you could generate your walls randomly, and use something like pathfinding behavior to find out if there is path between two points. If not, you could regenerate whole map, or remove (randomly or semi-randomly) a wall. Repeat the process until path is found.

  • You could put both parameters into single string and use string.find on your comparisons. Like: string.find(src, box1) is not -1 and string.find(src, box2) is not -1, do stuffs.

  • I guess that's what I get for messing with C2 too late at night!

    We`ve all been there :-)

  • You don't have any zone objects in the layout, so referring to zone.width or zone.height returns 0, which causes division by 0.

  • I want this too. EasyTween is pretty much the greatest plugin ever created, making it official should be mandatory :)

  • Right, I forgot about the existence of containers at all, so I started using 'families' instead because I wanted pseudo-container behaviours.

    When I put all the parts of the Deer container together, would I still have to do the On Start Layout event where I spawn and pin all the associated collision boxes?

    Or after making the Deer-container, I just ctrl+drag to duplicate it throughout the layout and it'll be exactly the same?

    You don't even need to spawn the hit boxes, that is done automagically due them being in same container. You only need to do the pinning, which I'd move into 'on deer created' event.

    To summarize:

    Only place instances of deer object in the layout, no hitboxes.

    On deer created event, place hitboxes (to imagepoints of deer object) and pin them.

  • You are not picking any instance of deer family, 'on collision' event picks your hit box, but as no specific instance of deer family is picked, they are all affected.

    I'd do this:

    Get rid of deer family, put all deer animations in to single deer object.

    Place hit boxes in container with the deer.

    Then it should work, as deer would be automatically picked with the hit box, due them being in same container.

  • The randomization event "Pick instance with UID Random(Block.UID)" does not really make any sense. You should use 'pick random instance' event like you did before, and everything else should work.

    If you use "Pick instance with UID" event, you'll need to enter an UID of exiting block to make it work. Right now, you are randoming a number from 0 to whatever UID first picked block has.

  • Thanks R0J0hound that makes sense. How would you assign the random to it? What I have currently now is:

    Block > Pick Instance with UID Random(Block.UID)

    ---- System > Set Target to block.UID

    For some reason though, this still does them all in order. I have tried other parameters to the Pick Instance with UID like Random(0,122), etc... but it does not work. It just sits there and nothing happens. Any better expression to plug into when grabbing the UID to really get a random (but existing) UID from the 100 blocks I Have on the screen?

    Thanks!

    The idea would be to pick a random instance of block, assign it's UID to target variable, and use that to refer to the target block in the future.

    So do something along these lines:

    pick random block

    .. target = block.uid

    pick block by uid target

    .. shoot

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • They move at the same speed on my preview (chrome, r125).

  • Check out easytween plugin too, has lots of easing functions in easy to use form!

vee41's avatar

vee41

Member since 12 Apr, 2012

None one is following vee41 yet!

Trophy Case

  • 12-Year Club
  • Coach One of your tutorials has over 1,000 readers
  • Email Verified

Progress

14/44
How to earn trophies