R0J0hound's Recent Forum Activity

  • [quote:11qmxxg4]Now Construct 2 isn't its own programming language, but instead based off JavaScript.

    I disagree. C2's event system is most certainly it's own language, and isn't really anything like Javascript.

    But this is a fun idea, I went with this one:

    http://rosettacode.org/wiki/Catmull%E2% ... on_surface

    Go big or go home, right?

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

    It took a while to debug it, but it had to be done today. I wouldn't know what I did in a week. <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    It only take obj files with four sided faces, and I didn't look into the hole cases.

  • mindfaQ

    Paster creates the url to download the same way as Canvas. It's very odd if one saves as a png and one as a jpeg.

    You can look at the canvas.imageUrl string and see if it says "image/png" or "image/jpg" in the first dozen characters or so. The filename extension could be wrong. For some reason your friend's computer firefox could be defaulting to jpg instead of png.

    If you look in the runtime.js and search for "canvas.toDataURL()", you can force it to use png to see if that helps by adding 'image/png' as a parameter so it would look like "canvas.toDataURL('image/png')".

  • cheesewhiz999

    You can set the "max speed" to be higher.

    ome6a1717

    Also note that the deceleration will slow the object down.

  • mindfaQ

    According to the html5 specifications the file should be a png by default. jpegs can be saved, but this plugin doesn't ask for a jpeg.

    What browser are they using? Firefox and Chrome saves pngs for me.

  • If you save to old position of the sprite in some variables, you could then use a loop and lerp to create particles in between the positions.

  • I don't really have one. It's just that the rotate behavior is a very light behavior, and since it's only used on one sprite it's hard to believe it's a contributor to bad performance.

    You can't really squeeze any more performance from something so simple.

    My thought is the lag you're encountering has nothing to do with your game.

    But perhaps someone else has tips. I've only ever used the html5 and nw.js exports.

  • Every 0.017 seconds and lower is the same as "every tick". So dt can make sense there.

    All every x seconds does is check the time since it last ran, then if it's >=x it runs.

    The rotate behavior and doing it with events should be identical for performance. Actually the behaviors often should perform better.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Well, all the rotate behavior does is the same as a event like this:

    Every tick: sprite: rotate clockwise speed*dt

    With just one object, there isn't much you can do to make it faster.

    How is the performance bad?

    If you're getting a low framerate then you might have a blacklisted graphics card. If you can update your driver it may help.

    If instead you're getting a rotation that's not buttery smooth, then it's a current browser issue. You can have lots of sprites/events/behaviors or very few and it doesn't affect that. Chrome supposedly has a fix coming in a newer version, but other than that other browsers have varying degrees of stutter. Once one solves it well I'm sure the others will follow suit.

  • Here are the specs:

    https://en.wikipedia.org/wiki/Double-pr ... int_format

    1 bit for sign, 11 bits for exponent, and 52 bits for the fraction.

    With that it's only 15-17 significant decimal digits, but since it also stores an exponent it can store a value up to:

    1.7976931348623157 × 10^308

    which is plenty for a clicker game.

  • Numbers in C2 are 64bit floating point values so it can handle values like that.

    The editor doesn't let you type numbers with scientific notation so maybe that's where the misunderstanding is.

  • It's the same if you created a sprite in a function. If you create another, it will exist till you destroy it. Also an object's uid should never change. I've resized many arrays and their uid remains the same.

  • Maybe this?

    (1-value/180)*100

R0J0hound's avatar

R0J0hound

Member since 15 Jun, 2009

Twitter
R0J0hound has 157 followers

Connect with R0J0hound