Behaviours not behaving

imjustmikeimjustmike Member Posts: 450
edited July 2012 in Working with GS (Mac)
Hey,

I'm trying to create a highlight effect for a menu item, essentially after a menu loads, I want a menu item to 'wiggle' (rotate a little one way, then a little the other way)

I've managed to achieve the effect through a series of rules and attributes. Problem is, after a certain amount of time it stops working. Sort of. It continues to run the behaviours, they continue to make the menu item 'wiggle', but it looks like the rules have gotten out of sync, the menu item fails to return to it's original position, and wiggles off centre.

I've included the rules below, if anyone could take a look and point me in the right direction I'd much appreciate it. Equally, if I've gone about this wrong and there's an easier way to achieve the effect I'd love to hear it.

Thanks in advance

image

Comments

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598

    @imjustmike

    Hi Mike, the reason that things get out of sync is because to rotate to a certain angle at a certain speed takes a certain time, which more than likely isn't the times in the Timers. (Hope I've explained that well enough...)

    I've made a GSC test and I've used Rotate Behaviours instead; see if that's OK for you. The amount of wiggles can be adjusted by the Count attribute, and of course the speed in the Rotate Behaviours adjusted as well as the time in the Timers to suit your needs.

    https://dl.dropbox.com/u/14060718/Wiggle DGtest.gameproj.zip

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • imjustmikeimjustmike Member Posts: 450
    I figured it must be something like that. I played around for ages with the timers but couldn't get them to be the speed I liked without resulting in being out of synch.

    Thanks very much for the test build - I'll have a play with it and report back

    Thanks again for taking the time to help
  • imjustmikeimjustmike Member Posts: 450
    Just noticed I failed to report back! This was very useful and I've implemented tis way of doing it into my game, so thank you very much @gyroscope
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598

    @imjustmike

    You're very welcome, Mike. Glad it worked out for you. :-)

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • ronixusronixus Member Posts: 19
    edited August 2012
    @gyroscope Thank you! This will be very helpful. :)
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598

    Glad it helps you too, @ronixus :-)

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

Sign In or Register to comment.