Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
123 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
(supertux-sprite | ||
|
||
(action | ||
(name "left") | ||
(fps 20) | ||
(hitbox 8 12 38 38) | ||
(images "walk-0.png" | ||
"walk-1.png" | ||
"walk-2.png" | ||
"walk-3.png" | ||
"walk-4.png" | ||
"walk-5.png" | ||
"walk-6.png" | ||
"walk-7.png" | ||
) | ||
) | ||
(action | ||
(name "right") | ||
(fps 20) | ||
(hitbox 8 12 38 38) | ||
(mirror-action "left") | ||
) | ||
) |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
// SuperTux | ||
// Copyright (C) 2014 Ingo Ruhnke <grumbel@gmail.com> | ||
// | ||
// This program is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// This program is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
#include "badguy/kirby.hpp" | ||
|
||
#include "sprite/sprite.hpp" | ||
#include "supertux/object_factory.hpp" | ||
|
||
Kirby::Kirby(const Reader& reader) | ||
: WalkingBadguy(reader, "images/creatures/kirby/kirby.sprite", "left", "right") | ||
{ | ||
walk_speed = 80; | ||
} | ||
|
||
Kirby::Kirby(const Vector& pos, Direction d, std::string script) | ||
: WalkingBadguy(pos, d, "images/creatures/kirby/kirby.sprite", "left", "right") | ||
{ | ||
walk_speed = 80; | ||
dead_script = script; | ||
} | ||
|
||
bool | ||
Kirby::collision_squished(GameObject& object) | ||
{ | ||
//sprite->set_action(dir == LEFT ? "squished-left" : "squished-right"); | ||
kill_squished(object); | ||
return true; | ||
} | ||
|
||
/* EOF */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// SuperTux | ||
// Copyright (C) 2014 Ingo Ruhnke <grumbel@gmail.com> | ||
// | ||
// This program is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// This program is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
#ifndef HEADER_SUPERTUX_BADGUY_KIRBY_HPP | ||
#define HEADER_SUPERTUX_BADGUY_KIRBY_HPP | ||
|
||
#include "badguy/walking_badguy.hpp" | ||
|
||
class Kirby : public WalkingBadguy | ||
{ | ||
public: | ||
Kirby(const Reader& reader); | ||
Kirby(const Vector& pos, Direction d, std::string script); | ||
|
||
protected: | ||
bool collision_squished(GameObject& object); | ||
|
||
}; | ||
|
||
#endif | ||
|
||
/* EOF */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters