OSDN Git Service

Added Assets for main menu
[mindgames/Mindgames_main.git] / Mindgames / Library / PackageCache / com.unity.shadergraph@6.9.0 / Editor / Data / Nodes / Utility / Logic / AndNode.cs
1 using System.Reflection;
2 using UnityEngine;
3
4 namespace UnityEditor.ShaderGraph
5 {
6     [Title("Utility", "Logic", "And")]
7     class AndNode : CodeFunctionNode
8     {
9         public AndNode()
10         {
11             name = "And";
12         }
13
14
15         public override bool hasPreview
16         {
17             get { return false; }
18         }
19
20         protected override MethodInfo GetFunctionToConvert()
21         {
22             return GetType().GetMethod("Unity_And", BindingFlags.Static | BindingFlags.NonPublic);
23         }
24
25         static string Unity_And(
26             [Slot(0, Binding.None)] Boolean A,
27             [Slot(1, Binding.None)] Boolean B,
28             [Slot(2, Binding.None)] out Boolean Out)
29         {
30             return
31                 @"
32 {
33     Out = A && B;
34 }
35 ";
36         }
37     }
38 }