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:
    11
    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:

    Laby, Playkit, chris15smile and 7 others like this.
  2. Josh (Nology Games)

    Josh (Nology Games) Avid Boxer

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

    Vlad-NY Serious Boxer

    Joined:
    Jul 21, 2018
    Messages:
    604
    Likes Received:
    360
    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:
    11
    Thank you
     
  5. Syntax Genius

    Syntax Genius Boxer

    Joined:
    Aug 30, 2020
    Messages:
    6
    Likes Received:
    11
    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:
    794
    Likes Received:
    391
    Awesome! Thank you so much!
     
    Syntax Genius likes this.
  7. rizwanashraf

    rizwanashraf Avid Boxer

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

    TheGameAppStudio Serious Boxer

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

    Playkit Boxer

    Joined:
    Jan 21, 2020
    Messages:
    13
    Likes Received:
    3
    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