Graphics skipping a beat!!!

ZombiebrainsZombiebrains www.zombiebrains.co.ukMember, PRO Posts: 296
edited April 2012 in Working with GS (Mac)
Hello guys

I am just about to get my app ready for release but there are a few niggles with some of my graphics.

I have a graphic that is off screen and when a scene is leaded it moves to a set X and Y position. When running this on my MAC is runs perfect every time but when ran in HOC format on my iPhone, sometimes the graphic decides in one instance to not stop and fly off the top of the screen.

Other times its ok?

Why would this happen?

I am now thinking of changing the movement from a 'Move to' to a 'Change Velocity' and when it reaches the X & Y co-ordinates then I would change the velocity to speed '0' to stop it.

Is this how people do this sort of thing...

I'm trying desperately to optimise my app by changing stuff as its really suffering problems when run on my iPhone (OS 5.1)

It takes a Zombie to know a Zombie!!!

Best Answer

  • xforcexforce Posts: 187
    edited April 2012 Accepted Answer
    Rule: After 1 second

    Interpolate self.X to 160
    Duration (enter a number here that will represent the amount of seconds it takes to complete movement. this will replace your "speed=200")

    Interpolate self.Y to 30
    Duration (enter a number here that will represent the amount of seconds it takes to complete movement. this will replace your "speed=200")

Answers

  • Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273
    Hey Anthony,

    You must be using interpolate.
    Interpolate has been broken for a while, I believe.
    You might want to use "move to"
  • ZombiebrainsZombiebrains www.zombiebrains.co.ukMember, PRO Posts: 296
    Hey Anthony,

    You must be using interpolate.
    Interpolate has been broken for a while, I believe.
    You might want to use "move to"
    Nope...i'm using 'Move to'



    It takes a Zombie to know a Zombie!!!

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    lol... it's the other way around. Move To is known to have problems. Make sure to use Interpolate and then let us know if the problems continue.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • ZombiebrainsZombiebrains www.zombiebrains.co.ukMember, PRO Posts: 296
    ah, so can you tell me how I would change a 'Move To' to a Interpolate as I've never used that to move an actor?

    eg as I have it now

    RULE: After 1 second

    Move to X=160 Y=30 Speed = 200

    Thanks Bray

    It takes a Zombie to know a Zombie!!!

  • ZombiebrainsZombiebrains www.zombiebrains.co.ukMember, PRO Posts: 296
    edited April 2012
    Thanks for the example Xforce...works a treat. Hopefully it will make a big difference on the iPhone.

    Only now need to replace all 'Move to' with Interpolates! lol :)

    Hey, Thanks again Bray for the advice :)

    It takes a Zombie to know a Zombie!!!

  • ZombiebrainsZombiebrains www.zombiebrains.co.ukMember, PRO Posts: 296
    lol... it's the other way around. Move To is known to have problems. Make sure to use Interpolate and then let us know if the problems continue.
    Hiya Tatiang

    Wow, the difference is miles superior, there's a huge difference in performance when converting my 'Move To' commands to use Interpolate.

    My graphics now follow the route I tell them to follow and no longer go off the screen!
    Thank you for the update...

    It takes a Zombie to know a Zombie!!!

  • entersimonentersimon Member, PRO Posts: 273
    Just remember that interpolating actors won't collide.
  • ZombiebrainsZombiebrains www.zombiebrains.co.ukMember, PRO Posts: 296
    Just remember that interpolating actors won't collide.
    ah yes, thanks for reminding me Entersimon :)

    It takes a Zombie to know a Zombie!!!

Sign In or Register to comment.