Custom Script (if Statement)

Discussion in 'BBNodes' started by Syntax Genius, Aug 31, 2020.

  1. Syntax Genius

    Syntax Genius Boxer

    Joined:
    Aug 30, 2020
    Messages:
    6
    Likes Received:
    10
    Hey Boxers, while I develop my game with BuildBox I'm creating a few custom scripts that I want to share with you in case someone need it.

    Today I'll share one simple but useful script "If Statement", that you can use to check a variable or any other boolean. Below you'll find the instructions.

    Custom Script
    Function: If Statement
    Inputs: 1 (Check)
    Outputs: 2 (True, False)
    Attributes: 1 (Name)

    Instructions:
    - Connect the source (e.g.. variable) or any node to the "Check" input
    - Connect the "True", "False" or both outputs to any nodes that you want to be performed after the script check if the input result True or False.

    Files:
    2 Images
    1 Source Code

    if_statement_full.jpg if_statement_code.jpg
     

    Attached Files:

  2. Josh (Nology Games)

    Josh (Nology Games) Community Manager Staff Member

    Joined:
    Nov 27, 2017
    Messages:
    754
    Likes Received:
    243
    Awesome stuff!
     
    Syntax Genius likes this.
  3. Vlad-NY

    Vlad-NY Avid Boxer

    Joined:
    Jul 21, 2018
    Messages:
    223
    Likes Received:
    125
    Well done, this thing can be useful in so many scenarios. Keep it up!
     
  4. Syntax Genius

    Syntax Genius Boxer

    Joined:
    Aug 30, 2020
    Messages:
    6
    Likes Received:
    10
    Thank you
     
  5. Syntax Genius

    Syntax Genius Boxer

    Joined:
    Aug 30, 2020
    Messages:
    6
    Likes Received:
    10
    Thank you for the feedback, I’ll keep sharing some cool scripts for everybody to use.
     
  6. volcank

    volcank Serious Boxer

    Joined:
    Oct 8, 2015
    Messages:
    732
    Likes Received:
    347
    Awesome! Thank you so much!
     
    Syntax Genius likes this.
  7. rizwanashraf

    rizwanashraf Avid Boxer

    Joined:
    Dec 3, 2015
    Messages:
    331
    Likes Received:
    208
    Awe, So cute Node :) Thank you for sharing.
     
  8. TheGameAppStudio

    TheGameAppStudio Serious Boxer

    Joined:
    Nov 2, 2016
    Messages:
    859
    Likes Received:
    264
    Well Done and Thank you
     
  9. Playkit

    Playkit Boxer

    Joined:
    Jan 21, 2020
    Messages:
    11
    Likes Received:
    2
    Thanks for sharing this script, just solved real a problem I had :)( see Signal on Signal off on my original post )
    This is the set up I used if anyone comes across the same problem (note the delay) bb if statement.png
     

Share This Page