Animation and Pre-load art Question.

ozboybrianozboybrian PRO Posts: 2,102
So pretend one Character has 20, 20 frame animations.
But only one batch can be used per turn along side the correct boolean being true.

If I click to not pre load art, would this benefit or the fact that the actor has those animations set it inside him, used or not, would that crank up the Ram?

Thanks in advance.

Comments

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited December 2011
    Hi Brian, hope you had a good Christmas!

    If the character is say, 64p square, then with your 20 x 20 frames making 400 64pixel square frames, they would all fit into a 1024 square image, so the RAM wouldn't be at all bad, and they shouldn't take that long to load. But I guess it depends on what else you'll be marking as pre-load art which might make a difference... (TSB in particular was championing sprite sheets by the way, that'd make life even easier).

    Then again, maybe just pre-load the walking animations and leave the other animations to load when needed...I don't think that should affect performance much at all.

    So I don't know if that's any help as I've suggested using either way...

    --------------------------------------------
    http://davidgriffinapps.co.uk/

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

  • MotherHooseMotherHoose Member Posts: 2,456
    Preload Art pertains to your Actor Assets
    Animation images are utilized in Behaviors
    the animation images are NOT preloaded (in general Images/Resources in Mac apps are loaded at runtime as called.)

    the animationBehavior sequentially changes the self.Image at a timed interval.

    and, I believe that when the sequence is run the images used are not retained in RAM

    think about getting rid of those 20 boolean attributes
    make one Index (game or scene Attribute) named animation#
    Rule: when Attribute: game/scene.animation# = 0
    (do nothing … leave the behavior blank)
    Otherwise:
    Rule: when game/scene.animation# = 1
    do the AnimationBehavior
    Rule: when game/scene.animation# = 2
    do the AnimationBehavior

    eliminate 20 booleans crowding up the list of attributes …
    and if the 1st condition is true, computer stops processing the Rule ... and doesn't continuously verify the state of the 20 booleans

    MH
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    Well, I've learned something there, thanks from me, MH! :-)

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

  • CloudsClouds Member Posts: 1,599
    gyroscope "If the character is say, 64p square, then with your 20 x 20 frames making 400 64pixel square frames, they would all fit into a 1024 square image"

    400 x 64 pixel images would not fit into a 1,024 x 1,024 square, you'd need a 1,280 x 1,280 pixel square image.

    (64 x 20 = 1280)
  • MotherHooseMotherHoose Member Posts: 2,456
    @Tynan … when/if iPad3 goes retina display we are going to have to have >1024x1024 GS import limit!
    of course, as mynameisAce pointed out: we can import them at 1024 and replace them with 2048 in the Project's Contents imageFolder.

    @gyroscope … coming from you …that thanx has got to be the nicest I ever received in the forum!

    MH
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    Thank you again, MH, I take that as a very nice compliment! :-)

    Hi Tynan, thanks for correcting me, (I just said in my mind: "16 x 16, then sounds enough" but of course that amounts to 256, not quite enough for 400...) although it's still an acceptable amount to pre-load (if you could pre-load animation frames but as MH pointed out, you can't...) Cheers anyway!

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

  • ozboybrianozboybrian PRO Posts: 2,102
    Thanks for the responses everyone! Hope you all had a great Christmas :D

    @gyroscope - Yeah TSB actually was telling me about Sprite Sheets etc... I WANT THEM SOOO BAD! lol.
    @Mothermoose - Index sounds better all the time.... Still learning I am xD

    So basically, i'll have an actor that unlocks new physical features and with the way GS works id have to change the entire frame. (actor is about 200 w / 100 h)
    So he won't utilise all animations per scene, but depending on his upgrades etc.
    But of course the rules will still be there in him while playing in the game...

    But from what I read above it won't effect performance at all! :D

    Correct me if i'm wrong. TSB is probably going to get up me, he told me a lot about this stuff before but i'm hoping this is a suitable work-a-round.
    Can't wait for Sprite Sheets!!!
  • MotherHooseMotherHoose Member Posts: 2,456
    We are all still learning!
    I enjoy learning something new every day.
    Some of us old dogs know a lot of tricks … often times the puppies teach us something new or ask a question that forces us to try to think of a new trick!
    … enjoy the adventure!

    MH
Sign In or Register to comment.