Question by 
               avin-kiseki · Dec 26, 2015 at 09:23 AM · 
                if-statementsconditionif-elseif else  
              
 
              How to use IF in Unity for selection MyScript

I have 2 script in unity, but in my condition, I want to use "Script b" if true, and if false using "Script c". Statement IF i call in "Script a" for selection Script b or Script c.. Thanks for your answer.. :D
 
                 
                question.jpg 
                (172.5 kB) 
               
 
              
               Comment
              
 
               
               
               Best Answer 
              
 
              Answer by usalalas · Dec 26, 2015 at 04:09 PM
Every time you want to use a variable that is in another script, you should declare it as PUBLIC STATIC. And the use it in your script like MyScript.variable == something;
Your answer
 
             Follow this Question
Related Questions
How to put an if statement inside an if statement? 3 Answers
If/else statement is always else 1 Answer
If Else problem 1 Answer
[GUI] Conditional Trigger for Button is flawed 0 Answers
Is There A Way To Make If Statement Condition Shorter 3 Answers