diff options
author | madmaxoft <github@xoft.cz> | 2014-07-17 22:15:34 +0200 |
---|---|---|
committer | madmaxoft <github@xoft.cz> | 2014-07-17 22:15:34 +0200 |
commit | 2423fbf2efa39e28cc348acc11b9269e573dcdef (patch) | |
tree | ce58732c3d16aeef3e68e2c3bdcb372199605312 /src/Entities | |
parent | Fixed spaces around single-line comments. (diff) | |
download | cuberite-2423fbf2efa39e28cc348acc11b9269e573dcdef.tar cuberite-2423fbf2efa39e28cc348acc11b9269e573dcdef.tar.gz cuberite-2423fbf2efa39e28cc348acc11b9269e573dcdef.tar.bz2 cuberite-2423fbf2efa39e28cc348acc11b9269e573dcdef.tar.lz cuberite-2423fbf2efa39e28cc348acc11b9269e573dcdef.tar.xz cuberite-2423fbf2efa39e28cc348acc11b9269e573dcdef.tar.zst cuberite-2423fbf2efa39e28cc348acc11b9269e573dcdef.zip |
Diffstat (limited to 'src/Entities')
29 files changed, 141 insertions, 141 deletions
diff --git a/src/Entities/ArrowEntity.cpp b/src/Entities/ArrowEntity.cpp index a3a1667e4..c0e361fea 100644 --- a/src/Entities/ArrowEntity.cpp +++ b/src/Entities/ArrowEntity.cpp @@ -75,12 +75,12 @@ void cArrowEntity::OnHitSolidBlock(const Vector3d & a_HitPos, eBlockFace a_HitFa { if (GetSpeed().EqualsEps(Vector3d(0, 0, 0), 0.0000001)) { - SetSpeed(GetLookVector().NormalizeCopy() * 0.1); // Ensure that no division by zero happens later + SetSpeed(GetLookVector().NormalizeCopy() * 0.1); // Ensure that no division by zero happens later } Vector3d Hit = a_HitPos; Vector3d SinkMovement = (GetSpeed() / 1000); - Hit += SinkMovement * (0.0005 / SinkMovement.Length()); // Make arrow sink into block a centimetre so it lodges (but not to far so it goes black clientside) + Hit += SinkMovement * (0.0005 / SinkMovement.Length()); // Make arrow sink into block a centimetre so it lodges (but not to far so it goes black clientside) super::OnHitSolidBlock(Hit, a_HitFace); Vector3i BlockHit = Hit.Floor(); @@ -166,9 +166,9 @@ void cArrowEntity::Tick(float a_Dt, cChunk & a_Chunk) // We can afford to do this because xoft's algorithm for trajectory is near perfect, so things are pretty close anyway without sync // Besides, this seems to be what the vanilla server does, note how arrows teleport half a second after they hit to the server position - if (!m_HasTeleported) // Sent a teleport already, don't do again + if (!m_HasTeleported) // Sent a teleport already, don't do again { - if (m_HitGroundTimer > 500.f) // Send after half a second, could be less, but just in case + if (m_HitGroundTimer > 500.f) // Send after half a second, could be less, but just in case { m_World->BroadcastTeleportEntity(*this); m_HasTeleported = true; @@ -189,9 +189,9 @@ void cArrowEntity::Tick(float a_Dt, cChunk & a_Chunk) return; } - if (Chunk->GetBlock(RelPosX, m_HitBlockPos.y, RelPosZ) == E_BLOCK_AIR) // Block attached to was destroyed? + if (Chunk->GetBlock(RelPosX, m_HitBlockPos.y, RelPosZ) == E_BLOCK_AIR) // Block attached to was destroyed? { - m_IsInGround = false; // Yes, begin simulating physics again + m_IsInGround = false; // Yes, begin simulating physics again } } } diff --git a/src/Entities/ArrowEntity.h b/src/Entities/ArrowEntity.h index 76cb24449..ad93dba6c 100644 --- a/src/Entities/ArrowEntity.h +++ b/src/Entities/ArrowEntity.h @@ -99,4 +99,4 @@ protected: virtual void CollectedBy(cPlayer * a_Player) override; virtual void Tick(float a_Dt, cChunk & a_Chunk) override; -}; // tolua_export +}; // tolua_export diff --git a/src/Entities/Boat.cpp b/src/Entities/Boat.cpp index 31bfe3dc3..2e9e77b44 100644 --- a/src/Entities/Boat.cpp +++ b/src/Entities/Boat.cpp @@ -94,7 +94,7 @@ void cBoat::Tick(float a_Dt, cChunk & a_Chunk) super::Tick(a_Dt, a_Chunk); BroadcastMovementUpdate(); - SetSpeed(GetSpeed() * 0.97); // Slowly decrease the speed + SetSpeed(GetSpeed() * 0.97); // Slowly decrease the speed if ((POSY_TOINT < 0) || (POSY_TOINT > cChunkDef::Height)) { diff --git a/src/Entities/Entity.cpp b/src/Entities/Entity.cpp index c6dc1fca3..0a85537bf 100644 --- a/src/Entities/Entity.cpp +++ b/src/Entities/Entity.cpp @@ -272,7 +272,7 @@ void cEntity::SetYawFromSpeed(void) void cEntity::SetPitchFromSpeed(void) { const double EPS = 0.0000001; - double xz = sqrt(m_Speed.x * m_Speed.x + m_Speed.z * m_Speed.z); // Speed XZ-plane component + double xz = sqrt(m_Speed.x * m_Speed.x + m_Speed.z * m_Speed.z); // Speed XZ-plane component if ((abs(xz) < EPS) && (abs(m_Speed.y) < EPS)) { // atan2() may overflow or is undefined, pick any number @@ -316,7 +316,7 @@ bool cEntity::DoTakeDamage(TakeDamageInfo & a_TDI) if ((a_TDI.DamageType == dtAttack) || (a_TDI.DamageType == dtArrowAttack)) { a_TDI.FinalDamage += 2; - m_World->BroadcastEntityAnimation(*this, 4); // Critical hit + m_World->BroadcastEntityAnimation(*this, 4); // Critical hit } } @@ -332,7 +332,7 @@ bool cEntity::DoTakeDamage(TakeDamageInfo & a_TDI) m_Health = 0; } - if ((IsMob() || IsPlayer()) && (a_TDI.Attacker != NULL)) // Knockback for only players and mobs + if ((IsMob() || IsPlayer()) && (a_TDI.Attacker != NULL)) // Knockback for only players and mobs { int KnockbackLevel = 0; if (a_TDI.Attacker->GetEquippedWeapon().m_ItemType == E_ITEM_BOW) @@ -767,11 +767,11 @@ void cEntity::HandlePhysics(float a_Dt, cChunk & a_Chunk) NextSpeed.x *= 0.25; NextSpeed.z *= 0.25; } - - //Get water direction + + // Get water direction Direction WaterDir = m_World->GetWaterSimulator()->GetFlowingDirection(BlockX, BlockY, BlockZ); - m_WaterSpeed *= 0.9f; //Reduce speed each tick + m_WaterSpeed *= 0.9f; // Reduce speed each tick switch(WaterDir) { @@ -828,7 +828,7 @@ void cEntity::HandlePhysics(float a_Dt, cChunk & a_Chunk) if (Tracer.HitNormal.y != 0.f) NextSpeed.y = 0.f; if (Tracer.HitNormal.z != 0.f) NextSpeed.z = 0.f; - if (Tracer.HitNormal.y == 1) // Hit BLOCK_FACE_YP, we are on the ground + if (Tracer.HitNormal.y == 1) // Hit BLOCK_FACE_YP, we are on the ground { m_bOnGround = true; } @@ -1095,9 +1095,9 @@ void cEntity::HandleAir(void) if (IsSubmerged()) { - if (!IsPlayer()) // Players control themselves + if (!IsPlayer()) // Players control themselves { - SetSpeedY(1); // Float in the water + SetSpeedY(1); // Float in the water } // Either reduce air level or damage player @@ -1266,9 +1266,9 @@ void cEntity::BroadcastMovementUpdate(const cClientHandle * a_Exclude) int DiffY = (int)(floor(GetPosY() * 32.0) - floor(m_LastPos.y * 32.0)); int DiffZ = (int)(floor(GetPosZ() * 32.0) - floor(m_LastPos.z * 32.0)); - if ((DiffX != 0) || (DiffY != 0) || (DiffZ != 0)) // Have we moved? + if ((DiffX != 0) || (DiffY != 0) || (DiffZ != 0)) // Have we moved? { - if ((abs(DiffX) <= 127) && (abs(DiffY) <= 127) && (abs(DiffZ) <= 127)) // Limitations of a Byte + if ((abs(DiffX) <= 127) && (abs(DiffY) <= 127) && (abs(DiffZ) <= 127)) // Limitations of a Byte { // Difference within Byte limitations, use a relative move packet if (m_bDirtyOrientation) @@ -1288,7 +1288,7 @@ void cEntity::BroadcastMovementUpdate(const cClientHandle * a_Exclude) { // Too big a movement, do a teleport m_World->BroadcastTeleportEntity(*this, a_Exclude); - m_LastPos = GetPosition(); // See above + m_LastPos = GetPosition(); // See above m_bDirtyOrientation = false; } } @@ -1587,7 +1587,7 @@ void cEntity::SteerVehicle(float a_Forward, float a_Sideways) -////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // Get look vector (this is NOT a rotation!) Vector3d cEntity::GetLookVector(void) const { @@ -1601,7 +1601,7 @@ Vector3d cEntity::GetLookVector(void) const -////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // Set position void cEntity::SetPosition(double a_PosX, double a_PosY, double a_PosZ) { diff --git a/src/Entities/Entity.h b/src/Entities/Entity.h index ea44c2722..011293233 100644 --- a/src/Entities/Entity.h +++ b/src/Entities/Entity.h @@ -506,7 +506,7 @@ protected: overrides can provide further processing, such as forcing players to move at the given speed. */ virtual void DoSetSpeed(double a_SpeedX, double a_SpeedY, double a_SpeedZ); - virtual void Destroyed(void) {} // Called after the entity has been destroyed + virtual void Destroyed(void) {} // Called after the entity has been destroyed /** Called in each tick to handle air-related processing i.e. drowning */ virtual void HandleAir(void); diff --git a/src/Entities/EntityEffect.cpp b/src/Entities/EntityEffect.cpp index 4da7cac85..6c4b13a58 100644 --- a/src/Entities/EntityEffect.cpp +++ b/src/Entities/EntityEffect.cpp @@ -108,7 +108,7 @@ void cEntityEffect::OnTick(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectInstantHealth: void cEntityEffectInstantHealth::OnActivate(cPawn & a_Target) @@ -128,7 +128,7 @@ void cEntityEffectInstantHealth::OnActivate(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectInstantDamage: void cEntityEffectInstantDamage::OnActivate(cPawn & a_Target) @@ -148,7 +148,7 @@ void cEntityEffectInstantDamage::OnActivate(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectRegeneration: void cEntityEffectRegeneration::OnTick(cPawn & a_Target) @@ -175,7 +175,7 @@ void cEntityEffectRegeneration::OnTick(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectHunger: void cEntityEffectHunger::OnTick(cPawn & a_Target) @@ -193,7 +193,7 @@ void cEntityEffectHunger::OnTick(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectWeakness: void cEntityEffectWeakness::OnTick(cPawn & a_Target) @@ -211,7 +211,7 @@ void cEntityEffectWeakness::OnTick(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectPoison: void cEntityEffectPoison::OnTick(cPawn & a_Target) @@ -250,7 +250,7 @@ void cEntityEffectPoison::OnTick(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectWither: void cEntityEffectWither::OnTick(cPawn & a_Target) @@ -270,7 +270,7 @@ void cEntityEffectWither::OnTick(cPawn & a_Target) -///////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cEntityEffectSaturation: void cEntityEffectSaturation::OnTick(cPawn & a_Target) diff --git a/src/Entities/ExpBottleEntity.h b/src/Entities/ExpBottleEntity.h index b2043d8f1..e9536452c 100644 --- a/src/Entities/ExpBottleEntity.h +++ b/src/Entities/ExpBottleEntity.h @@ -30,4 +30,4 @@ protected: // cProjectileEntity overrides: virtual void OnHitSolidBlock(const Vector3d & a_HitPos, eBlockFace a_HitFace) override; -}; // tolua_export +}; // tolua_export diff --git a/src/Entities/FireChargeEntity.h b/src/Entities/FireChargeEntity.h index 3924c337c..42ecc7d74 100644 --- a/src/Entities/FireChargeEntity.h +++ b/src/Entities/FireChargeEntity.h @@ -33,4 +33,4 @@ protected: virtual void OnHitSolidBlock(const Vector3d & a_HitPos, eBlockFace a_HitFace) override; virtual void OnHitEntity(cEntity & a_EntityHit, const Vector3d & a_HitPos) override; -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/FireworkEntity.h b/src/Entities/FireworkEntity.h index c62ca9402..7dbdc49e1 100644 --- a/src/Entities/FireworkEntity.h +++ b/src/Entities/FireworkEntity.h @@ -37,4 +37,4 @@ private: int m_ExplodeTimer; cItem m_FireworkItem; -}; // tolua_export +}; // tolua_export diff --git a/src/Entities/Floater.cpp b/src/Entities/Floater.cpp index d49893020..159429147 100644 --- a/src/Entities/Floater.cpp +++ b/src/Entities/Floater.cpp @@ -11,7 +11,7 @@ -/////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cFloaterEntityCollisionCallback class cFloaterEntityCollisionCallback : public cEntityCallback @@ -75,7 +75,7 @@ protected: -/////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cFloaterCheckEntityExist class cFloaterCheckEntityExist : public cEntityCallback @@ -130,7 +130,7 @@ void cFloater::Tick(float a_Dt, cChunk & a_Chunk) HandlePhysics(a_Dt, a_Chunk); if (IsBlockWater(m_World->GetBlock((int) GetPosX(), (int) GetPosY(), (int) GetPosZ())) && m_World->GetBlockMeta((int) GetPosX(), (int) GetPosY(), (int) GetPosZ()) == 0) { - if ((!m_CanPickupItem) && (m_AttachedMobID == -1)) // Check if you can't already pickup a fish and if the floater isn't attached to a mob. + if ((!m_CanPickupItem) && (m_AttachedMobID == -1)) // Check if you can't already pickup a fish and if the floater isn't attached to a mob. { if (m_CountDownTime <= 0) { @@ -141,7 +141,7 @@ void cFloater::Tick(float a_Dt, cChunk & a_Chunk) m_CountDownTime = 100 + m_World->GetTickRandomNumber(800); LOGD("Floater %i can be picked up", GetUniqueID()); } - else if (m_CountDownTime == 20) // Calculate the position where the particles should spawn and start producing them. + else if (m_CountDownTime == 20) // Calculate the position where the particles should spawn and start producing them. { LOGD("Started producing particles for floater %i", GetUniqueID()); m_ParticlePos.Set(GetPosX() + (-4 + m_World->GetTickRandomNumber(8)), GetPosY(), GetPosZ() + (-4 + m_World->GetTickRandomNumber(8))); @@ -156,12 +156,12 @@ void cFloater::Tick(float a_Dt, cChunk & a_Chunk) m_CountDownTime--; if (m_World->GetHeight((int) GetPosX(), (int) GetPosZ()) == (int) GetPosY()) { - if (m_World->IsWeatherWet() && m_World->GetTickRandomNumber(3) == 0) // 25% chance of an extra countdown when being rained on. + if (m_World->IsWeatherWet() && m_World->GetTickRandomNumber(3) == 0) // 25% chance of an extra countdown when being rained on. { m_CountDownTime--; } } - else // if the floater is underground it has a 50% chance of not decreasing the countdown. + else // if the floater is underground it has a 50% chance of not decreasing the countdown. { if (m_World->GetTickRandomNumber(1) == 0) { @@ -190,21 +190,21 @@ void cFloater::Tick(float a_Dt, cChunk & a_Chunk) if (Callback.HasHit()) { AttachTo(Callback.GetHitEntity()); - Callback.GetHitEntity()->TakeDamage(*this); // TODO: the player attacked the mob not the floater. + Callback.GetHitEntity()->TakeDamage(*this); // TODO: the player attacked the mob not the floater. m_AttachedMobID = Callback.GetHitEntity()->GetUniqueID(); } } cFloaterCheckEntityExist EntityCallback; m_World->DoWithEntityByID(m_PlayerID, EntityCallback); - if (!EntityCallback.DoesExist()) // The owner doesn't exist anymore. Destroy the floater entity. + if (!EntityCallback.DoesExist()) // The owner doesn't exist anymore. Destroy the floater entity. { Destroy(true); } if (m_AttachedMobID != -1) { - m_World->DoWithEntityByID(m_AttachedMobID, EntityCallback); // The mob the floater was attached to doesn't exist anymore. + m_World->DoWithEntityByID(m_AttachedMobID, EntityCallback); // The mob the floater was attached to doesn't exist anymore. if (!EntityCallback.DoesExist()) { m_AttachedMobID = -1; diff --git a/src/Entities/Floater.h b/src/Entities/Floater.h index 547d503f1..5d2720b6a 100644 --- a/src/Entities/Floater.h +++ b/src/Entities/Floater.h @@ -14,7 +14,7 @@ class cFloater : typedef cEntity super; public: - //tolua_end + // tolua_end CLASS_PROTODEF(cFloater); @@ -43,4 +43,4 @@ protected: // Entity IDs int m_PlayerID; int m_AttachedMobID; -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/GhastFireballEntity.h b/src/Entities/GhastFireballEntity.h index 9e4572c78..fa59fa642 100644 --- a/src/Entities/GhastFireballEntity.h +++ b/src/Entities/GhastFireballEntity.h @@ -35,4 +35,4 @@ protected: // TODO: Deflecting the fireballs by arrow- or sword- hits -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/HangingEntity.cpp b/src/Entities/HangingEntity.cpp index 41ac86268..d7a7ba943 100644 --- a/src/Entities/HangingEntity.cpp +++ b/src/Entities/HangingEntity.cpp @@ -28,14 +28,14 @@ void cHangingEntity::SpawnOn(cClientHandle & a_ClientHandle) // The client uses different values for item frame directions and block faces. Our constants are for the block faces, so we convert them here to item frame faces switch (m_BlockFace) { - case BLOCK_FACE_ZP: break; // Initialised to zero + case BLOCK_FACE_ZP: break; // Initialised to zero case BLOCK_FACE_ZM: Dir = 2; break; case BLOCK_FACE_XM: Dir = 1; break; case BLOCK_FACE_XP: Dir = 3; break; default: ASSERT(!"Unhandled block face when trying to spawn item frame!"); return; } - if ((Dir == 0) || (Dir == 2)) // Probably a client bug, but two directions are flipped and contrary to the norm, so we do -180 + if ((Dir == 0) || (Dir == 2)) // Probably a client bug, but two directions are flipped and contrary to the norm, so we do -180 { SetYaw((Dir * 90) - 180); } diff --git a/src/Entities/ItemFrame.cpp b/src/Entities/ItemFrame.cpp index 4cd707faa..144c6d5aa 100644 --- a/src/Entities/ItemFrame.cpp +++ b/src/Entities/ItemFrame.cpp @@ -43,7 +43,7 @@ void cItemFrame::OnRightClicked(cPlayer & a_Player) } } - GetWorld()->BroadcastEntityMetadata(*this); // Update clients + GetWorld()->BroadcastEntityMetadata(*this); // Update clients } diff --git a/src/Entities/Minecart.cpp b/src/Entities/Minecart.cpp index 7bd440d6d..6502ae45a 100644 --- a/src/Entities/Minecart.cpp +++ b/src/Entities/Minecart.cpp @@ -117,7 +117,7 @@ void cMinecart::SpawnOn(cClientHandle & a_ClientHandle) return; } } - a_ClientHandle.SendSpawnVehicle(*this, 10, SubType); // 10 = Minecarts, SubType = What type of Minecart + a_ClientHandle.SendSpawnVehicle(*this, 10, SubType); // 10 = Minecarts, SubType = What type of Minecart a_ClientHandle.SendEntityMetadata(*this); } @@ -127,7 +127,7 @@ void cMinecart::SpawnOn(cClientHandle & a_ClientHandle) void cMinecart::HandlePhysics(float a_Dt, cChunk & a_Chunk) { - if (IsDestroyed()) // Mainly to stop detector rails triggering again after minecart is dead + if (IsDestroyed()) // Mainly to stop detector rails triggering again after minecart is dead { return; } @@ -156,8 +156,8 @@ void cMinecart::HandlePhysics(float a_Dt, cChunk & a_Chunk) if (!IsBlockRail(InsideType)) { - Chunk->GetBlockTypeMeta(RelPosX, PosY + 1, RelPosZ, InsideType, InsideMeta); // When an descending minecart hits a flat rail, it goes through the ground; check for this - if (IsBlockRail(InsideType)) AddPosY(1); // Push cart upwards + Chunk->GetBlockTypeMeta(RelPosX, PosY + 1, RelPosZ, InsideType, InsideMeta); // When an descending minecart hits a flat rail, it goes through the ground; check for this + if (IsBlockRail(InsideType)) AddPosY(1); // Push cart upwards } bool WasDetectorRail = false; @@ -186,12 +186,12 @@ void cMinecart::HandlePhysics(float a_Dt, cChunk & a_Chunk) default: VERIFY(!"Unhandled rail type despite checking if block was rail!"); break; } - AddPosition(GetSpeed() * (a_Dt / 1000)); // Commit changes; as we use our own engine when on rails, this needs to be done, whereas it is normally in Entity.cpp + AddPosition(GetSpeed() * (a_Dt / 1000)); // Commit changes; as we use our own engine when on rails, this needs to be done, whereas it is normally in Entity.cpp } else { // Not on rail, default physics - SetPosY(floor(GetPosY()) + 0.35); // HandlePhysics overrides this if minecart can fall, else, it is to stop ground clipping minecart bottom when off-rail + SetPosY(floor(GetPosY()) + 0.35); // HandlePhysics overrides this if minecart can fall, else, it is to stop ground clipping minecart bottom when off-rail super::HandlePhysics(a_Dt, *Chunk); } @@ -223,18 +223,18 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) switch (a_RailMeta) { - case E_META_RAIL_ZM_ZP: // NORTHSOUTH + case E_META_RAIL_ZM_ZP: // NORTHSOUTH { SetYaw(270); SetPosY(floor(GetPosY()) + 0.55); - SetSpeedY(0); // Don't move vertically as on ground - SetSpeedX(0); // Correct diagonal movement from curved rails + SetSpeedY(0); // Don't move vertically as on ground + SetSpeedX(0); // Correct diagonal movement from curved rails // Execute both the entity and block collision checks bool BlckCol = TestBlockCollision(a_RailMeta), EntCol = TestEntityCollision(a_RailMeta); if (EntCol || BlckCol) return; - if (GetSpeedZ() != 0) // Don't do anything if cart is stationary + if (GetSpeedZ() != 0) // Don't do anything if cart is stationary { if (GetSpeedZ() > 0) { @@ -249,7 +249,7 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) } break; } - case E_META_RAIL_XM_XP: // EASTWEST + case E_META_RAIL_XM_XP: // EASTWEST { SetYaw(180); SetPosY(floor(GetPosY()) + 0.55); @@ -272,7 +272,7 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) } break; } - case E_META_RAIL_ASCEND_ZM: // ASCEND NORTH + case E_META_RAIL_ASCEND_ZM: // ASCEND NORTH { SetYaw(270); SetSpeedX(0); @@ -280,21 +280,21 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) if (GetSpeedZ() >= 0) { // SpeedZ POSITIVE, going SOUTH - if (GetSpeedZ() <= MAX_SPEED) // Speed limit + if (GetSpeedZ() <= MAX_SPEED) // Speed limit { - AddSpeedZ(0.5); // Speed up - SetSpeedY(-GetSpeedZ()); // Downward movement is negative (0 minus positive numbers is negative) + AddSpeedZ(0.5); // Speed up + SetSpeedY(-GetSpeedZ()); // Downward movement is negative (0 minus positive numbers is negative) } } else { // SpeedZ NEGATIVE, going NORTH - AddSpeedZ(1); // Slow down - SetSpeedY(-GetSpeedZ()); // Upward movement is positive (0 minus negative number is positive number) + AddSpeedZ(1); // Slow down + SetSpeedY(-GetSpeedZ()); // Upward movement is positive (0 minus negative number is positive number) } break; } - case E_META_RAIL_ASCEND_ZP: // ASCEND SOUTH + case E_META_RAIL_ASCEND_ZP: // ASCEND SOUTH { SetYaw(270); SetSpeedX(0); @@ -302,21 +302,21 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) if (GetSpeedZ() > 0) { // SpeedZ POSITIVE, going SOUTH - AddSpeedZ(-1); // Slow down - SetSpeedY(GetSpeedZ()); // Upward movement positive + AddSpeedZ(-1); // Slow down + SetSpeedY(GetSpeedZ()); // Upward movement positive } else { - if (GetSpeedZ() >= MAX_SPEED_NEGATIVE) // Speed limit + if (GetSpeedZ() >= MAX_SPEED_NEGATIVE) // Speed limit { // SpeedZ NEGATIVE, going NORTH - AddSpeedZ(-0.5); // Speed up - SetSpeedY(GetSpeedZ()); // Downward movement negative + AddSpeedZ(-0.5); // Speed up + SetSpeedY(GetSpeedZ()); // Downward movement negative } } break; } - case E_META_RAIL_ASCEND_XM: // ASCEND EAST + case E_META_RAIL_ASCEND_XM: // ASCEND EAST { SetYaw(180); SetSpeedZ(0); @@ -336,7 +336,7 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) } break; } - case E_META_RAIL_ASCEND_XP: // ASCEND WEST + case E_META_RAIL_ASCEND_XP: // ASCEND WEST { SetYaw(180); SetSpeedZ(0); @@ -356,10 +356,10 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) } break; } - case E_META_RAIL_CURVED_ZM_XM: // Ends pointing NORTH and WEST + case E_META_RAIL_CURVED_ZM_XM: // Ends pointing NORTH and WEST { - SetYaw(315); // Set correct rotation server side - SetPosY(floor(GetPosY()) + 0.55); // Levitate dat cart + SetYaw(315); // Set correct rotation server side + SetPosY(floor(GetPosY()) + 0.55); // Levitate dat cart SetSpeedY(0); TestBlockCollision(a_RailMeta); @@ -369,7 +369,7 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) break; } - case E_META_RAIL_CURVED_ZM_XP: // Curved NORTH EAST + case E_META_RAIL_CURVED_ZM_XP: // Curved NORTH EAST { SetYaw(225); SetPosY(floor(GetPosY()) + 0.55); @@ -380,7 +380,7 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) break; } - case E_META_RAIL_CURVED_ZP_XM: // Curved SOUTH WEST + case E_META_RAIL_CURVED_ZP_XM: // Curved SOUTH WEST { SetYaw(135); SetPosY(floor(GetPosY()) + 0.55); @@ -391,7 +391,7 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) break; } - case E_META_RAIL_CURVED_ZP_XP: // Curved SOUTH EAST + case E_META_RAIL_CURVED_ZP_XP: // Curved SOUTH EAST { SetYaw(45); SetPosY(floor(GetPosY()) + 0.55); @@ -404,7 +404,7 @@ void cMinecart::HandleRailPhysics(NIBBLETYPE a_RailMeta, float a_Dt) } default: { - ASSERT(!"Unhandled rail meta!"); // Dun dun DUN! + ASSERT(!"Unhandled rail meta!"); // Dun dun DUN! break; } } @@ -428,7 +428,7 @@ void cMinecart::HandlePoweredRailPhysics(NIBBLETYPE a_RailMeta) switch (a_RailMeta & 0x07) { - case E_META_RAIL_ZM_ZP: // NORTHSOUTH + case E_META_RAIL_ZM_ZP: // NORTHSOUTH { SetYaw(270); SetPosY(floor(GetPosY()) + 0.55); @@ -451,7 +451,7 @@ void cMinecart::HandlePoweredRailPhysics(NIBBLETYPE a_RailMeta) } break; } - case E_META_RAIL_XM_XP: // EASTWEST + case E_META_RAIL_XM_XP: // EASTWEST { SetYaw(180); SetPosY(floor(GetPosY()) + 0.55); @@ -474,7 +474,7 @@ void cMinecart::HandlePoweredRailPhysics(NIBBLETYPE a_RailMeta) } break; } - case E_META_RAIL_ASCEND_XM: // ASCEND EAST + case E_META_RAIL_ASCEND_XM: // ASCEND EAST { SetYaw(180); SetSpeedZ(0); @@ -494,7 +494,7 @@ void cMinecart::HandlePoweredRailPhysics(NIBBLETYPE a_RailMeta) } break; } - case E_META_RAIL_ASCEND_XP: // ASCEND WEST + case E_META_RAIL_ASCEND_XP: // ASCEND WEST { SetYaw(180); SetSpeedZ(0); @@ -514,7 +514,7 @@ void cMinecart::HandlePoweredRailPhysics(NIBBLETYPE a_RailMeta) } break; } - case E_META_RAIL_ASCEND_ZM: // ASCEND NORTH + case E_META_RAIL_ASCEND_ZM: // ASCEND NORTH { SetYaw(270); SetSpeedX(0); @@ -534,7 +534,7 @@ void cMinecart::HandlePoweredRailPhysics(NIBBLETYPE a_RailMeta) } break; } - case E_META_RAIL_ASCEND_ZP: // ASCEND SOUTH + case E_META_RAIL_ASCEND_ZP: // ASCEND SOUTH { SetYaw(270); SetSpeedX(0); @@ -907,7 +907,7 @@ bool cMinecart::DoTakeDamage(TakeDamageInfo & TDI) if ((TDI.Attacker != NULL) && TDI.Attacker->IsPlayer() && ((cPlayer *)TDI.Attacker)->IsGameModeCreative()) { Destroy(); - TDI.FinalDamage = GetMaxHealth(); // Instant hit for creative + TDI.FinalDamage = GetMaxHealth(); // Instant hit for creative SetInvulnerableTicks(0); return super::DoTakeDamage(TDI); // No drops for creative } @@ -980,7 +980,7 @@ void cMinecart::Destroyed() -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cRideableMinecart: cRideableMinecart::cRideableMinecart(double a_X, double a_Y, double a_Z, const cItem & a_Content, int a_Height) : @@ -1023,7 +1023,7 @@ void cRideableMinecart::OnRightClicked(cPlayer & a_Player) -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cMinecartWithChest: cMinecartWithChest::cMinecartWithChest(double a_X, double a_Y, double a_Z) : @@ -1056,7 +1056,7 @@ void cMinecartWithChest::OnRightClicked(cPlayer & a_Player) -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cMinecartWithFurnace: cMinecartWithFurnace::cMinecartWithFurnace(double a_X, double a_Y, double a_Z) : @@ -1078,12 +1078,12 @@ void cMinecartWithFurnace::OnRightClicked(cPlayer & a_Player) { a_Player.GetInventory().RemoveOneEquippedItem(); } - if (!m_IsFueled) // We don't want to change the direction by right clicking it. + if (!m_IsFueled) // We don't want to change the direction by right clicking it. { AddSpeed(a_Player.GetLookVector().x, 0, a_Player.GetLookVector().z); } m_IsFueled = true; - m_FueledTimeLeft = m_FueledTimeLeft + 600; // The minecart will be active 600 more ticks. + m_FueledTimeLeft = m_FueledTimeLeft + 600; // The minecart will be active 600 more ticks. m_World->BroadcastEntityMetadata(*this); } } @@ -1118,7 +1118,7 @@ void cMinecartWithFurnace::Tick(float a_Dt, cChunk & a_Chunk) -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cMinecartWithTNT: cMinecartWithTNT::cMinecartWithTNT(double a_X, double a_Y, double a_Z) : @@ -1132,7 +1132,7 @@ cMinecartWithTNT::cMinecartWithTNT(double a_X, double a_Y, double a_Z) : -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cMinecartWithHopper: cMinecartWithHopper::cMinecartWithHopper(double a_X, double a_Y, double a_Z) : diff --git a/src/Entities/Painting.h b/src/Entities/Painting.h index 30af6d412..ce7c6f3de 100644 --- a/src/Entities/Painting.h +++ b/src/Entities/Painting.h @@ -18,8 +18,8 @@ public: CLASS_PROTODEF(cPainting); cPainting(const AString & a_Name, int a_Direction, double a_X, double a_Y, double a_Z); - const AString & GetName(void) const { return m_Name; } // tolua_export - int GetDirection(void) const { return m_Direction; } // tolua_export + const AString & GetName(void) const { return m_Name; } // tolua_export + int GetDirection(void) const { return m_Direction; } // tolua_export private: diff --git a/src/Entities/Pickup.cpp b/src/Entities/Pickup.cpp index bae1485d4..ab0f856dd 100644 --- a/src/Entities/Pickup.cpp +++ b/src/Entities/Pickup.cpp @@ -113,7 +113,7 @@ void cPickup::SpawnOn(cClientHandle & a_Client) void cPickup::Tick(float a_Dt, cChunk & a_Chunk) { super::Tick(a_Dt, a_Chunk); - BroadcastMovementUpdate(); //Notify clients of position + BroadcastMovementUpdate(); // Notify clients of position m_Timer += a_Dt; @@ -150,10 +150,10 @@ void cPickup::Tick(float a_Dt, cChunk & a_Chunk) } } - if (!IsDestroyed() && (m_Item.m_ItemCount < m_Item.GetMaxStackSize())) // Don't combine into an already full pickup + if (!IsDestroyed() && (m_Item.m_ItemCount < m_Item.GetMaxStackSize())) // Don't combine into an already full pickup { cPickupCombiningCallback PickupCombiningCallback(GetPosition(), this); - m_World->ForEachEntity(PickupCombiningCallback); // Not ForEachEntityInChunk, otherwise pickups don't combine across chunk boundaries + m_World->ForEachEntity(PickupCombiningCallback); // Not ForEachEntityInChunk, otherwise pickups don't combine across chunk boundaries if (PickupCombiningCallback.FoundMatchingPickup()) { m_World->BroadcastEntityMetadata(*this); @@ -176,7 +176,7 @@ void cPickup::Tick(float a_Dt, cChunk & a_Chunk) return; } - if (GetPosY() < VOID_BOUNDARY) // Out of this world and no more visible! + if (GetPosY() < VOID_BOUNDARY) // Out of this world and no more visible! { Destroy(true); return; @@ -194,14 +194,14 @@ bool cPickup::CollectedBy(cPlayer * a_Dest) if (m_bCollected) { // LOG("Pickup %d cannot be collected by \"%s\", because it has already been collected.", m_UniqueID, a_Dest->GetName().c_str()); - return false; // It's already collected! + return false; // It's already collected! } // Two seconds if player created the pickup (vomiting), half a second if anything else if (m_Timer < (m_bIsPlayerCreated ? 2000.f : 500.f)) { // LOG("Pickup %d cannot be collected by \"%s\", because it is not old enough.", m_UniqueID, a_Dest->GetName().c_str()); - return false; // Not old enough + return false; // Not old enough } if (cRoot::Get()->GetPluginManager()->CallHookCollectingPickup(a_Dest, *this)) diff --git a/src/Entities/Pickup.h b/src/Entities/Pickup.h index 2dcbecaaf..d50941280 100644 --- a/src/Entities/Pickup.h +++ b/src/Entities/Pickup.h @@ -27,7 +27,7 @@ public: cPickup(double a_PosX, double a_PosY, double a_PosZ, const cItem & a_Item, bool IsPlayerCreated, float a_SpeedX = 0.f, float a_SpeedY = 0.f, float a_SpeedZ = 0.f); - cItem & GetItem(void) {return m_Item; } // tolua_export + cItem & GetItem(void) {return m_Item; } // tolua_export const cItem & GetItem(void) const {return m_Item; } virtual void SpawnOn(cClientHandle & a_ClientHandle) override; @@ -46,7 +46,7 @@ public: bool IsCollected(void) const { return m_bCollected; } // tolua_export /** Returns true if created by player (i.e. vomiting), used for determining picking-up delay time */ - bool IsPlayerCreated(void) const { return m_bIsPlayerCreated; } // tolua_export + bool IsPlayerCreated(void) const { return m_bIsPlayerCreated; } // tolua_export private: diff --git a/src/Entities/Player.cpp b/src/Entities/Player.cpp index da50843b6..c4f9c59ab 100644 --- a/src/Entities/Player.cpp +++ b/src/Entities/Player.cpp @@ -223,7 +223,7 @@ void cPlayer::Tick(float a_Dt, cChunk & a_Chunk) SendExperience(); } - if (!GetPosition().EqualsEps(m_LastPos, 0.01)) // Non negligible change in position from last tick? + if (!GetPosition().EqualsEps(m_LastPos, 0.01)) // Non negligible change in position from last tick? { // Apply food exhaustion from movement: ApplyFoodExhaustionFromMovement(); @@ -284,19 +284,19 @@ void cPlayer::Tick(float a_Dt, cChunk & a_Chunk) short cPlayer::CalcLevelFromXp(short a_XpTotal) { - //level 0 to 15 + // level 0 to 15 if(a_XpTotal <= XP_TO_LEVEL15) { return a_XpTotal / XP_PER_LEVEL_TO15; } - //level 30+ + // level 30+ if(a_XpTotal > XP_TO_LEVEL30) { return (short) (151.5 + sqrt( 22952.25 - (14 * (2220 - a_XpTotal)))) / 7; } - //level 16 to 30 + // level 16 to 30 return (short) ( 29.5 + sqrt( 870.25 - (6 * ( 360 - a_XpTotal )))) / 3; } @@ -306,19 +306,19 @@ short cPlayer::CalcLevelFromXp(short a_XpTotal) short cPlayer::XpForLevel(short a_Level) { - //level 0 to 15 + // level 0 to 15 if(a_Level <= 15) { return a_Level * XP_PER_LEVEL_TO15; } - //level 30+ + // level 30+ if(a_Level >= 31) { return (short) ( (3.5 * a_Level * a_Level) - (151.5 * a_Level) + 2220 ); } - //level 16 to 30 + // level 16 to 30 return (short) ( (1.5 * a_Level * a_Level) - (29.5 * a_Level) + 360 ); } @@ -353,7 +353,7 @@ bool cPlayer::SetCurrentExperience(short int a_CurrentXp) if(!(a_CurrentXp >= 0) || (a_CurrentXp > (SHRT_MAX - m_LifetimeTotalXp))) { LOGWARNING("Tried to update experiece with an invalid Xp value: %d", a_CurrentXp); - return false; //oops, they gave us a dodgey number + return false; // oops, they gave us a dodgey number } m_CurrentXp = a_CurrentXp; @@ -375,7 +375,7 @@ short cPlayer::DeltaExperience(short a_Xp_delta) // Value was bad, abort and report LOGWARNING("Attempt was made to increment Xp by %d, which overflowed the short datatype. Ignoring.", a_Xp_delta); - return -1; // Should we instead just return the current Xp? + return -1; // Should we instead just return the current Xp? } m_CurrentXp += a_Xp_delta; @@ -477,7 +477,7 @@ void cPlayer::SetTouchGround(bool a_bTouchGround) { float Dist = (float)(m_LastGroundHeight - floor(GetPosY())); - if (Dist >= 2.0) // At least two blocks - TODO: Use m_LastJumpHeight instead of m_LastGroundHeight above + if (Dist >= 2.0) // At least two blocks - TODO: Use m_LastJumpHeight instead of m_LastGroundHeight above { // Increment statistic m_Stats.AddValue(statDistFallen, (StatValue)floor(Dist * 100 + 0.5)); @@ -623,7 +623,7 @@ void cPlayer::FinishEating(void) GetInventory().RemoveOneEquippedItem(); - //if the food is mushroom soup, return a bowl to the inventory + // if the food is mushroom soup, return a bowl to the inventory if( Item.m_ItemType == E_ITEM_MUSHROOM_SOUP ) { cItem emptyBowl(E_ITEM_BOWL, 1, 0, ""); GetInventory().AddItem(emptyBowl, true, true); @@ -871,10 +871,10 @@ void cPlayer::KilledBy(TakeDamageInfo & a_TDI) if (m_Health > 0) { - return; // not dead yet =] + return; // not dead yet =] } - m_bVisible = false; // So new clients don't see the player + m_bVisible = false; // So new clients don't see the player // Puke out all the items cItems Pickups; @@ -925,7 +925,7 @@ void cPlayer::KilledBy(TakeDamageInfo & a_TDI) else { AString KillerClass = a_TDI.Attacker->GetClass(); - KillerClass.erase(KillerClass.begin()); // Erase the 'c' of the class (e.g. "cWitch" -> "Witch") + KillerClass.erase(KillerClass.begin()); // Erase the 'c' of the class (e.g. "cWitch" -> "Witch") GetWorld()->BroadcastChatDeath(Printf("%s was killed by a %s", GetName().c_str(), KillerClass.c_str())); } @@ -1338,7 +1338,7 @@ void cPlayer::MoveTo( const Vector3d & a_NewPos ) void cPlayer::SetVisible(bool a_bVisible) { - if (a_bVisible && !m_bVisible) // Make visible + if (a_bVisible && !m_bVisible) // Make visible { m_bVisible = true; m_World->BroadcastSpawnEntity(*this); @@ -1420,7 +1420,7 @@ bool cPlayer::HasPermission(const AString & a_Permission) { if( OtherSplit[i].compare( Split[i] ) != 0 ) { - if( OtherSplit[i].compare("*") == 0 ) return true; // WildCard man!! WildCard! + if( OtherSplit[i].compare("*") == 0 ) return true; // WildCard man!! WildCard! break; } } @@ -1548,7 +1548,7 @@ void cPlayer::TossEquippedItem(char a_Amount) char NewAmount = a_Amount; if (NewAmount > GetInventory().GetEquippedItem().m_ItemCount) { - NewAmount = GetInventory().GetEquippedItem().m_ItemCount; // Drop only what's there + NewAmount = GetInventory().GetEquippedItem().m_ItemCount; // Drop only what's there } GetInventory().GetHotbarGrid().ChangeSlotCount(GetInventory().GetEquippedSlotNum() /* Returns hotbar subslot, which HotbarGrid takes */, -a_Amount); @@ -1610,7 +1610,7 @@ void cPlayer::TossItems(const cItems & a_Items) double vX = 0, vY = 0, vZ = 0; EulerToVector(-GetYaw(), GetPitch(), vZ, vX, vY); vY = -vY * 2 + 1.f; - m_World->SpawnItemPickups(a_Items, GetPosX(), GetEyeHeight(), GetPosZ(), vX * 3, vY * 3, vZ * 3, true); // 'true' because created by player + m_World->SpawnItemPickups(a_Items, GetPosX(), GetEyeHeight(), GetPosZ(), vX * 3, vY * 3, vZ * 3, true); // 'true' because created by player } @@ -1931,7 +1931,7 @@ cPlayer::StringList cPlayer::GetResolvedPermissions() void cPlayer::UseEquippedItem(void) { - if (IsGameModeCreative()) // No damage in creative + if (IsGameModeCreative()) // No damage in creative { return; } @@ -2074,7 +2074,7 @@ void cPlayer::UpdateMovementStats(const Vector3d & a_DeltaPos) { if (IsClimbing()) { - if (a_DeltaPos.y > 0.0) // Going up + if (a_DeltaPos.y > 0.0) // Going up { m_Stats.AddValue(statDistClimbed, (StatValue)floor(a_DeltaPos.y * 100 + 0.5)); } @@ -2093,7 +2093,7 @@ void cPlayer::UpdateMovementStats(const Vector3d & a_DeltaPos) } else { - if (Value >= 25) // Ignore small/slow movement + if (Value >= 25) // Ignore small/slow movement { m_Stats.AddValue(statDistFlown, Value); } diff --git a/src/Entities/Player.h b/src/Entities/Player.h index 793f11e57..171e9541b 100644 --- a/src/Entities/Player.h +++ b/src/Entities/Player.h @@ -174,7 +174,7 @@ public: AString GetIP(void) const { return m_IP; } // tolua_export /** Returns the associated team, NULL if none */ - cTeam * GetTeam(void) { return m_Team; } // tolua_export + cTeam * GetTeam(void) { return m_Team; } // tolua_export /** Sets the player team, NULL if none */ void SetTeam(cTeam * a_Team); @@ -200,7 +200,7 @@ public: /** Forces the player to move in the given direction. @deprecated Use SetSpeed instead. */ - void ForceSetSpeed(const Vector3d & a_Speed); // tolua_export + void ForceSetSpeed(const Vector3d & a_Speed); // tolua_export /** Tries to move to a new position, with attachment-related checks (y == -999) */ void MoveTo(const Vector3d & a_NewPos); // tolua_export @@ -570,7 +570,7 @@ protected: /** Returns the filename for the player data based on the UUID given. This can be used both for online and offline UUIDs. */ AString GetUUIDFileName(const AString & a_UUID); -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/ProjectileEntity.cpp b/src/Entities/ProjectileEntity.cpp index 019ebeaa5..a55c9b895 100644 --- a/src/Entities/ProjectileEntity.cpp +++ b/src/Entities/ProjectileEntity.cpp @@ -35,7 +35,7 @@ -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cProjectileTracerCallback: class cProjectileTracerCallback : @@ -122,7 +122,7 @@ protected: -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cProjectileEntityCollisionCallback: class cProjectileEntityCollisionCallback : @@ -211,7 +211,7 @@ protected: -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cProjectileEntity: cProjectileEntity::cProjectileEntity(eKind a_Kind, cEntity * a_Creator, double a_X, double a_Y, double a_Z, double a_Width, double a_Height) : diff --git a/src/Entities/ProjectileEntity.h b/src/Entities/ProjectileEntity.h index 14cee1272..7b045de76 100644 --- a/src/Entities/ProjectileEntity.h +++ b/src/Entities/ProjectileEntity.h @@ -120,4 +120,4 @@ protected: virtual void HandlePhysics(float a_Dt, cChunk & a_Chunk) override; virtual void SpawnOn(cClientHandle & a_Client) override; -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/SplashPotionEntity.cpp b/src/Entities/SplashPotionEntity.cpp index ed5afaf11..3efb1f25d 100644 --- a/src/Entities/SplashPotionEntity.cpp +++ b/src/Entities/SplashPotionEntity.cpp @@ -7,7 +7,7 @@ -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cSplashPotionEntityCallback: /** Used to distribute the splashed potion effect among nearby entities */ @@ -63,7 +63,7 @@ private: -/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +//////////////////////////////////////////////////////////////////////////////// // cSplashPotionEntity: cSplashPotionEntity::cSplashPotionEntity( diff --git a/src/Entities/SplashPotionEntity.h b/src/Entities/SplashPotionEntity.h index 076e477da..2c78b55d2 100644 --- a/src/Entities/SplashPotionEntity.h +++ b/src/Entities/SplashPotionEntity.h @@ -56,4 +56,4 @@ protected: /** Splashes the potion, fires its particle effects and sounds @param a_HitPos The position where the potion will splash */ void Splash(const Vector3d & a_HitPos); -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/TNTEntity.h b/src/Entities/TNTEntity.h index 116f5a8cb..df61b14f5 100644 --- a/src/Entities/TNTEntity.h +++ b/src/Entities/TNTEntity.h @@ -38,7 +38,7 @@ public: protected: int m_FuseTicks; ///< How much ticks is left, while the tnt will explode -}; // tolua_export +}; // tolua_export diff --git a/src/Entities/ThrownEggEntity.h b/src/Entities/ThrownEggEntity.h index dc72c279f..f93731256 100644 --- a/src/Entities/ThrownEggEntity.h +++ b/src/Entities/ThrownEggEntity.h @@ -55,4 +55,4 @@ private: /** Time in ticks to wait for the hit animation to begin before destroying */ int m_DestroyTimer; -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/ThrownEnderPearlEntity.h b/src/Entities/ThrownEnderPearlEntity.h index 1cea5f7d9..549d8a3eb 100644 --- a/src/Entities/ThrownEnderPearlEntity.h +++ b/src/Entities/ThrownEnderPearlEntity.h @@ -55,4 +55,4 @@ private: /** Time in ticks to wait for the hit animation to begin before destroying */ int m_DestroyTimer; -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/ThrownSnowballEntity.h b/src/Entities/ThrownSnowballEntity.h index 9a8770379..6f3efdd7e 100644 --- a/src/Entities/ThrownSnowballEntity.h +++ b/src/Entities/ThrownSnowballEntity.h @@ -52,4 +52,4 @@ private: /** Time in ticks to wait for the hit animation to begin before destroying */ int m_DestroyTimer; -} ; // tolua_export +} ; // tolua_export diff --git a/src/Entities/WitherSkullEntity.h b/src/Entities/WitherSkullEntity.h index 8b3639802..ebc1550e3 100644 --- a/src/Entities/WitherSkullEntity.h +++ b/src/Entities/WitherSkullEntity.h @@ -32,4 +32,4 @@ protected: virtual void OnHitSolidBlock(const Vector3d & a_HitPos, eBlockFace a_HitFace) override; virtual void OnHitEntity (cEntity & a_EntityHit, const Vector3d & a_HitPos) override; -} ; // tolua_export +} ; // tolua_export |