How can I constrain at the edge of screen and grow?

Simple Gamer ArtsSimple Gamer Arts Member, PRO Posts: 305
edited January 2018 in Working with GS (Mac)

How can I constrain an actor at the bottom edge of screen and make him grow back and forth in height?

I got the interpolate growing back and forth fine... just need to know how to constrain the actor to the bottom of the screen and make him grow back and forth in Height... in other words, his center would be moving up and down (i'm guessing)

Comments

  • SocksSocks London, UK.Member Posts: 12,822
    edited January 2018

    @Simple Gamer Arts said:
    How can I constrain an actor at the bottom edge of screen and make him grow back and forth in height?

    Constrain Height to A*sin( game.time*B )+C
    Constrain Y position to Height/2

    A is the amount of growth up and down, B is the speed of growth, C is the actor's height.

  • Simple Gamer ArtsSimple Gamer Arts Member, PRO Posts: 305

    @Socks you sir are a master. Thank you!

Sign In or Register to comment.