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

◆ OnStack()

static void Terraria.ModLoader.ItemLoader.OnStack ( Item destination,
Item source,
int numToTransfer )
inlinestatic

Calls the GlobalItem.OnStack hooks in destination , then the ModItem.OnStack hook in destination
OnStack is called before the items are transferred from source to destination

Parameters
destinationThe item instance that source will attempt to stack onto
sourceThe item instance being stacked onto destination
numToTransferThe quantity of source that will be transferred to destination

Definition at line 1893 of file ItemLoader.cs.

1894 {
1896 while (enumerator.MoveNext())
1897 {
1898 enumerator.Current.OnStack(destination, source, numToTransfer);
1899 }
1900 destination.ModItem?.OnStack(source, numToTransfer);
1901 }
static GlobalHookList< GlobalItem > HookOnStack

References Terraria.ModLoader.ItemLoader.HookOnStack.

Referenced by Terraria.ModLoader.ItemLoader.StackItems().

+ Here is the caller graph for this function: