R0J0hound's Recent Forum Activity

  • Well, have you tried breaking it up into simpler things you can do?

    First you have a game board that's made up with hexagons and you have two different colors of pieces. As you say "simple". You can position the objects in C2's editor.

    Second the players take turns moving one of their pieces on the board. Then if they land next to the opposite player's piece then the color changes.

    That's basically the meat of it. So what can you do?

    Can you come up with a way to move pieces?

    This really depends on how you want to do it. Just look at the game and make a detailed step by step list of what you do and what is done.

    Can you find opponent pieces close to the player's piece?

    You could do it by measuring distance, detector sprites or even the overlapping at offset condition.

    Can you make it turn based?

    Basically just a global that's set to the current player and you make events to limit what pieces can be moved and such.

  • You could try this:

    Don't give the paddle the physics behavior.

    on ball collides with the paddle then

    apply impulse up on the ball

    and

    apply a horizontal impulse depending on where on the paddle was hit.

    Like this

    (ball.x-paddle.x)*k

    where k is a number to adjust the strength of the impulse.

    Then all that's left is to choose numbers that give acceptable results.

  • Here are some topics with a few solutions. Using physics, bullet and even events.

  • Look at the Shadow casting behavior, it was made for that.

  • You can set it up a bit different so it will take exactly 0.3 seconds to transition. Then you also could use qarp() or cubic() for a non-linear transition.

    Here are some ideas:

    ease in:

    qarp(0, 130,130, self.t)

    ease out:

    qarp(0, 0,130, self.t)

    Overshoot and fall back:

    qarp(0, 200,130, self.t)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • It's discussed elsewhere but and expression to get the scale can be ambiguous if the width or height is changed to have a different aspect ratio. Like tall and skinny or short and wide.

    If you're just setting the size with set scale and want to get it later and easy way would be to save the scale you set to a instance variable.

  • It might be enough to just check if the center of the star is in the polygon.

    I made a capx a while ago that did that.

  • From what I've read we might get that in Construct 3. Maybe. But that's a long way's out and as stated by Ashley in the Latest Podcast and elsewhere on the forums C3 is just a vague idea at this stage. All development is dedicated to C2 currently.

  • It causes that error because of how picking works. The correct way to reference newly created sprites is:

    System.CreateByName("Sprite", 1, 500, 200)
    SOL.Sprite[0].SetX(10)[/code:1wskp8k4]
    
    The relevant bit of the error is IndexError which basically means it can't access anything at that index.
    The reason? CC doesn't add the newly created objects to the object list until the next toplevel event.  C2's picking of new objects is much the same.
    
    If you want to go the python route try:
  • corlenbelspar

    Thanks. Here's an updated runtime.js to replace in the paster plugin folder that works with r189.

    https://dl.dropboxusercontent.com/u/542 ... runtime.js

    I'm not going to update the c2addon on the first post until the next stable release since this is a breaking change that will make the plugin not work for any release prior to 189.

    Cheers.

  • Level 5 -> sprite16 -> remove the 'floors' private variable to fix it.

    Edit: You can re-add it and it should work.

    Edit2: For a technical note it would seem the variable index is 0, and it should be 1 to not crash? Craziness.