ramones's Forum Posts

  • Check the collision polygon for the player.

  • It crashes here. You have to click on the bottom left text (the "0") to start the timer before clicking save and load.

    And the error is

    avascript error!

    TypeError: t.current.add is not a function

    http://localhost:50000/Timer_behavior.js, line 80 (col undefined)

  • It seems it's generating the pathfinding grid based on the menu layout so it's only 1280x768. Putting 'regenerate obstacle map' at the start of the game layout gets it working.

  • The quotation marks in the project description were breaking the node-webkit export. I see you got it sorted anyway.

  • This works well for a single player: trollgap2.capx

    It won't really work for multiple trolls moving together which I'm guessing they do based on the name 'trollemmings'.

    Maybe this:trollgap3.capx

    Falling down the gap is a little jumpy when you have scrollto on the troll.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • How about

    <img src="https://dl.dropboxusercontent.com/u/8367729/construct/pics/subevents1.PNG" border="0" />?

  • Cipriux yes dt could never be 10 or 20, I was just using simple numbers for the sake of example.

  • A super simplified example to show why you dash further at lower framerate:

    Say dt = 10 and dash = 30 and you move 100*dt every tick,

    move 100*dt = 1000 px
    dash = 30 - 10 = 20
    move 100*dt = 1000 px
    dash = 20 - 10 = 10
    move 100*dt = 1000 px
    dash = 10 - 10 = 0
    move 100*dt = 1000 px
    dashing = false
    

    total distance: 4000 px

    at half the framerate, dt = 20:

    move 100*dt = 2000 px
    dash = 30 - 20 = 10
    move 100*dt = 2000 px
    dash = 10 - 20 = -10
    move 100*dt = 2000 px
    dashing = false
    

    total distance: 6000 px

    -------------

    In your capx (if I've calculated it right):

    at 60 fps you move 1250*1/60 = 20.83px per tick

    22 times

    total distance: 458px

    at 30 fps you move 1250*1/30 = 41.67px per tick

    12 times

    total distance: 500px

    -------------

    So you want to move a fixed distance, say 450px. At the start of the dash set dashDistance = 450. Every tick, move 1250*dt OR dashDistance, whichever is smaller and then subtract the distance moved from dashDistance. So you'll be moving 1250*dt until the last tick and the you just move the remaining distance to make it 450 and don't overshoot.

    if dashing == true
        if dashDistance < 1250*dt
            move forward dashDistance
            set dashing = false
        else
            move forward 1250*dt
            subtract 1250*dt from dashDistance
    
  • You might need something like

    Windows["System"]["UserProfile"][GlobalizationPreferences"]["languages"]

    See this thread:

    http://www.scirra.com/forum/plugin-developers-please-test-with-the-minifier_topic45502_page1.html

  • You're destroying the array at start of layout so there's no array to download.

  • There's a link at the bottom of this page.

  • Yep "for each (ordered)" that is.

  • You could create a grid of invisible solid sprites over the water and when the player puts down a bridge tile you destroy the solid tile under it.

  • Action is a number.

    AvailableActions is text (e.g. "1,2,3,4").

    Set Action to

    int(tokenat(AvailableActions, floor(random(tokencount(AvailableActions, ","))), ","))

    example (r141)

    Explanation:

    int(tokenat(AvailableActions, floor(random(<font color="red">tokencount(AvailableActions, ",")</font>)), ","))

    tells you how many values there are in AvailableActions separated by a comma (in this case <font color="blue">4</font>)

    int(tokenat(AvailableActions, <font color="red">floor(random(<font color="blue">4</font>))</font>, ","))

    give you a random number from 0 to 3 (e.g. <font color="blue">0</font>)

    int(<font color="red">tokenat(AvailableActions, <font color="blue">0</font>, ",")</font>)

    gives you the value in AvailableActions at position 0 (i.e. <font color="blue">"1"</font>)

    <font color="red">int(<font color="blue">"1"</font>)</font>

    converts the text into a number, int("1") = 1

  • What C2 version are you using? I think that error message is a bug that was fixed months ago.