R0J0hound's Recent Forum Activity

  • Looks like they can’t automatically detect what engine was used in a lot of cases. Look at the issues page of their GitHub page and see that construct and mmf have issues for them.

    Edit:

    steamdb.info/tech

  • If you keep track of the z position of the object you may be able to sort with something like this:

    Sprite: set sorting to sprite.y-sprite.z+1000*sprite.z

    Z sort sprite by variable sorting

    That’s what you’d call absolute sorting. By subtracting the z it sorts them as if everything was on the ground. The 1000 gives more weight to the z so it’s drawn above.

    You may need to tweak the equation. I forget is z sorting is low to high or vise versa.

    This method works well when the objects are all the same z height and z position is on one of those levels. I don’t think it works great when transitioning z position.

    Another option is relative sorting.

    Here’s a recent topic with some ideas:

    construct.net/en/forum/construct-3/how-do-i-8/proper-gridless-isometry-161391

  • They try to make it so it’s not possible to reverse the export back to the c3p file.

    But if all you want to do is change some text, you can search in the files and just replace the text there?

  • Eh, my ideas aren’t always the smartest or simplest. There are pros and cons to most solutions.

    Anyways, I’d say dop2000’s idea is the best way to do it. The more mathy solutions look tedious to implement.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Here is my latest example of a parser. Has error checking, and has functions like sin() and min(), but you can add more.

    dropbox.com/s/ogcxmjml4560avl/expression%20parser%20oct2021.capx

  • Which example? I've probably made too many. Depending on the example it's possible to make functions that take more than one parameter. Do you have a full list of features you want it to have? I'm guessing you want all the expressions that construct expressions have?

    numbers: 22, 33, 1.66

    binary operators: +-*/^

    unary operators: -

    parenthesis: ()

    functions: sqrt(x), min(x,y), max(x,y), sin(x),...etc.

    Can even make it have the the conditional operator (?:), but that can be a bit trickier.

    Even though I use old functions it shouldn't be confusing. I tend to follow the pattern of making local variables which i immediately set from function.param(n), which works the same as function parameters. At any rate i tend to not use c3 if i can.

  • You can also write a parser that does it. Basically it pulls out the numbers and operators from the string and solve it.

    This can be preferred over just running it as JavaScript for a few reasons.

    1. If the string is something the player writes they could take advantage and run arbitrary code.

    2. You have more control over how the text is parsed and the error messages if there is a typo.

    Anyways here are a list of various examples of the parsing way of doing it.

    construct.net/en/forum/construct-2/how-do-i-18/possible-convert-string-154631

  • Beveling the corners of the objects or merging together objects in a row would help fix it.

    It seems to be a general issue with physics engines.

  • The Wikipedia articles on them have pseudo code on how they are done. In construct I’d say utilize the json plugin to manage the data structures needed, although they probably could be done with arrays albeit with some tedium.

    There are simpler structures like a uniform grid with a list of the objects in them, as well as binary space partitions that may work well too.

    If your levels has stuff mostly on a grid I’ve had great speed boosts from using and array to store if a grid location has an object or not.

    Guess the gist of all of them is adding/removing objects from the structure, and getting a list of objects overlapping an aabb.

    Event loops and picking kind of slow things down so for the greatest benefit I’d recommend utilizing JavaScript to do it if you can.

    So I’d say best, as in fastest, would be going with JavaScript.

    If utilizing just events, use json.

    But those are just general ideas.

  • I just checked and the link isn’t dead.

  • You could also do it with a local variable, but it’ll still be two events.

    Local number any=0
    Sprite: x=33
    —— set any to 1
    Any=0
    ——do something

    The else one isn’t bad. It lines up pretty good with the logic of picking.

    The main rough spot with the picking system is the top level event picking of newly created objects.

  • It varies. Events are an interpreted language that’s run with JavaScript. There is some overhead, but it’s mostly just chunks of JavaScript.

    You won’t notice the performance difference unless you’re doing some taxing algorithm. And even then it may be something else that’s causing the slowdown.

    Still I once implemented an isometric sorting algorithm in just events. It was cpu bound. Unsatisfied with how many objects it could handle before slowing down I made a plugin that implemented the same algorithm and got it to handle ten times as many.

    But like was said it probably was just some different values used in ghost shooter. That example isn’t cpu bound.