Core/Movement: Added another researched spline flag

This commit is contained in:
Shauren
2012-08-06 17:42:12 +02:00
parent 0411ba31e0
commit a83c2ca60a
5 changed files with 11 additions and 11 deletions

View File

@@ -13369,7 +13369,7 @@ void Player::ApplyEnchantment(Item* item, EnchantmentSlot slot, bool apply, bool
if (ItemTemplate const* gem = sObjectMgr->GetItemTemplate(pEnchant->GemID))
if (gem->RequiredSkill && GetSkillValue(gem->RequiredSkill) < gem->RequiredSkillRank)
return;
// If we're dealing with a gem inside a prismatic socket we need to check the prismatic socket requirements
// rather than the gem requirements itself. If the socket has no color it is a prismatic socket.
if ((slot == SOCK_ENCHANTMENT_SLOT || slot == SOCK_ENCHANTMENT_SLOT_2 || slot == SOCK_ENCHANTMENT_SLOT_3)

View File

@@ -50,15 +50,15 @@ Location MoveSpline::ComputePosition() const
if (splineflags.final_angle)
c.orientation = facing.angle;
else if (splineflags.final_point)
c.orientation = atan2(facing.f.y-c.y, facing.f.x-c.x);
c.orientation = atan2(facing.f.y - c.y, facing.f.x - c.x);
//nothing to do for MoveSplineFlag::Final_Target flag
}
else
{
if (!splineflags.hasFlag(MoveSplineFlag::OrientationFixed|MoveSplineFlag::Falling))
if (!splineflags.hasFlag(MoveSplineFlag::OrientationFixed | MoveSplineFlag::Falling | MoveSplineFlag::Unknown0))
{
Vector3 hermite;
spline.evaluate_derivative(point_Idx,u,hermite);
spline.evaluate_derivative(point_Idx, u, hermite);
c.orientation = atan2(hermite.y, hermite.x);
}

View File

@@ -37,7 +37,7 @@ namespace Movement
None = 0x00000000,
// x00-x07 used as animation Ids storage in pair with Animation flag
Unknown0 = 0x00000008, // NOT VERIFIED
Unknown1 = 0x00000010, // NOT VERIFIED
FallingSlow = 0x00000010,
Done = 0x00000020,
Falling = 0x00000040, // Affects elevation computation, can't be combined with Parabolic flag
No_Spline = 0x00000080,
@@ -73,7 +73,7 @@ namespace Movement
// flags that shouldn't be appended into SMSG_MONSTER_MOVE\SMSG_MONSTER_MOVE_TRANSPORT packet, should be more probably
Mask_No_Monster_Move = Mask_Final_Facing | Mask_Animations | Done,
// Unused, not suported flags
Mask_Unused = No_Spline|Enter_Cycle|Frozen|Unknown1|Unknown2|Unknown3|Unknown4|SmoothGroundPath|Unknown6|Unknown7|Unknown8|Unknown9,
Mask_Unused = No_Spline|Enter_Cycle|Frozen|Unknown0|FallingSlow|Unknown2|Unknown3|Unknown4|SmoothGroundPath|Unknown6|Unknown7|Unknown8|Unknown9,
};
inline uint32& raw() { return (uint32&)*this; }
@@ -101,8 +101,8 @@ namespace Movement
void operator &= (uint32 f) { raw() &= f; }
void operator |= (uint32 f) { raw() |= f; }
void EnableAnimation(uint8 anim) { raw() = (raw() & ~(Mask_Animations | Falling | Parabolic)) | Animation | (anim & Mask_Animations); }
void EnableParabolic() { raw() = (raw() & ~(Mask_Animations | Falling | Animation)) | Parabolic; }
void EnableAnimation(uint8 anim) { raw() = (raw() & ~(Mask_Animations | Falling | Parabolic | FallingSlow)) | Animation | (anim & Mask_Animations); }
void EnableParabolic() { raw() = (raw() & ~(Mask_Animations | Falling | Animation | FallingSlow)) | Parabolic; }
void EnableFalling() { raw() = (raw() & ~(Mask_Animations | Parabolic | Animation)) | Falling; }
void EnableFlying() { raw() = Flying; }
void EnableCatmullRom() { raw() = Catmullrom | UncompressedPath; }
@@ -115,7 +115,7 @@ namespace Movement
uint8 animId : 3;
bool unknown0 : 1;
bool unknown1 : 1;
bool fallingSlow : 1;
bool done : 1;
bool falling : 1;
bool no_spline : 1;

View File

@@ -154,7 +154,7 @@ namespace Movement
inline void MoveSplineInit::SetOrientationInversed() { args.flags.orientationInversed = true;}
inline void MoveSplineInit::SetTransportEnter() { args.flags.EnableTransportEnter(); }
inline void MoveSplineInit::SetTransportExit() { args.flags.EnableTransportExit(); }
inline void MoveSplineInit::SetOrientationFixed(bool enable) { args.flags.orientationFixed = enable;}
inline void MoveSplineInit::SetOrientationFixed(bool enable) { args.flags.orientationFixed = enable; }
inline void MoveSplineInit::MovebyPath(const PointsArray& controls, int32 path_offset)
{

View File

@@ -159,7 +159,7 @@ namespace Movement
STR(AnimBit2 ),// 0x00000002,
STR(AnimBit3 ),// 0x00000004,
STR(Unknown0 ),// 0x00000008,
STR(Unknown1 ),// 0x00000010,
STR(FallingSlow ),// 0x00000010,
STR(Done ),// 0x00000020,
STR(Falling ),// 0x00000040, // Not Compartible With Trajectory Movement
STR(No_Spline ),// 0x00000080,