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

◆ ApplyPotionDelay()

void Terraria.Player.ApplyPotionDelay ( Item sItem)
inlineprivate

Definition at line 52671 of file Player.cs.

52672 {
52673 if (sItem.type == 3001)
52674 {
52675 int minValue = 2400;
52676 int num = 4200;
52677 potionDelay = Main.rand.Next(minValue, num + 1);
52678 if (pStone)
52679 {
52681 }
52682 AddBuff(21, potionDelay);
52683 }
52684 else if (sItem.type == 227)
52685 {
52687 AddBuff(21, potionDelay);
52688 }
52689 else if (sItem.type == 5)
52690 {
52692 AddBuff(21, potionDelay);
52694 }
52695 else
52696 {
52698 AddBuff(21, potionDelay);
52699 }
52700 }
int restorationDelayTime
Definition Player.cs:2991
static readonly float PhilosopherStoneDurationMultiplier
Definition Player.cs:2583
void TryToResetHungerToNeutral()
Definition Player.cs:10066
void AddBuff(int type, int timeToAdd, bool quiet=true, bool foodHack=false)
Gives the player the provided buff. This accounts for if the player is immune to the buff....
Definition Player.cs:5700
int potionDelayTime
Definition Player.cs:2989
int mushroomDelayTime
Definition Player.cs:2993

References Terraria.Player.AddBuff(), Terraria.Player.mushroomDelayTime, Terraria.Player.PhilosopherStoneDurationMultiplier, Terraria.Player.potionDelay, Terraria.Player.potionDelayTime, Terraria.Player.pStone, Terraria.Main.rand, Terraria.Player.restorationDelayTime, and Terraria.Player.TryToResetHungerToNeutral().

Referenced by Terraria.Player.ItemCheck_Inner(), Terraria.Player.QuickHeal(), and Terraria.Player.QuickMana().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: