Ruskul's Recent Forum Activity

  • Hey, Is this still the case? I was looking in the "scroll to" behavior and found found that it uses tick2 and not posttick? Am I missing something?

  • mattb - I'm downloading this, looks cool. As stated I probably can't use it in the current project but Maybe the next one I can use it.

  • I am curious, why did you decide to use chipmunk? Was there a defining feature that made it more feasible to add to construct2 than box2d?

    I have been looking through chipmunk and comparing box2d to it. I like all the work you have done, but it seems that some of the features (such as this frame jointing and position setting ) are more a product of how the behavior is written than the physics engine. Is this correct?

  • mattb - Thanks for letting me know about this. I hesitate to switch behaviors at this point in the project I am working on, simply because the switch could be painful. I know all the quirks of box2d at this point (so I say) so I feel it would be better to stay with it. R0j0 is awesome with all his help and knowledge when it comes to physics and math and such.

    Do you know if you can write pre collision events?

  • R0J0hound - as always, helpful as ever. I appreciate the help you have given me and others.

    dax - I got your pm, and I am glad my post was of use to you. I think R0j0Hound has it covered here though. I struggle with math as soon as it gets more complicated than hello world stuff- I get along simply because I get obsessed over it and spend 8 hours trying to figure out why stuff like x = l*sin(a) works.

  • Colludium how do I get c2 to use this older node webkit?

  • Has there been any progress on this in the last month??

    I thought I was going crazy. I have been working on a few big projects and then a while back I started getting jerking. I have been running circles trying to figure out whats wrong... when I started making smaller, very simple games (like here is a red square, move it around the screen with 8 direction behavior) I still get jerks every few seconds. Its just like the op described. Smooth, smooth, jerky, jerk, smooth...etc. The debugger still reports 60 fps at all times!

    It has been a debug nightmare (except I did find a few bugs in my game that caused 1 frame lags, but nothing serious).

  • Wow, Thanks for the reply ASHLEY. Unfortunately, given the nature of your question, this must be a long reply, but I will be as brief as I can. I understand fully the limitations on a small developer team and construct 2 is an exceptional product and I am very happy with it. Just saying ! Thank you for you hard work.

    (TLDR - the platformer behavior is perfect, for a conventional classically implemented platformer. But... my system is better for what I "need"

    Firstly, I understand platforming code can be a bit of a hassle to make. There are so many things to consider and some of the fringe cases can produce glitches that are hard to test for. On the other hand I have already rolled my own collision detection and resolution system a few years ago in XNA – So I do know what I am getting into. I moved to construct 2 due to dev speed and efficiency reasons and occasionally use Unity3d as well.

    In the last year I have been working to force box2d into a flexible platformer system, with variable gravity directions and Jump throughs (funny you should mention those) in addition to a custom particle system that allows 10,000 physics based particles to be present in a layout. I have also tied in my own character state management system (keeping track of arriving, leaving, and being currently on ground, walls, ceiling, and other objects, relative movement directions, and collision states) in addition to managing different projection variables. I have a custom input object that can be tied to character controllers or AI.

    The reason I chose physics over platformer: 1.) Because it is awesome, and I don't think I have ever seen a "TIGHT" 2d platformer that is fully physics enabled. Basically, my game is a platformer with physics... not a physics platformer, if you understand the nuance I am getting at (imagine mario or meatboy or even sonic but with physics). This makes things like bouncing, moving platforms, explosions, elevators, and more, feel very different than in traditional platformers in a very good way. 2.) Because so many small minded people said it was impossible. As it stands I can emulate the original mario perfectly. In box2d. with physics. Small minds = blown. Objective achieved

    Basically, things are going great... I am making a game around this system and I am supposed to be at beta/media ready stage in march... but, as is the norm, I just ran into a large problem in physics (If i want arbitrary changing gravity and slopes in the game)...

    In any frame that I change a friction coefficient to a non 0 number that is different from what it was, then the next frame (when the change is actually applied) the velocity of an object is not added to its position (this occurs in vanilla box2d bundled with construct) This lag in a frame is very noticeable. I cannot abide it.

    Given the way I handle character movement, I need to change friction of characters on a constant basis. Otherwise they interact quite funny when hitting walls and ceilings, but I can't change a wall or ceilings friction because gravity can be different for different things (meaning a ceiling isn't just a ceiling, it is a floor too).

    If I use no friction and handle it myself in context, I need to apply velocity changes based on surface normals. I can create a system in which I know the objects relative gravity, and I know the objects slope based on its family and can work out the normal from there, however this is tedious and it can only allow me to have set angle slopes. It also means I have to make my world with trigger objects that serve to mark slopes. This is also a more inefficient method but necessary because all slopes have to be part of a larger object that has no internal seams (because we can't use chain shapes in construct 2 with box2d)

    Being able to simply pull a surface normal from contact information in box2d would be great. Or, if construct 2 has surface normal information... otherwise I have to develop hacks to get at it.

    I would use platformer except for lack of control in a few key aspects. Firstly, when traveling on slopes, the object does not store the change in vertical movement as a new dy. Thus if you exit a slope into thin air, the object's perceived y velocity = 0 instantly and seems to "pop" from the slope. I understand what is going on here. I know why it does this (I just read through the behavior). Using surface normals, would be a better way of handling this. From a surface normal you could calculate things like friction and restitution. I want my character to slide meaningfully. I also need the character to base its control on the steepness of the slope. Right now in the platformer behavior, the dx remains the same even when running up a steep slope. (again this makes sense for how it is programmed and is a good classic platformer implementation)... but thats not what I want. Also, The platformer behavior in its general usefulness lacks a few features that are not generally useful but are in certain situations (things like collision forgiveness and collision assumptions based on player intent). Mario 3 has this going for it in spades. The collisions are resolved in respect to what a player would most likely want given input and collision context. Further, the jump through behavior works great but not at weird angles and not with gravity switching... If you stand on a steep edge that cant be climbed but is jump through, if you move in the direction of said platform, you go into it.

    Suffice it to say... If I can pull surface normals, then I can fix my system quite easily. I could conceivably make my own system handle physics (I have made a classic platformer behavior using custom movement from within construct 2 events).

    If I can't pull surface normal then I need to probably edit box2d behavior and expose that, as that is probably by best bet at this point in time). I have been holding off on including my edits in my project in hopes that by the time I released they would be officially exposed. I don't want to include some edits, then see a release that includes those edits plus more... due to the whole "behavior/same id / too hard to substitute similar behaviors in a giant project".

    The only thing that has kept me from simply hard coding my own behavior is that it would kinda eliminate the reasons why I use construct 2 over unity. If I have to do that, unity is better situated for that type of dev process (especially given that I more comfortable in c#).

    Does this all make sense?

  • Hello,

    Does anyone know of a way for looking at the collision results from collision polygons from within construct 2?

    I want to roll my own platformer code, but I need to know if I am on an arbitrary angled slope.

  • Hello,

    I was wondering if anyone knows if this is a construct 2 thing or a box2d thing - I looked through box2d manual and couldn't find an answer.

    If you change the friction coefficient object, the physics behavior will not apply velocity changes to an object during the next frame. In other words, if you change friction every tick, a physics object will not move!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • R0J0hound - Thats neat, I'm to far into a project to switch right now but that's really cool.

  • spongehammer - I agree, more features is way more important than more objects on screen.

Ruskul's avatar

Ruskul

Member since 23 Nov, 2013

Twitter
Ruskul has 2 followers

Trophy Case

  • 10-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • x6
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

17/44
How to earn trophies