Browse Source

TileSet is now a child of Asset.

legacy
Sam Hocevar sam 14 years ago
parent
commit
cf1f5d500f
2 changed files with 3 additions and 16 deletions
  1. +0
    -12
      src/tileset.cpp
  2. +3
    -4
      src/tileset.h

+ 0
- 12
src/tileset.cpp View File

@@ -27,7 +27,6 @@ class TileSetData

private:
char *name;
int ref;
int *tiles;
int ntiles;

@@ -43,7 +42,6 @@ TileSet::TileSet(char const *path)
{
data = new TileSetData();
data->name = strdup(path);
data->ref = 0;
data->tiles = NULL;
data->ntiles = 0;
data->img = NULL;
@@ -77,16 +75,6 @@ TileSet::~TileSet()
delete data;
}

void TileSet::Ref()
{
data->ref++;
}

int TileSet::Unref()
{
return --data->ref;
}

char const *TileSet::GetName()
{
return data->name;


+ 3
- 4
src/tileset.h View File

@@ -8,17 +8,16 @@

#include <stdint.h>

#include "asset.h"

class TileSetData;

class TileSet
class TileSet : public Asset
{
public:
TileSet(char const *path);
~TileSet();

void Ref();
int Unref();

char const *GetName();

void BlitTile(uint32_t id, int x, int y);


Loading…
Cancel
Save