TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches

◆ NewItem() [9/10]

static int Terraria.Item.NewItem ( IEntitySource source,
Vector2 position,
int Type,
int Stack = 1,
bool noBroadcast = false,
int prefixGiven = 0,
bool noGrabDelay = false,
bool reverseLookup = false )
inlinestatic



This particular overload uses a Vector2 instead of X, Y, Width, and Height to determine the actual spawn position.

Returns

Definition at line 51990 of file Item.cs.

51991 {
51992 //IL_0001: Unknown result type (might be due to invalid IL or missing references)
51993 //IL_0008: Unknown result type (might be due to invalid IL or missing references)
51994 return NewItem(source, (int)position.X, (int)position.Y, 0, 0, Type, Stack, noBroadcast, prefixGiven, noGrabDelay, reverseLookup);
51995 }
Vector2 position
The position of this Entity in world coordinates.
Definition Entity.cs:28
int noGrabDelay
The delay, in ticks, before players can pick up this item. Usually set to 100 (approximately 1....
Definition Item.cs:183
static int NewItem(IEntitySource source, Vector2 pos, Vector2 randomBox, int Type, int Stack=1, bool noBroadcast=false, int prefixGiven=0, bool noGrabDelay=false, bool reverseLookup=false)
This particular overload uses two Vector2 to determine the actual spawn position.
Definition Item.cs:51478

References Terraria.Item.NewItem(), Terraria.Item.noGrabDelay, and Terraria.Entity.position.

+ Here is the call graph for this function: