11-24-2012, 11:50 PM
11-25-2012, 03:34 AM
(11-24-2012, 11:50 PM)Luksor Wrote: [ -> ]How?(11-24-2012, 11:43 PM)Jers Wrote: [ -> ]I wanted to fix it, but I have not found BlockMycelium.hThere was no such file, I added it.
I Add BlockMycelium.h
Code:
#pragma once
#include "BlockHandler.h" //Это по любому нужно
class cBlockMyceliumHandler :
public cBlockHandler
{
public:
cBlockMyceliumHandler(BLOCKTYPE a_BlockType)
: cBlockHandler(a_BlockType)
{
}
virtual const char * GetStepSound(void) override//Я тут получаю звук для блока
{
return "step.gravel";
}
virtual void ConvertToPickups(cItems & a_Pickups, NIBBLETYPE a_BlockMeta) override//Тут при ломании блока появляется земля, но смотри
{
a_Pickups.push_back(cItem(E_ITEM_DIRT, 1, 0));
}
} ;
Code:
#include "BlockMycelium.h"
Code:
case E_BLOCK_MYCELIUM: return new cBlockMyceliumHandler (a_BlockType);
11-25-2012, 04:56 AM
It should work. Maybe you forgot to add the file to Visual Studio project?

11-25-2012, 05:02 AM
(11-25-2012, 04:56 AM)Luksor Wrote: [ -> ]It should work. Maybe you forgot to add the file to Visual Studio project?How to do it?


![[Image: 3307180.png]](http://savepic.ru/3307180.png)
11-25-2012, 05:13 AM
I'm using an older version, but it should be similar:
![[Image: vs.png]](https://dl.dropbox.com/u/21041937/vs.png)
![[Image: vs.png]](https://dl.dropbox.com/u/21041937/vs.png)
11-25-2012, 05:29 AM
(11-25-2012, 05:13 AM)Luksor Wrote: [ -> ]I'm using an older version, but it should be similar:thank you, but it dont work

11-25-2012, 05:32 AM
What is not working? Do you get any compilation errors or something?
11-25-2012, 02:56 PM
When I break the power of mycelium, falls mycelium, but i need to give out dirt
Error
Error 1 fatal error C1083: Cannot open file include: BlockMycelium.h: No such file or directory c:\Users\Oleg\Downloads\MCServer_1024_src\MCServer_1024\source\blocks\BlockHandler.cpp 10
I corrected the mistake and earned mycelium Thank you
Code:
virtual void ConvertToPickups(cItems & a_Pickups, NIBBLETYPE a_BlockMeta) override
{
a_Pickups.push_back(cItem(E_ITEM_DIRT, 11, 0)); //wtf dont work!
}
Error

Error 1 fatal error C1083: Cannot open file include: BlockMycelium.h: No such file or directory c:\Users\Oleg\Downloads\MCServer_1024_src\MCServer_1024\source\blocks\BlockHandler.cpp 10
I corrected the mistake and earned mycelium Thank you
12-06-2012, 12:25 AM
You also need to add a feature where cactus actually causes damage 

12-21-2012, 10:45 PM
you can add double doors to features now 
