diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-03-13 16:20:15 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-03-13 16:20:15 +0000 |
commit | ea6011fbc06a2adc9805baabf8c921b48f60f2c3 (patch) | |
tree | cba2d0c6d1f8f1b6a46e248fb031e97c12693c10 | |
parent | 49949e95f8fed59ee815ef36a03c54a6959996db (diff) | |
download | mana-ea6011fbc06a2adc9805baabf8c921b48f60f2c3.tar.gz mana-ea6011fbc06a2adc9805baabf8c921b48f60f2c3.tar.bz2 mana-ea6011fbc06a2adc9805baabf8c921b48f60f2c3.tar.xz mana-ea6011fbc06a2adc9805baabf8c921b48f60f2c3.zip |
Maybe now finally no more crashing in paths? Needs playtesting, I know we all
like that!
-rwxr-xr-x | .cvsignore | 3 | ||||
-rw-r--r-- | ChangeLog | 3 | ||||
-rwxr-xr-x | autogen.sh | 4 | ||||
-rw-r--r-- | src/Makefile.am | 2 | ||||
-rw-r--r-- | src/game.cpp | 24 |
5 files changed, 20 insertions, 16 deletions
@@ -15,3 +15,6 @@ configure libtool autom4te.cache tmw.log +missing +install-sh +depcomp @@ -1,9 +1,10 @@ 0.0.11 (.... 2005) - Added walking with mouse by clicking where you want to go +- Chat now appears in a window - More complete support for new map format (collision, compression) - Fixed problem where players would often turn up with black hair - Fixed not showing other players dead when they die -- Fixed a crash in being path handling +- Fixed multiple crashes in being path handling - Fixed initial starting position for new player characters 0.0.10 (5 March 2005) @@ -4,9 +4,9 @@ echo "Generating build information using aclocal, autoheader, automake and autoc echo # Regerate configuration files -aclocal-1.9 +aclocal autoheader -automake-1.9 --gnu --add-missing --copy +automake --gnu --add-missing --copy autoconf echo diff --git a/src/Makefile.am b/src/Makefile.am index 7b59d450..63482415 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -116,6 +116,6 @@ INCLUDES= $(all_includes) # the library search path. tmw_LDFLAGS = $(all_libraries) $(LIBSDL_RPATH) -lguichan_sdl -lguichan `pkg-config --libs libxml-2.0` -tmw_CXXFLAGS = -Wall $(LIBSDL_CFLAGS) `pkg-config --cflags libxml-2.0` +tmw_CXXFLAGS = -Wall $(LIBSDL_CFLAGS) `pkg-config --cflags libxml-2.0` -fno-inline tmw_LDADD = $(LIBSDL_LIBS) -lguichan_opengl -lguichan -lGL -lphysfs tmw_TARGET = ../tmw diff --git a/src/game.cpp b/src/game.cpp index 9d55b3e4..c9d611bf 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -537,15 +537,17 @@ void do_parse() { break; // Add new being / stop monster case 0x0078: - if (find_node(RFIFOL(2)) == NULL) { + being = find_node(RFIFOL(2)); + + if (being == NULL) { being = new Being(); being->id = RFIFOL(2); being->speed = RFIFOW(6); if (being->speed == 0) { - being->speed = 150; // Else division by 0 when calculating frame + // Else division by 0 when calculating frame + being->speed = 150; } being->job = RFIFOW(14); - being->clearPath(); being->x = get_x(RFIFOP(46)); being->y = get_y(RFIFOP(46)); being->direction = get_direction(RFIFOP(46)); @@ -554,15 +556,13 @@ void do_parse() { add_node(being); } else { - if (being) { - being->clearPath(); - being->x = get_x(RFIFOP(46)); - being->y = get_y(RFIFOP(46)); - being->direction = get_direction(RFIFOP(46)); - being->frame = 0; - being->walk_time = tick_time; - being->action = STAND; - } + being->clearPath(); + being->x = get_x(RFIFOP(46)); + being->y = get_y(RFIFOP(46)); + being->direction = get_direction(RFIFOP(46)); + being->frame = 0; + being->walk_time = tick_time; + being->action = STAND; } break; |