Curving a Rainbow

RodericRoderic Member Posts: 145
edited November -1 in Working with GS (Mac)
I'm trying to create an actor where the user can swipe and it will draw an arched rainbow. I figured out how to make it draw a straight line rainbow, but I can't figure out how to make it curved. Does anyone have any suggestions? Thanks.

image

Comments

  • tenrdrmertenrdrmer Member, Sous Chef, Senior Sous-Chef Posts: 9,934
    Check out sin and cos in the wiki.
  • SparkyidrSparkyidr Member, PRO Posts: 2,033
    Like t-Shirt says.
    the best you can do is :
    http://gamesalad.com/forums/topic.php?id=16974
    Check the vids a few posts into the thread showing the real time corners

    It's not ideal, but works using the sin function.
  • RodericRoderic Member Posts: 145
    Thanks guys. I'll let you know if I can get it to work.
  • tenrdrmertenrdrmer Member, Sous Chef, Senior Sous-Chef Posts: 9,934
    Couldn't you spawn the actor and then stretch its width out from the spawn point and use sin and/or cos to make it arc?
  • SparkyidrSparkyidr Member, PRO Posts: 2,033
    nah, that would still count as bitmap manipulation, which gamesalad can't do.
  • RodericRoderic Member Posts: 145
    Well, I couldn't figure it out with sin and cos, so I made a workaround using interpolate. It won't really be the user drawing it per se, but at least they can resize it and move it around.

    I knew I should have paid better attention in calculus... but oh boy that was so long ago. Ha.
Sign In or Register to comment.