mirror of
https://gitea.sffnetwork.ru/Kolyah35/minecraft-pe-0.6.1.git
synced 2026-11-24 03:19:44 +00:00
the whole game
This commit is contained in:
parent
816e9060b4
commit
f0617a5d22
2069 changed files with 581500 additions and 0 deletions
64
src/world/level/tile/QuartzBlockTile.h
Executable file
64
src/world/level/tile/QuartzBlockTile.h
Executable file
|
|
@ -0,0 +1,64 @@
|
|||
#ifndef NET_MINECRAFT_WORLD_LEVEL_TILE__QuartzBlockTile_H__
|
||||
#define NET_MINECRAFT_WORLD_LEVEL_TILE__QuartzBlockTile_H__
|
||||
|
||||
//package net.minecraft.world.level.tile;
|
||||
|
||||
#include "../../../util/Random.h"
|
||||
#include "../../Facing.h"
|
||||
#include "../material/Material.h"
|
||||
#include "../Level.h"
|
||||
|
||||
#include "Tile.h"
|
||||
|
||||
class QuartzBlockTile: public Tile
|
||||
{
|
||||
typedef Tile super;
|
||||
public:
|
||||
|
||||
static const int TYPE_DEFAULT = 0;
|
||||
static const int TYPE_CHISELED = 1;
|
||||
static const int TYPE_LINES = 2;
|
||||
|
||||
QuartzBlockTile(int id)
|
||||
: super(id, 4 + 13 * 16, Material::stone)
|
||||
{}
|
||||
|
||||
int getTexture(int face, int data) {
|
||||
if (face == Facing::UP || face == Facing::DOWN) {
|
||||
if (data == TYPE_CHISELED)
|
||||
{
|
||||
return 6 + 12 * 16;
|
||||
}
|
||||
if (data == TYPE_LINES)
|
||||
{
|
||||
return 5 + 12 * 16;
|
||||
}
|
||||
if (face == Facing::DOWN) {
|
||||
return 3 + 13 * 16;
|
||||
}
|
||||
return 4 + 12 * 16;
|
||||
}
|
||||
if (data == TYPE_CHISELED)
|
||||
{
|
||||
return 6 + 13 * 16;
|
||||
}
|
||||
if (data == TYPE_LINES)
|
||||
{
|
||||
return 5 + 13 * 16;
|
||||
}
|
||||
return tex;
|
||||
}
|
||||
|
||||
static int getTileDataForItemAuxValue(int auxValue) {
|
||||
return (auxValue & 0xf);
|
||||
}
|
||||
|
||||
protected:
|
||||
|
||||
int getSpawnResourcesAuxValue(int data) {
|
||||
return data;
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
#endif /*NET_MINECRAFT_WORLD_LEVEL_TILE__QuartzBlockTile_H__*/
|
||||
Loading…
Add table
Add a link
Reference in a new issue