diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2007-08-28 16:42:47 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2007-08-28 16:42:47 +0000 |
commit | 3641a74507d692a7fbababfd8beb738f71e48acb (patch) | |
tree | 78d9235fe86ff2e958edb2cc2f777bbaade7607c /src/imageparticle.cpp | |
parent | 55786731e0517efdc123d4e8245b2aa94fa55cbe (diff) | |
download | mana-3641a74507d692a7fbababfd8beb738f71e48acb.tar.gz mana-3641a74507d692a7fbababfd8beb738f71e48acb.tar.bz2 mana-3641a74507d692a7fbababfd8beb738f71e48acb.tar.xz mana-3641a74507d692a7fbababfd8beb738f71e48acb.zip |
Added Vector class and used it in the particle engine.
Diffstat (limited to 'src/imageparticle.cpp')
-rw-r--r-- | src/imageparticle.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/imageparticle.cpp b/src/imageparticle.cpp index 35cc21ad..db38e395 100644 --- a/src/imageparticle.cpp +++ b/src/imageparticle.cpp @@ -44,8 +44,8 @@ void ImageParticle::draw(Graphics *graphics, int offsetX, int offsetY) const if (!mAlive) return; - int screenX = (int) mPosX + offsetX - mImage->getWidth() / 2; - int screenY = (int) mPosY - (int) mPosZ + offsetY - mImage->getHeight()/2; + int screenX = (int) mPos.x + offsetX - mImage->getWidth() / 2; + int screenY = (int) mPos.y - (int)mPos.z + offsetY - mImage->getHeight()/2; // Check if on screen if (screenX + mImage->getWidth() < 0 || |