Explosions and TNT block and entity - Printable Version +- Cuberite Forum (https://forum.cuberite.org) +-- Forum: Cuberite (https://forum.cuberite.org/forum-4.html) +--- Forum: Development (https://forum.cuberite.org/forum-13.html) +--- Thread: Explosions and TNT block and entity (/thread-858.html) |
Explosions and TNT block and entity - keyboard - 04-18-2013 Hi All, Rev 1392 is the first try to implement explosions,TNT block and the TNT entity on MCServer. A ton of work is still needed to finish implementing explosions and TNT. What needs to be done is the following: -Implement physics for the TNT entity (this is going to be taken care of when I implement physics for all entities) -Optimize the algorithm for block destruction (Probably use cBlockArea to speed this up) -Add damage to players and mobs -Have logic to generate pickups when some of the blocks are destroyed -Implement some sort of block hardiness -Make sure that the explosion animation is the correct one (I noticed that the explosion animation from the Explosion Packet looks different when the mcservers sends it. The vanilla gives out more smoke and particles) Please feel free to add anything else that it is missing RE: Explosions and TNT block and entity - NiLSPACE - 04-18-2013 also explosions should activate other TNT blocks. RE: Explosions and TNT block and entity - xoft - 04-18-2013 Are you on Linux or on Windows? You seem to have forgotten to commit the MSVC project file changes. But you really need to have MSVC 2008 in order to do that. If it's just the TNTEntity file addition, I can do that. RE: Explosions and TNT block and entity - keyboard - 04-18-2013 Oops, actually I used Visual Studio 2012. Also there is the file BlockTNT.h inside the block folder mmm, I think i am going to stop using visual studio 2012 and use 2008 I added BlockTNT.h to the project. Now it should be all good. please let me know if it is still broken RE: Explosions and TNT block and entity - tonibm19 - 04-18-2013 Also you can add creeper explosions. RE: Explosions and TNT block and entity - xoft - 04-18-2013 The header files don't need to be in the project file for the project to compile, but of course it's good to have them there. The project compiles, which is as much testing as I can do now. RE: Explosions and TNT block and entity - keyboard - 04-18-2013 Cool, now I am switching back to work on the physics stuff for entities. RE: Explosions and TNT block and entity - xoft - 04-19-2013 You know, a friend once said, "whitespace is free, so use it freely". You might want to take that advice as well I hopefully fixed your code to compile on Linux, it had some really bad issues - you put a pointer into a list and then let the object it was pointing to die, etc. So I fixed that up, too. Also, a vector is a better data structure here, since you can more or less approximate the number of elements, so you can even pre-allocate it, thus saving quite a few reallocations; a list has to allocate each item, so it's slow. RE: Explosions and TNT block and entity - keyboard - 04-20-2013 oh cool, thanks hopefully there aren't any more issues RE: Explosions and TNT block and entity - NiLSPACE - 04-21-2013 i made something that prevents TNT from destroying blocks when its in water. shall i commit it? |