From: Matthias Braun Date: Mon, 17 Apr 2006 09:22:14 +0000 (+0000) Subject: - Fixed ghostforest vs. ghostwood name X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=c0fed8bdef7dbc9540b476fd28949ebad7d3c2ba;p=supertux.git - Fixed ghostforest vs. ghostwood name - Added waterways (no spritechange implemented though) - Removed FIXME file, use the wiki TODO - relax Sector::inside test to conside things above the sector as inside (this fixes the badguy porting problems in a simpler way, and the lifeup on top disappearing) SVN-Revision: 3351 --- diff --git a/FIXME b/FIXME deleted file mode 100644 index b2236ce77..000000000 --- a/FIXME +++ /dev/null @@ -1,8 +0,0 @@ -SUPERTUX FIXME'S -This file is for small, obvious and temporary issues that are too minor to be put into the TODO at the wiki. -Just put them here so you don't forget. ---- - -Errors in scripts crash X-Server (very annoying, please fix) -Some levels don't have the music path set correctly -Revert Tux to single image sprite diff --git a/data/images/tiles/ghostforest/ghostforest.xcf b/data/images/tiles/ghostforest/ghostforest.xcf deleted file mode 100644 index 9a8da5bd0..000000000 Binary files a/data/images/tiles/ghostforest/ghostforest.xcf and /dev/null differ diff --git a/data/images/tiles/ghostforest/ghostwood-1.png b/data/images/tiles/ghostforest/ghostwood-1.png deleted file mode 100644 index 86f50d768..000000000 Binary files a/data/images/tiles/ghostforest/ghostwood-1.png and /dev/null differ diff --git a/data/images/tiles/ghostforest/ghostwood-4.png b/data/images/tiles/ghostforest/ghostwood-4.png deleted file mode 100755 index b2af5f90e..000000000 Binary files a/data/images/tiles/ghostforest/ghostwood-4.png and /dev/null differ diff --git a/data/images/tiles/ghostforest/ghostwood-5.png b/data/images/tiles/ghostforest/ghostwood-5.png deleted file mode 100644 index cdf50151a..000000000 Binary files a/data/images/tiles/ghostforest/ghostwood-5.png and /dev/null differ diff --git a/data/images/tiles/ghostforest/ghostwood-6.png b/data/images/tiles/ghostforest/ghostwood-6.png deleted file mode 100644 index 992adbac9..000000000 Binary files a/data/images/tiles/ghostforest/ghostwood-6.png and /dev/null differ diff --git a/data/images/tiles/ghostforest/ghostwood-7.png b/data/images/tiles/ghostforest/ghostwood-7.png deleted file mode 100755 index 2e4d8e394..000000000 Binary files a/data/images/tiles/ghostforest/ghostwood-7.png and /dev/null differ diff --git a/data/images/tiles/ghostwood/ghostforest.xcf b/data/images/tiles/ghostwood/ghostforest.xcf new file mode 100644 index 000000000..9a8da5bd0 Binary files /dev/null and b/data/images/tiles/ghostwood/ghostforest.xcf differ diff --git a/data/images/tiles/ghostwood/ghostwood-1.png b/data/images/tiles/ghostwood/ghostwood-1.png new file mode 100644 index 000000000..86f50d768 Binary files /dev/null and b/data/images/tiles/ghostwood/ghostwood-1.png differ diff --git a/data/images/tiles/ghostwood/ghostwood-4.png b/data/images/tiles/ghostwood/ghostwood-4.png new file mode 100755 index 000000000..b2af5f90e Binary files /dev/null and b/data/images/tiles/ghostwood/ghostwood-4.png differ diff --git a/data/images/tiles/ghostwood/ghostwood-5.png b/data/images/tiles/ghostwood/ghostwood-5.png new file mode 100644 index 000000000..cdf50151a Binary files /dev/null and b/data/images/tiles/ghostwood/ghostwood-5.png differ diff --git a/data/images/tiles/ghostwood/ghostwood-6.png b/data/images/tiles/ghostwood/ghostwood-6.png new file mode 100644 index 000000000..992adbac9 Binary files /dev/null and b/data/images/tiles/ghostwood/ghostwood-6.png differ diff --git a/data/images/tiles/ghostwood/ghostwood-7.png b/data/images/tiles/ghostwood/ghostwood-7.png new file mode 100755 index 000000000..2e4d8e394 Binary files /dev/null and b/data/images/tiles/ghostwood/ghostwood-7.png differ diff --git a/data/images/worldmap.strf b/data/images/worldmap.strf index 0f5dbb392..529b731da 100644 --- a/data/images/worldmap.strf +++ b/data/images/worldmap.strf @@ -378,6 +378,116 @@ (east #t) (stop #f)) + (tile (id 78) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 0 0 32 32) + ) + (north #f) + (south #f) + (west #t) + (east #t) + ) + + (tile (id 79) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 32 0 32 32) + ) + (north #t) + (south #t) + (west #f) + (east #f) + ) + + (tile (id 80) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 64 0 32 32) + ) + (north #f) + (south #t) + (west #f) + (east #t) + ) + + (tile (id 81) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 96 0 32 32) + ) + (north #f) + (south #t) + (west #t) + (east #f) + ) + + (tile (id 82) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 0 32 32 32) + ) + (north #t) + (south #t) + (west #f) + (east #t) + ) + + (tile (id 83) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 32 32 32 32) + ) + (north #t) + (south #t) + (west #t) + (east #f) + ) + + (tile (id 84) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 64 32 32 32) + ) + (north #t) + (south #f) + (west #f) + (east #t) + ) + + (tile (id 85) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 96 32 32 32) + ) + (north #t) + (south #f) + (west #t) + (east #f) + ) + + (tile (id 86) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 0 64 32 32) + ) + (north #t) + (south #f) + (west #t) + (east #t) + ) + + (tile (id 87) + (images "worldmap/antarctica/water.png") + (editor-images + (region "worldmap/antarctica/water-editor.png" 32 64 32 32) + ) + (north #f) + (south #t) + (west #t) + (east #t) + ) + (tile (id 167) (images diff --git a/data/images/worldmap/antarctica/water-editor.png b/data/images/worldmap/antarctica/water-editor.png new file mode 100644 index 000000000..9ca55987b Binary files /dev/null and b/data/images/worldmap/antarctica/water-editor.png differ diff --git a/data/images/worldmap/common/boat/boat.sprite b/data/images/worldmap/common/boat/boat.sprite index 89ddae6fa..130735670 100644 --- a/data/images/worldmap/common/boat/boat.sprite +++ b/data/images/worldmap/common/boat/boat.sprite @@ -1,18 +1,30 @@ (supertux-sprite (action - (name "default") - (x-offset 0) - (y-offset 0) -(fps 5) - (images "boat.png" -) + (name "empty") + (images "boat_empty.png") ) (action - (name "solved") - (x-offset 0) - (y-offset 0) -(fps 5) - (images "boat.png" -) + (name "small-stop") + (images "boat.png") + ) + (action + (name "small-walking") + (images "boat.png") + ) + (action + (name "fire-stop") + (images "boat.png") + ) + (action + (name "fire-walking") + (images "boat.png") + ) + (action + (name "large-stop") + (images "boat.png") + ) + (action + (name "large-walking") + (images "boat.png") ) ) diff --git a/src/badguy/badguy.cpp b/src/badguy/badguy.cpp index 8c3f085cd..3798ab903 100644 --- a/src/badguy/badguy.cpp +++ b/src/badguy/badguy.cpp @@ -32,7 +32,7 @@ static const float X_OFFSCREEN_DISTANCE = 1600; static const float Y_OFFSCREEN_DISTANCE = 1200; BadGuy::BadGuy() - : countMe(true), sprite(0), remove_out_of_bounds(true), dir(LEFT), state(STATE_INIT) + : countMe(true), sprite(0), dir(LEFT), state(STATE_INIT) { set_group(COLGROUP_DISABLED); } @@ -62,7 +62,7 @@ BadGuy::draw(DrawingContext& context) void BadGuy::update(float elapsed_time) { - if(!Sector::current()->inside(bbox) && remove_out_of_bounds) { + if(!Sector::current()->inside(bbox)) { remove_me(); return; } diff --git a/src/badguy/badguy.hpp b/src/badguy/badguy.hpp index f318a4e06..24f31549f 100644 --- a/src/badguy/badguy.hpp +++ b/src/badguy/badguy.hpp @@ -141,12 +141,6 @@ protected: /// is the enemy activated bool activated; /** - * Should the badguy be removed when it leaves the bounds of the sector? - * Use this when the badguy is portable and picked up by the player, who - * may actually leave the sector's bounds sometimes. - */ - bool remove_out_of_bounds; - /** * initial position of the enemy. Also the position where enemy respawns when * after being deactivated. */ diff --git a/src/badguy/mriceblock.cpp b/src/badguy/mriceblock.cpp index 8ec6f9a09..732793742 100644 --- a/src/badguy/mriceblock.cpp +++ b/src/badguy/mriceblock.cpp @@ -276,7 +276,6 @@ MrIceBlock::grab(MovingObject&, const Vector& pos, Direction dir) sprite->set_action(dir == LEFT ? "flat-left" : "flat-right"); set_state(ICESTATE_GRABBED); set_group(COLGROUP_DISABLED); - remove_out_of_bounds = false; } void @@ -285,7 +284,6 @@ MrIceBlock::ungrab(MovingObject& , Direction dir) this->dir = dir; set_state(ICESTATE_KICKED); set_group(COLGROUP_MOVING); - remove_out_of_bounds = true; } IMPLEMENT_FACTORY(MrIceBlock, "mriceblock") diff --git a/src/console.cpp b/src/console.cpp index abb10d615..7e7b38f76 100644 --- a/src/console.cpp +++ b/src/console.cpp @@ -196,8 +196,8 @@ Console::addLine(std::string s) } alpha = 1.0; - if(stayOpen < 5) - stayOpen += 1; + if(stayOpen < 6) + stayOpen += 1.5; } void diff --git a/src/sector.cpp b/src/sector.cpp index f746eec81..d92fc37c4 100644 --- a/src/sector.cpp +++ b/src/sector.cpp @@ -1165,7 +1165,7 @@ Sector::inside(const Rect& rect) const { if(rect.p1.x > solids->get_width() * 32 || rect.p1.y > solids->get_height() * 32 - || rect.p2.x < 0 || rect.p2.y < 0) + || rect.p2.x < 0) return false; return true; diff --git a/src/sector.hpp b/src/sector.hpp index c6b486d48..9b72e7d1f 100644 --- a/src/sector.hpp +++ b/src/sector.hpp @@ -93,7 +93,10 @@ public: const std::string& get_name() const { return name; } - /// tests if a given rectangle is inside the sector + /** + * tests if a given rectangle is inside the sector + * (a rectangle that is on top of the sector is considered inside) + */ bool inside(const Rect& rectangle) const; void play_music(MusicType musictype); diff --git a/src/worldmap/tux.cpp b/src/worldmap/tux.cpp index ade0588b9..f1086af52 100644 --- a/src/worldmap/tux.cpp +++ b/src/worldmap/tux.cpp @@ -182,6 +182,8 @@ Tux::tryContinueWalking(float elapsed_time) } } + + // stop if we reached a level, a WORLDMAP_STOP tile or a special tile without a passive_message if ((worldmap->at_level()) || (worldmap->at(tile_pos)->getData() & Tile::WORLDMAP_STOP) || (special_tile && !special_tile->passive_message)) { diff --git a/src/worldmap/worldmap.hpp b/src/worldmap/worldmap.hpp index b6e3a4377..69e1ca76c 100644 --- a/src/worldmap/worldmap.hpp +++ b/src/worldmap/worldmap.hpp @@ -160,10 +160,12 @@ public: * Save worldmap state to squirrel state table */ void save_state(); + /** * Load worldmap state from squirrel state table */ void load_state(); + /** * Load a worldmap */