megatronx's Forum Posts

  • No link

  • You mean like the platform behavior just with events instead?

    It's basically called parabolic motion, and you could use the bullet behavior with gravity if you wanted.

    Anyways to do it with just events you'd add two instance variables to the sprite : (vx and vy). Those would be the horizontal and vertical velocities. Then the event would be:

    every tick
    -- sprite: add 100*dt to vy
    -- sprite: set position to self.x+self.vy*dt, self.y+self.vy*dt

    I can't really think of a application of lerp or clamp with just that.

    You could clamp the vertical velocity so that it doesn't fall too fast?

    set vy to clamp(vy, -100, 100)

    I may have bungled the order of the parameters though.

    You could limit the y position for some kind of ground too:

    set y to min(self.y, 400)

    Thanks! I will try it out. The game axis are xyz actually, and jump direction and strength can be controlled similar to Mario. I asked about Lerp and Clamp, because I want the longer the fall the faster you'd go and also I'd want to have jump height dependent on how long you press button with a limit. I would do it myself, but it would take me more events than necessary, and someone like you is very good at keeping things simple. :)

  • Hi,

    It's been a while since I've lurked in to construct. I want to make custom jump and fall using event's, but all the help I've got in the past got lost ( removing of pm's and windows failure requiring me to format hdd with copies of examples ). I frankly forgot how to properly use those expressions. So if someone could give me a code to get smooth jump and fall, as well as remind me why it works the way it does, I'd be very thankful.

    R0J0hound I know you know this very well :D

  • Hi,

    3d demo doesn't seam to display anything except for text. Any idea why it might be?

  • QuaziGNRLnose> Development has ceased.

    Why did you stop its development? It looks like amazing plugin.

  • you got to create your own events for movement and collisions and you'll be fine. Although, you will need to create slightly different events for kb and for gamepad.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • It is also an issue in c2. I didn't do tests per say, but I did notice that once I added a family, performance would always start going downhill. Same for animations.

  • I noticed that too - it takes way longer then a while back, but I don't remember when I started noticing this. I thought it was my pc.

  • wow mOOnpunk having the seperate object (in your case shadows) handling the Z-Order is brilliant! Allows much more freedom of animation in the characters!

    Yeah, classic. Also, if its grid based, you don't need any collisions at all, you just check position on the array against other solids on the array

  • As for the movement, it's not too difficult. Basically I use a "Collision" sprite, and on collisison with it I simply set my Global Movement Speed to 0. Because it's a custom movement, it works really well for both players and NPC's.

    Can you move player normally after it collides ? Isn't it easy to break?

  • Some advice from my own experience: Z-order every 2 or 3 ticks and only object that are on screen or within a distance. You wont notice it. You will have to Zorder all first, then set to front limbs and other parts that are suppose to be in front of parent objects. As for the amount of enemies on screen, just don't have to many of them on it, and try not to process them outside of the screen. But keep in mind that you can't do any transformations of pinned objects, so what i do, every second or less, i pin other parts of characters that are off screen, and when they come back on screen i unpin those and other events set them to their place. Loads of messing about really. I wish construct would have some tools to create entities from several objects. Anyway, it's doable. As for pathfinding, you have an option to create game on a grid, and use A*, but even the behavior shouldn't put too much pressure on the performance. You could switch between pathfinding and other movement behavior depending on circumstance.

    But here's what most annoying will be for ya, and that's collisions with solid environment. This is a nightmare right now for isometric games. Using any of available plugins will give you poor results: it will bounce your character or it will move it at nearest angle but at different speeds. So i created my own collision system, a long one, that checks offset. I only did that for player, but will have to figure out how to make it general now. This is the only way I could get normal resoults, making player

    I have also one for the pad, but that one is different. It was even harder to come up with

    And btw, someone generous could turn this in to a plugin, so we finally have something NORMAL for collisions.

    Also, if you want some distopian soundscapes, I'd can write some gritty, grainy tracks.

  • Thanks, but i'd just like to know how to do that condition, cause there is a way right?

  • I'd like to know too, so the random only picks the number once.

  • It wouldn't go in the condition, it would go in the action.

    Something like:

    for each in array

    -> object set opacity to (curx="r"|curx=1)=1 ?100 :0

    Well, ok, but I need it to be a condition, because then I need to add other actions.

  • You have to add For Each condition to your events.