diff options
author | Eugenio Favalli <elvenprogrammer@gmail.com> | 2005-12-13 20:03:25 +0000 |
---|---|---|
committer | Eugenio Favalli <elvenprogrammer@gmail.com> | 2005-12-13 20:03:25 +0000 |
commit | 8684a122e2a18c217dd9be896867d28fbf4f98d7 (patch) | |
tree | baa0ea8405b23a8575c5a4d15d9dbeac7a5f2ccd | |
parent | 30219be2ac73561f299b445504b9f3a211eefc7a (diff) | |
download | mana-8684a122e2a18c217dd9be896867d28fbf4f98d7.tar.gz mana-8684a122e2a18c217dd9be896867d28fbf4f98d7.tar.bz2 mana-8684a122e2a18c217dd9be896867d28fbf4f98d7.tar.xz mana-8684a122e2a18c217dd9be896867d28fbf4f98d7.zip |
Enabled monster emotions.
-rw-r--r-- | ChangeLog | 1 | ||||
-rw-r--r-- | src/being.cpp | 21 |
2 files changed, 14 insertions, 8 deletions
@@ -2,6 +2,7 @@ * data/items.xml: Changed item properties according to eAthena scripting capabilities. + * src/being.cpp: Enabled monster emotions. 2005-12-12 Eugenio Favalli <elvenprogrammer@gmail.com> diff --git a/src/being.cpp b/src/being.cpp index 6b26afad..2bea8341 100644 --- a/src/being.cpp +++ b/src/being.cpp @@ -345,14 +345,6 @@ Being::logic() } break; } - - if (emotion != 0) - { - emotion_time--; - if (emotion_time == 0) { - emotion = 0; - } - } } if (getType() == MONSTER && action != STAND) @@ -374,6 +366,14 @@ Being::logic() mPy += getYOffset(); mPx += getXOffset(); } + + if (emotion != 0) + { + emotion_time--; + if (emotion_time == 0) { + emotion = 0; + } + } } void @@ -592,6 +592,11 @@ Being::draw(Graphics *graphics, int offsetX, int offsetY) graphics->drawImage( monsterset[job-1002]->spriteset[dir + 4 * frame], px - 12, py - 25); + if (emotion != 0) + { + graphics->drawImage(emotionset->spriteset[emotion - 1], + px + 3, py - 60); + } break; default: |