summaryrefslogtreecommitdiff
path: root/src/graphic
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2005-02-20 17:16:37 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2005-02-20 17:16:37 +0000
commit38a97bac830d6afe82fe3f68f3d8a0831bb5b643 (patch)
treeae8f26697caeee74da81c7b87cda0ac90faf5fb7 /src/graphic
parentd332272741e8382409453b975c66235d45e66cc7 (diff)
downloadmana-38a97bac830d6afe82fe3f68f3d8a0831bb5b643.tar.gz
mana-38a97bac830d6afe82fe3f68f3d8a0831bb5b643.tar.bz2
mana-38a97bac830d6afe82fe3f68f3d8a0831bb5b643.tar.xz
mana-38a97bac830d6afe82fe3f68f3d8a0831bb5b643.zip
More progress towards loading XML maps.
Diffstat (limited to 'src/graphic')
-rw-r--r--src/graphic/graphic.cpp10
-rw-r--r--src/graphic/spriteset.h2
2 files changed, 6 insertions, 6 deletions
diff --git a/src/graphic/graphic.cpp b/src/graphic/graphic.cpp
index 9fdda40b..83ed22bc 100644
--- a/src/graphic/graphic.cpp
+++ b/src/graphic/graphic.cpp
@@ -379,8 +379,8 @@ void Engine::draw()
// Draw tiles below nodes
for (int j = 0; j < 20; j++) {
for (int i = 0; i < 26; i++) {
- Image *tile0 = tiledMap.getTile(i + camera_x, j + camera_y, 0);
- Image *tile1 = tiledMap.getTile(i + camera_x, j + camera_y, 1);
+ Image *tile0 = tiledMap->getTile(i + camera_x, j + camera_y, 0);
+ Image *tile1 = tiledMap->getTile(i + camera_x, j + camera_y, 1);
if (tile0) {
tile0->draw(screen, i * 32 - offset_x, j * 32 - offset_y);
@@ -509,7 +509,7 @@ void Engine::draw()
// Draw tiles above nodes
for (int j = 0; j < 20; j++) {
for (int i = 0; i < 26; i++) {
- Image *tile = tiledMap.getTile(i + camera_x, j + camera_y, 2);
+ Image *tile = tiledMap->getTile(i + camera_x, j + camera_y, 2);
if (tile) {
tile->draw(screen, i * 32 - offset_x, j * 32 - offset_y);
@@ -527,7 +527,7 @@ void Engine::draw()
// purposes.
if (displayPathToMouse)
{
- PATH_NODE *debugPath = tiledMap.findPath(
+ PATH_NODE *debugPath = tiledMap->findPath(
player_node->x, player_node->y,
mouseX / 32 + camera_x, mouseY / 32 + camera_y);
@@ -538,7 +538,7 @@ void Engine::draw()
guiGraphics->setColor(gcn::Color(255, 0, 0));
guiGraphics->fillRectangle(gcn::Rectangle(squareX, squareY, 8, 8));
- MetaTile *tile = tiledMap.getMetaTile(debugPath->x, debugPath->y);
+ MetaTile *tile = tiledMap->getMetaTile(debugPath->x, debugPath->y);
std::stringstream cost;
cost << tile->Gcost;
diff --git a/src/graphic/spriteset.h b/src/graphic/spriteset.h
index d7b72a0e..42d6a82a 100644
--- a/src/graphic/spriteset.h
+++ b/src/graphic/spriteset.h
@@ -41,7 +41,7 @@ class Spriteset {
/*
* Cuts the passed image in a grid of sub images.
*/
- Spriteset::Spriteset(Image *img, int w, int h);
+ Spriteset(Image *img, int w, int h);
/**
* Destructor.