Page 1 of 1

Angry Birds path?

Posted: Sat Feb 25, 2012 10:43 pm
by richardmac
I'm prototyping an app that requires objects to go from the left hand side of the screen to the right hand side of the screen, in a motion similar to how you propel a bird in Angry Birds (a parabolic path, I guess?)

I know I could just make a big huge list of coordinates, but there's got to be an easier way. Anyone?

Re: Angry Birds path?

Posted: Sat Feb 25, 2012 11:47 pm
by malte
There is no single line command for that (yet ;-) ) However, if you are using AE, you can use movePolygonal.

Use the build in graphics opject (freehand curve) to construct your path. Maybe edit it a little. There are also stacks available to construct a bezier curve. Afterwards, use movePolygonal to move your object.

hope that helps,

Malte

Re: Angry Birds path?

Posted: Sun Feb 26, 2012 12:08 am
by sturgis
Also might look at this thread: http://forums.runrev.com/viewtopic.php?f=7&t=11185 there is a link at the end to a newsletter that has a guide to building a canon shooting type of game.

Also, if you want a calculated path, sin and cos can be used to generate factors that can then be used to calculate a trajectory.

Just off the top of my head.. Determine the angle of launch. use sin and cos to create x, y factors, use those factors unchanged combined with your launch velocity you can move the object in a straight line. Since you want it to be a ballistic trajectory, the y factor can be modified by taking the force of gravity and again to 'tweak' the value of y, adjusting for gravity over time. I think.

Re: Angry Birds path?

Posted: Wed Oct 03, 2012 10:20 pm
by salman.r1BUSYiYh
Hi guys
i just downloaded livecode and want to make a similar app to angrybirds i.e a ball launches when a person swipes the screen and hits a target
is it possible to do this now via livecode also as a newbie to this will it be better for me to get animation engine as well?
thnx

Re: Angry Birds path?

Posted: Thu Oct 04, 2012 8:40 pm
by malte
Hi,

as animationEngine is entirely written in liveCode everything contained in it is possible without it in liveCode. Considder it being a time saver on some tricky stuff. Once you got the livecode basics down, download the animationEngine trial and see if it is for you. :-)

Cheers,

Malte

Re: Angry Birds path?

Posted: Thu Oct 04, 2012 9:59 pm
by salman.r1BUSYiYh
thanx