Fixed rotation

kiwacikiwaci Member, PRO Posts: 72

Hello,

i have an actor that's standing and i want when actor2 coming from his left witch will be winds hit him, i want him to fall but when he fall i want his feet to stay in there position , just like the hour hand in a clock

Thanks you

Comments

  • SocksSocks London, UK.Member Posts: 12,822

  • kiwacikiwaci Member, PRO Posts: 72

    i did that but still the bottom of the actor rotate as well

  • SocksSocks London, UK.Member Posts: 12,822

    I think I understand, you want him to rotate away from the 'wind' - but with his feet stuck to the ground ?

  • kiwacikiwaci Member, PRO Posts: 72

    @socks that's right

  • SocksSocks London, UK.Member Posts: 12,822
    edited July 2014

    @kiwaci said:
    socks that's right

    Without joints in GameSalad it can be a little tricky, but I can think of a few different ways you might do it . . . . I'm sure @RThurman could probably conjure up come up some of his fiendishly clever maths if you asked him - this seems very related to his recent pendulum ideas.

    Otherwise you could try this.

    When the wind actor hits the 'hour hand' actor, it releases a 'weight' (invisible) that drops to the floor (invisible) - and the 'hour hand' actor uses the movement of this 'weight' to define its angle (via sin + cos).

    The advantage to this method is that as the weight bounces when it hits the floor, so will the 'hour hand' actor, so you impart GameSalad's build it physics onto a rotating actor . . .

    Hope that makes some sense !?

  • SocksSocks London, UK.Member Posts: 12,822

    Like this:

  • SocksSocks London, UK.Member Posts: 12,822
    edited July 2014

    ...

  • kiwacikiwaci Member, PRO Posts: 72

    thanks a lot for your efforts, that what i was looking for, but what are the behaviours in the "hour hand " actor, you said "the 'hour hand' actor uses the movement of this 'weight' to define its angle (via sin + cos)." , how can i do that ?

  • kiwacikiwaci Member, PRO Posts: 72

    @socks can you please upload the project to mediafire ?

  • kiwacikiwaci Member, PRO Posts: 72

    ?

  • SocksSocks London, UK.Member Posts: 12,822

    @kiwaci said:
    socks can you please upload the project to mediafire ?

    Here you go . . .

    Link: https://www.mediafire.com/?4k4rej7qqy14iu2

    I added a change velocity behaviour into the 'weight', so the fall starts off with more of a kick.

  • kiwacikiwaci Member, PRO Posts: 72

    @socks Thanks a lot, you're awesome :D

  • SocksSocks London, UK.Member Posts: 12,822

    @kiwaci said:
    socks Thanks a lot, you're awesome :D

    No problem, good luck with your game.

Sign In or Register to comment.