#include "object/tilemap.hpp"
#include "scripting/squirrel_util.hpp"
#include "scripting/tilemap.hpp"
-#include "supertux/main.hpp"
+#include "supertux/globals.hpp"
#include "supertux/object_factory.hpp"
#include "supertux/tile_manager.hpp"
#include "supertux/tile_set.hpp"
TileMap::TileMap(const TileSet *new_tileset) :
tileset(new_tileset),
+ tiles(),
solid(false),
speed_x(1),
speed_y(1),
z_pos(0),
x_offset(0),
y_offset(0),
- movement(Vector(0,0)),
+ movement(0,0),
drawing_effect(NO_EFFECT),
alpha(1.0),
current_alpha(1.0),
remaining_fade_time(0),
+ path(),
+ walker(),
draw_target(DrawingContext::NORMAL)
{
}
TileMap::TileMap(const Reader& reader) :
+ tileset(),
+ tiles(),
solid(false),
speed_x(1),
speed_y(1),
alpha(1.0),
current_alpha(1.0),
remaining_fade_time(0),
+ path(),
+ walker(),
draw_target(DrawingContext::NORMAL)
{
tileset = current_tileset;
TileMap::TileMap(const TileSet *new_tileset, std::string name, int z_pos,
bool solid, size_t width, size_t height) :
tileset(new_tileset),
+ tiles(),
solid(solid),
speed_x(1),
speed_y(1),
alpha(1.0),
current_alpha(1.0),
remaining_fade_time(0),
+ path(),
+ walker(),
draw_target(DrawingContext::NORMAL)
{
this->name = name;
TileMap::expose(HSQUIRRELVM vm, SQInteger table_idx)
{
if (name.empty()) return;
- Scripting::TileMap* interface = new Scripting::TileMap(this);
+ scripting::TileMap* interface = new scripting::TileMap(this);
expose_object(vm, table_idx, interface, name, true);
}
TileMap::unexpose(HSQUIRRELVM vm, SQInteger table_idx)
{
if (name.empty()) return;
- Scripting::unexpose_object(vm, table_idx, name);
+ scripting::unexpose_object(vm, table_idx, name);
}
void