summaryrefslogtreecommitdiff
path: root/SurvivalTest/Assets/Scripts/Items/Item_SpaceBeamer.cs
blob: db76bb8074a93cf2c4b80f6322e3bbf29000749a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Item_SpaceBeamer : ItemBase
{
	public override string name => "ÎÀÐÇÉäÏß";

	public override string iconPath => "art/ui/itemicon/space_beamer";

	string prefabPath = "prefabs/weapon/space_beam";

	public override void OnUse(GameObject owner)
	{
		TestSpaceBeam beam = UnityEngine.Object.Instantiate<TestSpaceBeam>(ResourceManager.Instance.Load<TestSpaceBeam>(prefabPath));

		Vector3 pos3D = owner.GetComponent<TopDownTransform>().position;
		beam.Set(pos3D + new Vector3(3, 0, 0));
	}

}