57 number_of_trees != 0; --number_of_trees)
61 for (
int k=
HEIGHT-2; ; --k) {
65 Tree(x, y, k+1, 4+qrand()%5);
90 int z_start =
HEIGHT/2-depth;
108 for (
int k=z_start; k<=
HEIGHT/2; ++k) {
109 if ( shore !=
GetBlock(i, j, k)->Sub() ) {
125 for (z=0; z<SHRED_WIDTH/2-2; ++z) {
126 if ( z <= -qAbs(x-SHRED_WIDTH/2)+
135 for (z=0; z<SHRED_WIDTH/2-2; ++z) {
136 if ( z <= -qAbs(y-SHRED_WIDTH/2)+
160 const ushort mount_top = 3*
HEIGHT/4;
174 if ( qrand()%10 == 0 ) {
177 for (
int k=mount_top-3; k<=mount_top; ++k) {
182 if ( qrand()%10 == 0 ) {
184 const int entries = qrand()%15+1;
206 for (
int i=0; i<4; ++i) {
215 int random = qrand();
221 if ( random & 0x1 ) {
225 const int x = random & 0xF;
227 const int y = random & 0xF;
static Block * Normal(int sub)
Puts block to coordinates, not activates it.
void NormalCube(int x_start, int y_start, int z_start, int x_size, int y_size, int z_size, subs)
void NormalUnderground(int depth=0, subs sub=SOIL)
shred_type GetTypeOfShred() const
void CoverWith(int kind, int sub)
void Water(subs sub=WATER)
void PutBlock(Block *const block, const int x, int y, int z)
void LoadRoom(int level, int index=0)
int FlatUndeground(int depth=0)
const WorldMap * GetMap() const
char TypeOfShred(long longi, long lati) const
Block * GetBlock(const int x, const int y, const int z) const
int CountShredTypeAround(int type) const
bool Tree(int x, int y, int z, int height)
Block combinations section (trees, buildings, etc):
void RandomDrop(int num, int kind, int sub, bool on_water=false)
Puts num things(kind-sub) in random places on shred surface.
Block without special physics and attributes.
Provides definition for class Block.
void SetNewBlock(int kind, int sub, int x, int y, int z, int dir=UP)