possible?

Gamer61Gamer61 Member Posts: 40
edited February 2012 in Working with GS (Mac)
Same actor different image?
-All in one
-change to random image
possible?

Comments

  • old_kipperold_kipper Member Posts: 1,420
    edited February 2012
    totally. if your image files for the actor that you want to randomise are numbered as part of the name then you can use a rule or timer to fire the expression-

    change self.image to "image"..(random(10,26))..".png"

    in this case the files that changed would be image10.png to image26.png In most cases sequences of images have the same number of digits in the file name so when I use a program to output images I start with a 1 as the first digit so the random works where it won't (i think) if you where to number with zeros in front of the digits such as 001.

    hope that helps

    kipper

    p.s its better to post a title that gives a clue as to your problem as it is far more likely to get answered.
  • CloudsClouds Member Posts: 1,599
    edited February 2012
    @old_kipper

    Did you know (one in a series of dreary 'did you know facts' I am planning for this thread):

    If you number your images with just a number (1.png 2png 3png 4png 5png 6png 7png etc etc) you can simply do:

    Change image to: random (1,7)

    Or

    Change image to: self.time

    (etc)


    No need for the "image".. and ..".png" stuff.
  • old_kipperold_kipper Member Posts: 1,420
    @tynan I look forward to a blogs worth of dreary facts from you that would raise the operation of my tiny fishy brain a notch. But there is a case for adding the image name when you run custom numbers for a score and if like me you need some reminder of which group of images your pulling on for another purpose (I have been know to get out milk, use it and return it to the cooker rather than the fridge).
Sign In or Register to comment.