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

◆ MountedCenter

Vector2 Terraria.Player.MountedCenter
getset

Returns the player's center adjusted for mount and step stool usage. Typically used in conjunction with M:Terraria.Player.RotatedRelativePoint(Microsoft.Xna.Framework.Vector2,System.Boolean,System.Boolean) to retrieve a suitable position for positioning items and effects originating from the player.

Definition at line 3691 of file Player.cs.

3692 {
3693 get
3694 {
3695 //IL_002d: Unknown result type (might be due to invalid IL or missing references)
3696 return new Vector2(position.X + (float)(width / 2), position.Y + 21f + HeightOffsetHitboxCenter);
3697 }
3698 set
3699 {
3700 //IL_0001: Unknown result type (might be due to invalid IL or missing references)
3701 //IL_0011: Unknown result type (might be due to invalid IL or missing references)
3702 //IL_0024: Unknown result type (might be due to invalid IL or missing references)
3703 //IL_0029: Unknown result type (might be due to invalid IL or missing references)
3704 position = new Vector2(value.X - (float)(width / 2), value.Y - 21f - HeightOffsetHitboxCenter);
3705 }
3706 }
Vector2 position
The position of this Entity in world coordinates.
Definition Entity.cs:28
int width
The width of this Entity's hitbox, in pixels.
Definition Entity.cs:46
float HeightOffsetHitboxCenter
Definition Player.cs:3605

Referenced by Terraria.Projectile.AI_015_Flails(), Terraria.Projectile.AI_019_Spears(), Terraria.Projectile.AI_075(), Terraria.Projectile.AI_140_MonkStaffT1(), Terraria.Projectile.AI_142_MonkStaffT2And3(), Terraria.Projectile.AI_158_GetHomeLocation(), Terraria.Projectile.AI_160_Kites(), Terraria.Projectile.AI_161_RapierStabs(), Terraria.Projectile.AI_164_GetHomeLocation(), Terraria.Projectile.AI_182_FinalFractal(), Terraria.Projectile.AI_190_NightsEdge(), Terraria.Projectile.AI_191_TrueNightsEdge(), Terraria.Player.ApplyEquipFunctional(), Terraria.Player.BloodButcherer_TryButchering(), Terraria.Player.DoEyebrellaRainEffect(), Terraria.Player.GetBackHandPosition(), Terraria.Player.GetFrontHandPosition(), Terraria.Player.ItemCheck_ApplyHoldStyle_Inner(), Terraria.Player.ItemCheck_ApplyUseStyle_Inner(), Terraria.Player.ItemCheck_Shoot(), Terraria.Player.TentacleSpike_TrySpiking(), Terraria.Player.TryToPoop(), Terraria.DelegateMethods.Mount.WolfMouthPosition(), and Terraria.Player.Yoraiz0rEye().