Windwalker's Recent Forum Activity

  • ROFLMAO:)

  • KaMiZoTo Awesomeness! :)

  • statelessrich What is the inital setting on flag? Try changing it. Because I made the exact sample and it works :)

  • Your ground object is a bullet, and your player object is on top of it. Your ground object is moving to left with X speed and your player object is moving to right in X speed, so it feels like player is stationary.

    But when your ground object reaches it's limit, you take it, and put it to the end (right) of itself. When you do this, if your player is touching the ground, it also takes the player to further right, along with itself. I don't even have dropboxaccount so it will be hard for me to send you back the capx. But as far as I know, there is a "wrap" behaviour you can use for the same effect. Suggest you take a look at it.

  • detno29, as long as your enemy is not upside down, this should work :D But what works is what works, show us your game sometime :)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • A fake, invisible grid... Grid is registered and updated on an array. Each enemy is registered in one of the grid squares, always updated. When enemy is pushed, do the magic math on the array to "move" their places in the array, and update the positions accordingly.

    Just on the top of my head. There may visually be problems, like enemies pushing eachther even though they are not touching eachother... Or different sizes of enemies may cause problems... But maybe this will give ideas?

    Sorry if it was too vauge. Not good with changing ideas into language.

  • Hello flipbox,

    I just noticed it does not go missing. It just jumps to further right, out of screen. Will check code to see why.

    Edit:

    I think I know what happens. When you replace the ground with the new ground that should follow it, if the player is touching the ground, he also jumps to front with it. So it means platform behaviour moves the player along with the platform. Observe that if you jump, player does not move along with the platform. To solve, I suggest making two platforms in the same manner, and never move the platform that the player is standing to front. Instead, move the platform that has passed under the player to front. I hope I could describe it :)

    Regards.

  • I am still fresh in C2, but maybe... You create a body sprite (a blue rectangle for example) and a head sprite (red and smaller rectangle). Position red rectangle on top of blue rectangle... Give pin behaviour to head, and on start of layout, pin the head to body (position and angle perhaps.) Then you can check the collision seperately for the body and head.

    If you have animations for this character, you can also create them and pin them to blue rectangle too. And then make the rectangles invisible.

    I am sure there are better solutions but... Maybe this helps of gives new ideas.

  • Maybe you can replace the object that is being dragged with another object that carries the same sprite while being dragged, and switch back to phsycis object as soon as it is dropped?

  • Hello stateless,

    Out of curiosity, I recreated the whole design myself and run some tests. Result is: A solid object cannot use Line of sight mechanic efficiently. Perhaps it's "eye" is in the center, and thus it's preventing itself from seeing anything. So when I removed solid behaviour from char2, the example worked.

    Nice catch :)

  • Ok Sethmaster, lets imagine your enemies move in random directions, but you want the distance they travelled to be limited. (I don't want to use a function) In that case, on the top of my head, we can do something like

    find path to (enemy.X + random (-100,100), enemy.Y+ random (-100,100)

    This way they can only go to a maximum of 141 distance. Basically, an imaginary square over the enemies. Maybe this helps or helps you get a new idea?

  • make a global (or local) variable first, lets call it "whichspawn"

    Condition:

    system - every 2 seconds

    action

    whichspawn = int(random (1,5))

    system/

    create object yourobject at location whichspawn.X, whichspawn.Y

    something along these lines. I hope I could help.

    Regards;

    -Wind.

Windwalker's avatar

Windwalker

Member since 2 Apr, 2013

None one is following Windwalker yet!

Trophy Case

  • 11-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Email Verified

Progress

13/44
How to earn trophies