How do I make a smooth curve?

0 favourites
  • 3 posts
  • Hello everyone. I need to make a node system for a puzzle game. It should looks like a node-based visual scripting in UE4 and work with touch controls. Something like this:

    But how can I make a smooth curve in Constuct 3? I can`t even imagine how to make this wwith default tools.

    Tagged:

  • you need to use many short line segments to draw a bezier curve. As you drag around objects, you need to constantly redraw the line.

    I read through an article about bezier curves several months ago and made a test capx to play around with. There aren't many comments in there explaining what is going on...

    the two most important parts are the function "DrawBezier" (which needs a start point, end point, and two control points), and DrawConnector (which just needs a start and end point, and assumes the control points line up with the start and end points).

    https://www.rieperts.com/games/forum/Bezier_Curves.capx

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • you need to use many short line segments to draw a bezier curve. As you drag around objects, you need to constantly redraw the line.

    I read through an article about bezier curves several months ago and made a test capx to play around with. There aren't many comments in there explaining what is going on...

    the two most important parts are the function "DrawBezier" (which needs a start point, end point, and two control points), and DrawConnector (which just needs a start and end point, and assumes the control points line up with the start and end points).

    https://www.rieperts.com/games/forum/Bezier_Curves.capx

    OK, thanks a lot. Your code was really hard to understand, but you have made a very important thing: you have showed me a posibility of completing this task, so infinite thanks! I have read by myself about bezier Curves and now I have a made better optimized version of making bezier curves using drawing canvas and connected Touch-control to draw them. If anyone need this project, you may access it by the link: https://drive.google.com/open?id=1Hcrxp5gZB07XCQLcAfcjgBa6YlV44bki

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)