We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c0f89f7 commit ec772fbCopy full SHA for ec772fb
UltimateTeleport/Teleport.cs
@@ -0,0 +1,30 @@
1
+using System.Collections;
2
+using System.Collections.Generic;
3
+using UnityEngine;
4
+
5
+public class Teleport : MonoBehaviour
6
+{
7
+ public string triggerName;
8
+ public Transform 3dClxviClwnPort_;
9
+ public Transform 2dClxviClwnPort_;
10
11
+ private void OnTriggerEnter2D(Collider2D dclxviclan)
12
+ {
13
+ if(dclxviclan.CompareTag(triggerName)
14
15
+ dclxviclan.transform.position = 2dClxviClwnPort_.transform.position;
16
+ }
17
18
19
20
+ private void OnTriggerEnter(Collider dclxviclan)
21
22
23
24
+ dclxviclan.transform.position = 3dClxviClwnPort_.transform.position;
25
26
27
28
29
30
+}
0 commit comments