From 864bdd2626fbbdca10d1ddfe934334c41ccc3571 Mon Sep 17 00:00:00 2001 From: James Ravenscroft Date: Thu, 8 Aug 2013 11:01:45 +0100 Subject: Made comments more readable by adding space between // and text content. Added /// doxygen syntax comments to declarations --- source/Player.cpp | 14 +++++++------- source/Player.h | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) (limited to 'source') diff --git a/source/Player.cpp b/source/Player.cpp index 21f31c555..fb752ed87 100644 --- a/source/Player.cpp +++ b/source/Player.cpp @@ -1322,8 +1322,8 @@ void cPlayer::UseEquippedItem() void cPlayer::HandleAir(cChunk & a_Chunk) { - //Ref.: http://www.minecraftwiki.net/wiki/Chunk_format - //see if the player is /submerged/ water (block above is water) + // Ref.: http://www.minecraftwiki.net/wiki/Chunk_format + // see if the player is /submerged/ water (block above is water) // Get the type of block the player's standing in: BLOCKTYPE BlockIn; int RelX = (int)floor(m_LastPosX) - a_Chunk.GetPosX() * cChunkDef::Width; @@ -1334,24 +1334,24 @@ void cPlayer::HandleAir(cChunk & a_Chunk) if (IsBlockWater(BlockIn)) { - //either reduce air level or damage player + // either reduce air level or damage player if(m_AirLevel < 1) { if(m_AirTickTimer < 1) { - //damage player + // damage player TakeDamage(dtDrowning, NULL, 1, 1, 0); - //reset timer + // reset timer m_AirTickTimer = DROWNING_TICKS; }else{ m_AirTickTimer -= 1; } }else{ - //reduce air supply + // reduce air supply m_AirLevel -= 1; } }else{ - //set the air back to maximum + // set the air back to maximum m_AirLevel = MAX_AIR_LEVEL; m_AirTickTimer = DROWNING_TICKS; } diff --git a/source/Player.h b/source/Player.h index f1d746318..542656b5a 100644 --- a/source/Player.h +++ b/source/Player.h @@ -271,9 +271,9 @@ protected: std::string m_PlayerName; std::string m_LoadedWorldName; - //Player's air level (for swimming) + /// Player's air level (for swimming) int m_AirLevel; - //used to time ticks between damage taken via drowning/suffocation + /// used to time ticks between damage taken via drowning/suffocation int m_AirTickTimer; bool m_bVisible; -- cgit v1.2.3