From 4736ec595c1ed46f8b076f89bc31660ae21e9231 Mon Sep 17 00:00:00 2001 From: Philipp Sehmisch Date: Thu, 13 Mar 2008 13:14:24 +0000 Subject: Sending destination of beings when the client comes on-screen to fix a bug which showed moving monsters as standing in this situation. --- src/game-server/state.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/game-server/state.cpp b/src/game-server/state.cpp index 21305c01..2d6e4a04 100644 --- a/src/game-server/state.cpp +++ b/src/game-server/state.cpp @@ -249,15 +249,16 @@ static void informPlayer(MapComposite *map, Character *p) { // o is now visible by p. Send enter message. flags |= MOVING_POSITION; + flags |= MOVING_DESTINATION; MessageOut enterMsg(GPMSG_BEING_ENTER); enterMsg.writeByte(otype); enterMsg.writeShort(oid); enterMsg.writeByte(static_cast< Being *>(o)->getAction()); - enterMsg.writeShort(opos.x); - enterMsg.writeShort(opos.y); - switch (otype) { - + enterMsg.writeShort(opos.x); // aren't these two lines redundand considering + enterMsg.writeShort(opos.y); // that a MOVING_POSITION message is following? + switch (otype) + { case OBJECT_CHARACTER: { Character *q = static_cast< Character * >(o); -- cgit v1.2.3-70-g09d2