User Tag List

Results 1 to 5 of 5

Thread: Picture based on availalibility

  1. #1
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)

    Join Date
    Oct 2006
    Location
    In a Dark room with only a lamp
    Posts
    367
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Picture based on availalibility

    Hi all

    how can i change which picture is displayed based on the contents of a folder?

    I have numerous jpg images in a folder each one is refrenced using a 13 digit number. there is also a file name NA.jpg. this is th image to be used if a certain file does not exist.

    On one frame i have a loop which creates a picture object and then adds a 13 digit id to an alterabl string. in order to make the picture display i have done the following:

    File Name: Alt String A (Picture) exists - Set Picture to appdir$+"images\"AltStringA+".jpg"

    The abovw works great if the file exists. the problem is though that i cannot get the NA.jpg to display if the file doesn't exist.

    anyone got any tips?

  2. #2
    Clicker Multimedia Fusion 2 Developer

    Join Date
    Jun 2006
    Location
    Darlington, UK
    Posts
    3,298
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Picture based on availalibility

    Set every picture to show NA before your loop?

    Alternatively, show us the code you've used to make it show the NA.jpg, as that's the bit that's broken it could be useful to show it to us...

  3. #3
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)

    Join Date
    Oct 2006
    Location
    In a Dark room with only a lamp
    Posts
    367
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Picture based on availalibility

    I'll have to type the code out so bear with me:

    Bit of background - the picture objects are displayed on an 9x 4 grid

    start of frame: Start loop displayy 4 times

    on loop displayy start loop displayx 8 times

    on loop displayx create picture object
    - set picture to appdir$+"images\NA.jpg"
    - set alt string a of Picture to 13 digit id (this is retreived from an array and i know this works fine)
    - start loop image 1 time

    on loop image
    + file alt string a (picture) exists
    - set picture to appdir$+"images\"+altsringa(picture)+".jpg"

    That works great. If the image doesn't exist though just a blank square is displayed.

    I haven't posted my positioning code as it is quite complex and uses counters and other objects. The positioning itself is fine though.

    Hope what i have written makes sense

    (Note - I have also tried using the If Else object instead of a third loop but that doesn't seem to work.)

  4. #4
    Clicker Multimedia Fusion 2 Developer

    Join Date
    Jun 2006
    Location
    Darlington, UK
    Posts
    3,298
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Picture based on availalibility

    Your last loop doesn't restrict its actions to a single picture object, that could do strange things (like setting all pictures to the same file).

  5. #5
    Clicker Fusion 2.5
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)

    Join Date
    Oct 2006
    Location
    In a Dark room with only a lamp
    Posts
    367
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Picture based on availalibility

    It doesn't restrict but it still works. each individual picture is displayed correctly it's just the NA picture that isn't.

Similar Threads

  1. Take picture and make from it Active Object / Active picture
    By qenio in forum Android Export Module Version 2.0
    Replies: 3
    Last Post: 3rd February 2014, 07:34 AM
  2. BUG: Active Picture > New Picture from Selector doesn't wait for image - Beta9
    By AyreGuitar in forum iOS Export Module Version 2.0
    Replies: 5
    Last Post: 27th January 2013, 03:09 PM
  3. Picture Name$ for Active Picture
    By AyreGuitar in forum iOS Export Module Version 2.0
    Replies: 2
    Last Post: 11th April 2012, 07:54 AM
  4. timer based???
    By rurkryber in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 30th June 2009, 09:54 PM
  5. Tactical-based RPG.
    By Erkz in forum File Archive
    Replies: 0
    Last Post: 23rd August 2007, 09:11 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •