summaryrefslogtreecommitdiff
path: root/src/graphic/graphic.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/graphic/graphic.cpp')
-rw-r--r--src/graphic/graphic.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/graphic/graphic.cpp b/src/graphic/graphic.cpp
index 052ec402..cbd0a9da 100644
--- a/src/graphic/graphic.cpp
+++ b/src/graphic/graphic.cpp
@@ -226,8 +226,8 @@ void do_graphic(void) {
if(node->action!=STAND) {
node->frame = (get_elapsed_time(node->tick_time)*4)/(node->speed);
if(node->frame>=4) {
- if(node->action!=MONSTER_DEAD) {
- if(node->path->next && node->action!=MONSTER_DEAD) {
+ if(node->action!=MONSTER_DEAD && node->path) {
+ if(node->path->next) {
PATH_NODE *old = node->path;
node->path = node->path->next;
direction = 0;