Hi all,
I was wondering how to make a line graph. For example, graphing y = sin(x). I also want to be able to remove the grid if possible and turn the graph into an object that can be moved around.
Thanks!
Hi all,
I was wondering how to make a line graph. For example, graphing y = sin(x). I also want to be able to remove the grid if possible and turn the graph into an object that can be moved around.
Thanks!
Explore Edge Shape or “Chain” Bodies
https://docs.coronalabs.com/api/library/physics/addBody.html
You can use this with your vertices to make graph and use a touch joint to move it.
https://docs.coronalabs.com/api/library/physics/newJoint.html
Enclosing the chain so it meets itself might be helpful - I can’t quite remember, but explore those features a little
Thank you very much sporkfin!
Explore Edge Shape or “Chain” Bodies
https://docs.coronalabs.com/api/library/physics/addBody.html
You can use this with your vertices to make graph and use a touch joint to move it.
https://docs.coronalabs.com/api/library/physics/newJoint.html
Enclosing the chain so it meets itself might be helpful - I can’t quite remember, but explore those features a little
Thank you very much sporkfin!