summaryrefslogtreecommitdiff
path: root/src/being.cpp
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2009-02-11 00:01:36 +0100
committerBjørn Lindeijer <bjorn@lindeijer.nl>2009-02-11 00:01:36 +0100
commitdbc6444d3086fa1b7afca4605600a0a0ae8ca394 (patch)
tree929a30503728e9f657c9a8820b3a9069b916343e /src/being.cpp
parent8712ce09e8f3a86dcf2f6c8ee7d030e3b41a4618 (diff)
downloadmana-dbc6444d3086fa1b7afca4605600a0a0ae8ca394.tar.gz
mana-dbc6444d3086fa1b7afca4605600a0a0ae8ca394.tar.bz2
mana-dbc6444d3086fa1b7afca4605600a0a0ae8ca394.tar.xz
mana-dbc6444d3086fa1b7afca4605600a0a0ae8ca394.zip
Removed many pointless comparisons with NULL
Sometimes it's nice for clarity, but most of the time this is just clutter. C++ != Java. :)
Diffstat (limited to 'src/being.cpp')
-rw-r--r--src/being.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/being.cpp b/src/being.cpp
index 565eb35f..0ccf675c 100644
--- a/src/being.cpp
+++ b/src/being.cpp
@@ -370,8 +370,8 @@ void Being::setDirection(Uint8 direction)
for (int i = 0; i < VECTOREND_SPRITE; i++)
{
- if (mSprites[i] != NULL)
- mSprites[i]->setDirection(dir);
+ if (mSprites[i])
+ mSprites[i]->setDirection(dir);
}
}
@@ -470,7 +470,7 @@ void Being::logic()
// Update sprite animations
for (int i = 0; i < VECTOREND_SPRITE; i++)
{
- if (mSprites[i] != NULL)
+ if (mSprites[i])
{
mSprites[i]->update(tick_time * 10);
}
@@ -500,7 +500,7 @@ void Being::draw(Graphics *graphics, int offsetX, int offsetY) const
for (int i = 0; i < VECTOREND_SPRITE; i++)
{
- if (mSprites[i] != NULL)
+ if (mSprites[i])
{
mSprites[i]->draw(graphics, px, py);
}