Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
PlayerInteractionAnchor.cs
Go to the documentation of this file.
2
4{
5 public int interactEntityID;
6
7 public int X;
8
9 public int Y;
10
11 public bool InUse => interactEntityID != -1;
12
13 public PlayerInteractionAnchor(int entityID, int x = -1, int y = -1)
14 {
15 interactEntityID = entityID;
16 X = x;
17 Y = y;
18 }
19
20 public void Clear()
21 {
23 X = -1;
24 Y = -1;
25 }
26
27 public void Set(int entityID, int x, int y)
28 {
29 interactEntityID = entityID;
30 X = x;
31 Y = y;
32 }
33
35 {
36 if (InUse)
37 {
38 return TileEntity.ByID.ContainsKey(interactEntityID);
39 }
40 return false;
41 }
42
44 {
46 {
47 return null;
48 }
50 }
51}
static Dictionary< int, TileEntity > ByID
Definition TileEntity.cs:18
PlayerInteractionAnchor(int entityID, int x=-1, int y=-1)