R0J0hound's Recent Forum Activity

  • The shape of the line is done with the sum of multiple sine waves.

    A single sine wave would look like this:

    y = a*sin(b*time+c*x+d)

    a is the amplitude of the wave

    b is the speed of the wave

    c is the frequency of the wave

    d is just an offset

    The interesting slopes can be done by adding more than one of those waves together as long as they have different values for a,b,c and d.

    So then we have an equation that gives a y position from a x position. That can be used to place the trees, since they just move up and down.

    Getting the angle of the curve at any point just requires some basic calculus. Just take the derivative of the equation above with respect to x and we get:

    slope = a*cos(b*time+c*x+d)*c*pi/180

    Then the angle can be found from the atan of the slope:

    angle = atan(slope)

    Here's an example:

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

    I used iid but I could have just as well used x, also the lines have gaps which could be fixed with better line drawing.

    That pretty much covers what it looks like is done in that video. To have other objects move about on that surface you'll need to do it manually. I make a ski example a while back that probably could be referenced.

  • To eliminate the sprite getting caught you need to lengthen the slope sprites. If you look close as it is now they don't extend far enough so there's corners to catch on.

    An overlaps check could be better than a on collision check. Just keep in mind you could overlap more than one wall. One way to deal with that would be to use the average angle of the wall's bossAngle.

    +------------------------+
    |                        | set sprite angle to 0
    +------------------------+
       local number count=0
       local number sum=0
       +---------------------+
       | sprite overlaps wall| set count to wall.pickedcount
       +---------------------+
          +------------------+
          | for each wall    | add wall.bossangle to sum
          +------------------+
          +------------------+
          |                  | set sprite angle to sum/count
          +------------------+[/code:3kmqslf2]
    
    The first action that set's the angle to 0 may not be necessary, but it might give some more consistency to it.  Probably a better idea than setting the angle of the platform object would be to use a seperate object that you'd position to the other one, and then just change the angle of that.
  • You could use the platform behavior to do it quick.

    every tick:

    --- simulate platform pressing right

    sprite: wall to right

    --- set angle of gravity to self.platform.angleofgravity-90

    you just need to eliminate the corners that it can get caught on.

  • The idea is possible, see here:

    It has a link to a generic guide on how such a game works. No c2 example has been made yet, but it looks somewhat doable. Maybe by having a sprite per scanline or some variation of that.

  • Pretty sure. The mibbit web client seems to work well.

  • Try a different irc client then. One that works is in the search results. A Google search also gives a link in the first page of results.

  • Did you try a search for irc in the forum search? There's one that has been in use for a while.

  • Here's one possible way that could give you ideas.

    It solves the cornering in an exact way by positioning the detectors relative to the object's rounded position as I recall.

  • Giganten

    It's generally better to use forces and torques to change the motion of the objects. Changing the velocities directly won't give very realistic results although you can increase the iterations setting to make it do a better job of keeping up.

  • I can't see the link you posted but to do a mirrored water like surface it's just a matter of positioning the canvas with it's hotspot on the bottom of it. You'd then position it in the layout so the bottom will be where you want the top of the water to be. Then in events you'd:

    1. paste everything you want to reflect to the canvas

    2. set the canvas' height to negative

    The effect would basically look like this:

    +---+
    |   |
    |   |
    +-o-+  ->  +-o-+
               |   |
               |   |
               +---+[/code:25j7xwz9]
  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The nw.js export makes an exe which can work on most versions of windows.

R0J0hound's avatar

R0J0hound

Member since 15 Jun, 2009

Twitter
R0J0hound has 157 followers

Connect with R0J0hound