R0J0hound's Forum Posts

  • You could use one of these:

  • http://stackoverflow.com/questions/9403 ... javascript

    Add the browser object and use these expressions to convert over and back.

    Browser.ExecJS("'"& char & "'.charCodeAt(0)")

    Browser.ExecJS("String.fromCharCode("& ascii &")")

  • Instead of building the first text right away store the two numbers in variables and the operator in another variable. Then you can build the first text with number1&operator&number2. Then just add some conditions checking what the operator and set the second text depending on the operator.

    global number number1=0

    global number number2=0

    global text operator=""

    Start of layout

    --- set number1 to round(random(1,100))

    --- set number2 to round(random(1,100))

    --- set operator to choose("+","-","/","*")

    --- set Text1 to number1&operator&number2

    operator = "+"

    --- set text2 to number1+number2

    operator = "-"

    --- set text2 to number1-number2

    ... etc

  • Here's the reverse.

    x = iy-320+ix/2

    y = iy-320-ix/2

  • By platforms do you mean android and ios? My guess there is a tag in the manifest that says if it's a game, app or anything else. That said I'm unfamiliar with the export process, and weather or not you can access it or if the process is fully automated.

  • I agree with Katala's idea of having a top view layout in the back.

    For pathfinding and other motion in iso the simple thing is to do it in top view and then position some isometric objects from the top view positions to isometric positions.

    The math is simple:

    IsoX = x-y

    IsoY = 320+(x+y)/2

    Example:

    https://dl.dropboxusercontent.com/u/542 ... nding.capx

    I left the top view stuff visible but in practice you would make it completely invisible. The advantage of doing it that way is all behaviors can now work as an isometric motion.

    The animation aspect is basically the same as changing animations in 8-direction.

    viewtopic.php?f=147&t=90880&p=713920&hilit=animation#p713920

    To me z-sorting is the hardest aspect of isometric. In the capx I sorted by Y which doesn't sort right in some cases.

  • Yes, that would work.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Glad they helped. I found the topics using the forum search with "comma number".

  • eli0s

    Maybe I've become accustomed to it.

    I did a bare basic js test of motion and even then it's not buttery smooth.

    http://jsfiddle.net/us1v4sq4/1/

    Also added a graph of the frame time to inspect it further

    http://jsfiddle.net/us1v4sq4/2/

    For me there are some little spikes in the frame time, but it doesn't really correlate to the motion.

    Not sure what can be done to improve it. The issue may lie in the web browser itself.

  • Other stuff running in the background have much less of an effect than Garbage collection. Garbage collection is automatic and in javascript you can't control when it happens as far as I know. Ashley has done a lot to keep the amount of garbage made by the engine to a bare minimum according to his blog posts.

    I don't really notice the lag, but then again my pc is dog slow with html5 as it is.

  • Another interesting idea would be to use

    http://en.wikipedia.org/wiki/Dijkstra%27s_algorithm

    The idea is to use an array to store the direction to move for every spot to get to the target with the shortest distance. It's just as easy to have more than one target so it's good for many objects that need to find a path to the same set of targets.

    So after the array is calculated objects can move to the closest target by just referencing the direction of the square it's currently on.

    https://dl.dropboxusercontent.com/u/542 ... eSpot.capx

    In the example I made the objects accelerate toward the direction instead of just setting the direction. The result was nice rounded turning.

    It caused a stall if I calculated the array all at once, so I adjusted it to only calculate a bit at a time.

  • JavaScript's garbage collection (GC) is one cause of stuttering. It's gotten better over time because web browsers are implementing ways so the GC causes shorter stalls. Some are better at this than others.

    Another reason is stuff running in the background, the underlining os can be as much of a culprit as other programs. The nes had a lot less variance since only the current game was running.

  • How is 0-100 limiting? Just convert a 0-255 value to 0-100 with value/255*100.

  • There's an example here:

  • Here are some topics with examples: