User Tag List

Results 1 to 2 of 2

Thread: Total Noob Question about if then statements

  1. #1
    Clicker 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
    Jan 2018
    Location
    North Carolina, USA
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Total Noob Question about if then statements

    So this is what I have, I have a get object that's accessing an external web page and I'd like to check the response code to display a different message.

    Right now I have "On Get Complete" set to change the alterable text of my string object to the response code and then it displays that alterable text.

    I'd like this to be a little more informative to the end user, however, but I can't seem to figure out how to do if statments in CF.

    I'd like to do this....

    Code:
    if( Recieved$( "Response Code" ) == 404 ) {
    set alterable string to "404 Page not Found, please contact the admin"
    } else if ( Recieved$( "Response Code" ) == 404 ) {
    set alterable string to "200 Status Okay, request recieved."
    }
    I'm a PHP developer and this is my very first attempt at anything in CF so I'm a little confused on how to write such a conditional statement in CF.

    Thanks in advance for any help given!

  2. #2
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleSWF Export Module

    Join Date
    Jul 2006
    Location
    Norway
    Posts
    325
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Just make two events:

    Event 1:
    *On Get Complete
    *Compare two general values. Recieved$( "Response Code" ) is Equal to 404
    -Then set alterable string to "
    404 Page not Found, please contact the admin"

    Event 2:
    *On Get Complete
    *Compare two general values.
    Recieved$( "Response Code" ) is Different from 404
    -Then set alterable string to "200 Status Okay, request recieved."

    (* is Conditions, - is action)

    You find the compare two general values under the Special Object (The gears).

Similar Threads

  1. Total n00b enemy movement question, but I can't get this to work
    By Del_Duio in forum Multimedia Fusion 2 - Technical Support
    Replies: 13
    Last Post: 25th September 2014, 09:22 PM
  2. Total number of Global Alterable Values question
    By mobichan in forum Multimedia Fusion 2 - Technical Support
    Replies: 7
    Last Post: 16th May 2012, 10:08 PM
  3. Simple question about OR statements
    By pirodaggar in forum Multimedia Fusion 2 - Technical Support
    Replies: 14
    Last Post: 22nd August 2010, 08:20 PM
  4. Another Noob Question
    By AidanHawke in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 9th January 2009, 10:13 PM
  5. Noob question
    By gamefreak202 in forum Multimedia Fusion 2 - Technical Support
    Replies: 8
    Last Post: 15th August 2007, 06:16 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
  •