diff options
Diffstat (limited to 'SurvivalTest/Assets/Scripts/Props/Prop_B2Phone.cs')
-rw-r--r-- | SurvivalTest/Assets/Scripts/Props/Prop_B2Phone.cs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/SurvivalTest/Assets/Scripts/Props/Prop_B2Phone.cs b/SurvivalTest/Assets/Scripts/Props/Prop_B2Phone.cs new file mode 100644 index 0000000..40d2f87 --- /dev/null +++ b/SurvivalTest/Assets/Scripts/Props/Prop_B2Phone.cs @@ -0,0 +1,24 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +/// <summary> +/// B2ºô½Ð»ú +/// </summary> +public class Prop_B2Phone : PropBase +{ + public override string name => "B2"; + + public override string iconPath => "art/ui/propicon/plane"; + + string prefabPath = "prefabs/weapon/b2"; + + public override void OnUse(GameObject owner) + { + TestB2 b2 = UnityEngine.Object.Instantiate(ResourceManager.Instance.Load<TestB2>(prefabPath)); + + Vector3 pos3D = owner.GetComponent<TopDownTransform>().GetProjectedPosition(); + b2.Set(pos3D + new Vector3(-15, 0, 0), pos3D + new Vector3(15, 0, 0), 20f, 3f); + } + +}
\ No newline at end of file |