forked from mirrors/kolyah35-minecraft-pe-0.6.1
the whole game
This commit is contained in:
parent
816e9060b4
commit
f0617a5d22
2069 changed files with 581500 additions and 0 deletions
32
src/world/level/tile/StonecutterTile.h
Executable file
32
src/world/level/tile/StonecutterTile.h
Executable file
|
|
@ -0,0 +1,32 @@
|
|||
#ifndef NET_MINECRAFT_WORLD_LEVEL_TILE__StonecutterTile_H__
|
||||
#define NET_MINECRAFT_WORLD_LEVEL_TILE__StonecutterTile_H__
|
||||
|
||||
#include "Tile.h"
|
||||
#include "../Level.h"
|
||||
#include "../material/Material.h"
|
||||
#include "../../entity/player/Player.h"
|
||||
|
||||
class StonecutterTile: public Tile
|
||||
{
|
||||
typedef Tile super;
|
||||
public:
|
||||
StonecutterTile(int id)
|
||||
: super(id, Material::stone)
|
||||
{
|
||||
tex = 13 + 16 * 2;
|
||||
}
|
||||
|
||||
int getTexture(int face) {
|
||||
if (face == Facing::UP) return 9 + 10 * 16;
|
||||
if (face == Facing::DOWN) return 14 + 3 * 16;
|
||||
if (face == Facing::NORTH || face == Facing::SOUTH) return 8 + 10 * 16;
|
||||
return tex;
|
||||
}
|
||||
|
||||
bool use(Level* level, int x, int y, int z, Player* player) {
|
||||
player->startStonecutting(x, y, z);
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
#endif /*NET_MINECRAFT_WORLD_LEVEL_TILE__StonecutterTile_H__*/
|
||||
Loading…
Add table
Add a link
Reference in a new issue