Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  2. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

TerraVol: volumetric/voxel terrain system. Dig holes caves in your terrains!

Discussion in 'Assets and Asset Store' started by Amfu, Apr 9, 2013.

  1. pixlweaver

    pixlweaver

    Joined:
    Dec 21, 2012
    Posts:
    92
    Sweet! Definitely looking forward to the LOD system :D
     
  2. SevenBits

    SevenBits

    Joined:
    Dec 26, 2011
    Posts:
    1,953
    Looks really cool. Glad that someone came out with a feature like this.
     
  3. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Thanks :)

    Yes, I will test TerraVol on mobile for the next major version, but I can't promise it will work well... (that's why I have to test it)

    And yes, all updates, including major versions, are and will be available for free through the Asset Store. ;)
     
  4. lotsofcash

    lotsofcash

    Joined:
    May 11, 2013
    Posts:
    3
    cool,

    Will there be any updates to stop floating rocks? like when you dig a whole around rock and theres no more connecting rock it falls and on the demo when building material i fell through the terrain kept falling... think was when built material on the player camera.. or something

    Any seems quite good
     
  5. MarkFowler

    MarkFowler

    Joined:
    Nov 29, 2012
    Posts:
    31
    I am watching this thread like a hawk, and will purchase your system when you:

    1 - Add LoD
    2 - Fix the floating pieces and have the un-connected parts "fall"
    3 - Add fluids (water, lava, etc)
     
  6. HeavyMcD

    HeavyMcD

    Joined:
    Nov 4, 2012
    Posts:
    317
    I bought TerraVol. I was wondering if you could tell me how I might make the polygonal density doubled what it is now? I have an open sandbox game I am making and I wanted to add it as a terrain type but the resolution is not quite what I was hoping for. Any help would be greatly appreciated.

    Here is a link to my game so you have a frame of reference. https://www.dropbox.com/sh/wxgyj0ei47201tl/sobtGZHs8a

    Also latest videos of it in action

     
  7. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Making the floating rocks fall would not be as easy as it might look. I haven't planed to do that yet, but this is definitely something to add at the todo list of TerraVol. I'll let you know if there is any news about it.

    @heavyh2o
    You can adjust the size of each block by changing the following parameters on the Map component:
    • Block Size X
    • Block Size Y
    • Block Size Z

    By default, these are set to 3, you could try with 2 or 1 (this is an integer to avoid floating point imprecision in intermediate computations).

    Do not hesitate to ask if you have any more questions.

    By the way, your videos look great! I'll test your game as soon as I'm back home!
     
  8. HeavyMcD

    HeavyMcD

    Joined:
    Nov 4, 2012
    Posts:
    317
    Thanks,

    I'll let my coder know.. He hasn't had time to get your code integrated into ours yet.. He has done a fantastic job on my project but i fear that this is out of his comfort level. Do you think we might be able to join forces some how? We are only 3 people and I could really use the help. If you are up to it... Could I pay you to help me out?

    BTW new vids today..






    Matt
     
  9. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    This is really interesting but unfortunately I have no time for that currently. I'm already handling TerraVol development and I'm working on another project + my job. I can't take one more for now. Maybe later, if you still need it... who knows!

    But remember you can at least get some support from me about TerraVol, if you have some questions or if you need specific information.
     
  10. UrgeT

    UrgeT

    Joined:
    Mar 2, 2013
    Posts:
    11
    I just got some questions about Terravol:

    - Will I be able to use Relief Terrain Pack https://www.assetstore.unity3d.com/#/content/5664 together with this ? If can I can see that this will become very useful for the project I am putting together.

    - I read the manual : sow construction is done in real time, just save then load the terrain, meaning that I can shape the landshape then take away the ability to digg in the terrain (since gone use for caves, underground passages, dungeons, without letteing player be able to digg their way out)
     
  11. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    You will be able to use some Relief Terrain Pack shaders, but not all of them. Voxel terrains need triplanar shaders. From what I read on the RTP forum thread, you can't use the triplanar shader with parallax mapping for example.

    Yes construction is done in real time so you can shape it, then save it and load it after. If you don't need the ability to alter the terrain in your game, you don't even need to save TerraVol data. You will just have to save the scene (.unity).
    The next version of TerraVol will also allow you to shape the terrain in the editor.
     
  12. UrgeT

    UrgeT

    Joined:
    Mar 2, 2013
    Posts:
    11
    Ok, well some working is better then none, sow I bought Terravol, the ability to make caves and dugeons alone is worth that price too me, also very interested in that LOD system you are working on.
     
  13. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Thanks UrgeT, and welcome to the TerraVol community! (btw, I'm thinking of opening a forum for TerraVol users)
    Yes, the LOD system is still under development but is definitely coming.
     
  14. botumys

    botumys

    Joined:
    Apr 16, 2009
    Posts:
    707
    One question : It is possible to paint splatmaps on voxels, or it's only "mathematic"? (same question for details obj)
     
  15. Ebil

    Ebil

    Joined:
    Feb 13, 2012
    Posts:
    12
    How big can the terrain be ( also in height / depth)? In your demo its a lil bit short for my purpose, I would like to have a size of a planet or like in minecraft.
     
  16. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    @Botumys
    What would you like to do with splatmaps? I will give you a better answer if I know what is your goal, because splatmaps can't be directly used with TerraVol but maybe what you really need to do is even simpler than splatmaps with TerraVol BlockSet component.

    @Ebil
    It's quite hard to answer this, as it mainly depends on the size of each block (i.e. the granularity). Terrains can be very big thanks to the dynamic generation, but maybe not as big as you want. What do you mean by "big" (in term of Unity's coordinates)?
     
  17. bens1984

    bens1984

    Joined:
    Jan 18, 2013
    Posts:
    84
    Amfu - I've been watching your project since release, very cool!

    I have a very similar project, "Ruaumoko", also on the Asset Store (the release thread is here http://forum.unity3d.com/threads/18...face-voxel-mesh-generation-and-terrain-engine )

    I don't see any reason to be in direct competition and I would be glad to specialize my project in a different direction from yours. Then I'd be able to point people towards the right package for their needs. (for example I'm not interested in making a Mine-craft-esque utility, yet I get a lot of requests for those capabilities) If you have ideas about the end design objectives for your project I'd be glad to talk about aiming in different directions! (and making this publicly known here)
     
  18. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Hi Bens1984,

    Don't worry, I'm totally ok to find similar projects on the Asset Store. To my mind, there are so much possibilities offered by voxels that it would be weird to be the only one to work with that :)
    I think what you say is smart and would be a good thing for both of us. Maybe the forum is not the best place to speak about the details but I agree with you, we should discuss about this. Maybe you could send an email to me at terravol.unity@gmail.com so we can talk about it.

    See you soon then ;)
     
  19. Ostavius

    Ostavius

    Joined:
    Feb 14, 2013
    Posts:
    9
    Any updates to come?

    Last update was: 1.04 (April 29, 2013)
     
  20. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Yes! A new version is about to be released. I'm finishing the tests.
    This version will mainly include a brand new in-editor terrain modeling tool and some memory usage access optimizations.
    This is going to be quite a big upgrade which will make life easier for TerraVol users. The ability to see and alter the terrain within the editor is a great plus.

    After this, the next release will include LOD and multithreading.
     
    Last edited: Jun 6, 2013
  21. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Hi everyone!

    I'm pleased to announce the release of TerraVol 1.1.0, which is now available on the Asset Store. As always, TerraVol customers can update their version for free. ;)

    This version comes with a brand new in-editor modeling tool which will allow to see, sculpt, build, and paint your voxel terrains directly inside the scene view.
    You may also appreciate the memory usage and memory access optimizations.

    Here is a video showing the editor tool (at 0:52):

    [video=youtube_share;iFcrYdfY4Ms]http://youtu.be/iFcrYdfY4Ms?t=52s

    Thanks!
     
  22. Don-Gray

    Don-Gray

    Joined:
    Mar 18, 2009
    Posts:
    2,276
    Hi,
    I did buy your package now that I am able to shape the terrain in the editor, thanks.
    Do you have list you could publish about what features you are planning for this package?
    Also, I see some demo videos, how about some how to videos (with speech, please)?
    I create the terrain, but then when going into Editor mode, some blocks keep getting added on the outer edges, but not always connected, what is the purpose of this and how can the open areas be filled in, so it's not broken?
    I think instead of the "OK" dialog when a terrain is saved, a fading message might be good instead.
    No user input needed.
    Is there a smooth feature to smooth the terrain when done sculpting?

    Thanks
     
    Last edited: Jun 12, 2013
  23. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Hi Don Gray,

    On the first post of this forum thread you will find a "coming soon" section.
    I've planed to make some tutorials but it takes a lot of time and I wanted to focus on the development. But this is something which is definitely coming up.

    When you create a terrain in the editor, blocks will be built around the camera and around the brush dynamically. This should not be a problem if all blocks are not built inside the editor because they will be built during the game anyway. If you want to limit the terrain size, you can adjust the Size X/Y/Z parameters of the TerraMap component.

    That's a good idea about the OK dialog. It's a little thing but still appreciable.

    There is no smooth feature in the editor tool yet, but I'm going to add new types of brush in the next versions of TerraVol. Don't worry, there will be more and more possibilities. ;)
     
  24. Don-Gray

    Don-Gray

    Joined:
    Mar 18, 2009
    Posts:
    2,276
    All sounds good, thanks!

    :)
     
  25. Psyckosama

    Psyckosama

    Joined:
    Mar 20, 2013
    Posts:
    88
    Is it possible to create very blocky terrain? Not minecraft blocky but still not smooth...
     
  26. dl_studios

    dl_studios

    Joined:
    Oct 14, 2012
    Posts:
    76
    Hi Amfu,

    Got your TerraVol pack. It's a nice package. You did a great job of optimizing the speed and I like the control you give over land creation.

    There are a couple of features I'd love to get for my up coming game and wonder how hard these would be to implement from your package.

    1. I'd like cubes to make buildings. I don't want all of the terrain to be blocky like mine craft, just the ability to build blocks on your smooth terrain. Okay, actually I know that marching cubes(with out modifying) can't give cubes due to the rounding it always does. Have you considered using dual contouring? Dual contouring using an octree gives the ability for sharp features and LOD, you don't have to worry about patching holes when you have cubes of different sizes siting side by side like you do with MC. Here is a link to a modified DC technique that looks very promising.

    2. I'd like to texture things with the brushes at runtime. If the texture brush could have a randomize on it, that would be awesome!

    3. The current texturing method could use some improvement. At least in the demo scene it's very easy to pick out the repeating patterns and ruins the believability. I applied an Allegorithmic substance procedural texture to the land, the tiling was still easy to spot. I'd like the ability to randomize the size and rotation of textures to get rid of the patterns. This would mean some how ignoring the block boundaries and treating an area as a whole. This article about the cicada principle might be helpful in finding some algorithms to do that.

    Any thoughts would be appreciated.

    Thank you.
     
    Last edited: Jun 13, 2013
  27. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    @Psyckosama: Yes, this is possible. I don't know exactly what you want to get, and you will probabely have to make your own terrain generator to fit exactly your needs, but it's entirely possible. Geometry is defined by blocks' isovalue. When isovalue is > 0, the block is "outside", otherwise, it is "inside". If you use negative isovalue near 0 (i.e. -0.001), you will get sharp angles. See the answer below:


    @dl_studios:

    1. As I said to Psyckosama, it is possible to have sharp angles in TerraVol an though to make buildings. The thing is to define inner blocks with a negative isovalue near 0 (i.e. -0.001).
    Here is a screenshot showing the result (it will be included as a new brush in the next release):

    $screen_sharp_angles.jpg

    As you can see, it's blocky, sharp. I modified the image a bit so you see polygons better.

    2. That's a good idea :)

    3. I have to think about it... Texturing is handled by the shader so I think modifying the shader is what you want to do...
     
    Last edited: Jun 14, 2013
  28. Banksy

    Banksy

    Joined:
    Mar 31, 2013
    Posts:
    341
    Just updated Terravol but there's no Editor :(

    Is it possible to edit a terrain ... save it then terraform the same terrain in game ?

    I hit "Save" in game and then I can't terraform anymore... so am under the impression once a terrain is saved that's it... yes ?

    note: I have a paid version of TerraVol running on Unity 4 Pro.
     
    Last edited: Jun 17, 2013
  29. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Hi Bransky,

    Are you trying to run it from the new example scene ("editor_tool_scene.unity") or from your own scene?
    If you want to run it from your own scene, do not forget to add the "TerraBuilder" component to the Map object. (Add Component -> TerraVol -> In-Editor Builder Tool)

    Also, be sure you have update the other components because some names changed in the last version (Map -> TerraMap, MapGenerator -> TerraMapGenerator)

    Please tell me if it fixes your problem :)
     
  30. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Yes it is totally possible, you can save a terrain and terraform it after again as many times as you want. But be careful: for some reasons terrains saved with previous versions of TerraVol can't be loaded by the new version.

    Also, there is a little bug coming with version 1.1.0 (which is already fixed and should be released in the next few days) at line 85 of Builder.cs. You have to replace this line with: TerraMap map = GameObject.Find ("Map").GetComponent<TerraMap> ();
    This bug happens when you try to save your map during play mode (press "E").

    Can you describe a little more your problem so I can help you with better instructions? It could be easier to talk about this by email if you prefer you can contact me at terravol.unity@gmail.com
     
  31. Banksy

    Banksy

    Joined:
    Mar 31, 2013
    Posts:
    341
    Ok I try to DL again from the Asset store... I think I may have hit import rather than update..

    Not sure what's happening... I just updated TeraVol now it has completely disappeared from my Component menu ...

    p.s Thx for the heads up on the Bug at line 85

    [ EDIT] All ok now.. I had two TerraVol version in the same project... Dooh !!

    All back to normal... I can now see the shiny new editor.. AWESOME !!!! looks great.. I can open the sample editor scene.

    I plan to add a few buildings to a scene ... try to add a few hidden treasure chests beneath the terrain. So players must seek them out... Is there any special setup I need to attain such results... It's a fairly straight forward game... A simple dig up hidden treasure to gain points.

    THX ..... this looks really powerful fun :)
     
    Last edited: Jun 17, 2013
  32. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Great!

    I'm glad I could help :)

    What you want to do is definitely possible. I don't see any specific setup for that, you should be able to do it without any problem, just by positioning your treasures anywhere you want in the scene. If your treasures are rigidbodies and are affected by gravity, just be careful they don't drop forever under the ground ;)

    Thank you very much for your feedback. About the editor: new brushes and tools will be added in future versions, so if you think of anything that could help you please tell me and I will see when I can manage to add it.
     
  33. Banksy

    Banksy

    Joined:
    Mar 31, 2013
    Posts:
    341
    The ability to mask out a certain area of terrain that can not be terraformed would be helpful.

    So for example a player could drop an object such as a securing point for a bridge this would not be affected by in game terraforming. Perhaps a drop off value around the securing point is in place. " a no dig zone " that can be created by the player.. That would be so neat This would in effect allow foundations to be put down for structures... Players can't simply dig under a building etc... without the right tool.
    Over time, a no dig zone may gradually change back to a diggable-zone.

    I'm guessing some of these features are simply related to game design rather than TerraVol itself... yes ? Perhaps I could simply add an object with box collider that stops players entering the area... but I feel it would still be good to be able to walk over such terrain.. just not the ability to dig there....

    Solid Rock... Sacred Ground etc..
     
    Last edited: Jun 17, 2013
  34. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    You will be happy to know that this feature already exists in TerraVol :)

    In the BlockSet component, where you define your different types of blocks, you will see a checkbox "Is Destructible". If this is unchecked, players won't be able to dig these blocks (but you will still be able to dig it in the editor).

    If you want to add some indestructible blocks using the editor, you will just need to select an indestructible block in the TerraBuilder inspector ("Current type of block") and then apply it using dig/build/paint actions.

    I hope this is what you wanted! Please let me know.
     
  35. Banksy

    Banksy

    Joined:
    Mar 31, 2013
    Posts:
    341
    WOw !! cool very cool.... I will test this out now....

    note: I tried adding a few treasure chests below the terrain surface ... I can dig down uncover the treasure ... great... but then it simply sits in mid air.. looking a bit strange defying gravity. Is there a way to apply a rigid body once it becomes visible ?

    How can I slow the dig process down. I've tried adjusting the Dig parameter in the build component but it still digs incredibly fast... looks more like blocks are simply popping away rather than slowly being eroded.
     
    Last edited: Jun 17, 2013
  36. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    What you could make is a MonoBehaviour script that you attach on your chests and that checks in the Update method if the chest is above the ground by performing a Raycast. When you detect that it is above the ground, you add a RigidBody component and set the parameters properly.

    If you want slow digging, you have to put a very low value as parameter, and do not forget to use Time.deltaTime.
    A parameter like this should dig slowly: 0.01f * Time.deltaTime
    Also, be careful how many times per frame or per second the "mouse down" input is taken into account in your scripts.
     
  37. Yguinhoxp

    Yguinhoxp

    Joined:
    Apr 7, 2013
    Posts:
    4
  38. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    While LOD and multithreading are still under development (it needs a lot of testing and time), a new grass system is going to be included in TerraVol.
    I'm sure you will like it: TerraVol is going to be able to render a lot of grass!

    I initially made this grass system for TerraVol only, but I finally decided to release it also in a different package on the Asset Store. Don't worry, as I said, this will also be included in TerraVol so people who already bought TerraVol and people who will buy TerraVol will get a voxel-optimized version of this grass system for free ;)

    Other people who need a powerful grass generator but don't want to buy TerraVol will be able to buy this new grass system for a lower price.

    Here is a screenshot of what is coming very soon:

    $01_low.jpg

    Grass-OMG stands for "Grass On Mesh Generator".
    I hope you will like it!
     
    Last edited: Jun 25, 2013
  39. jc_lvngstn

    jc_lvngstn

    Joined:
    Jul 19, 2006
    Posts:
    1,503
    That's awesome..I was actually getting ready to start looking at how to generate grass on my meshes, and this looks very nice.
     
  40. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Great! I'm glad to see that some people are already interested :)

    Thanks
     
    Last edited: Jun 28, 2013
  41. dl_studios

    dl_studios

    Joined:
    Oct 14, 2012
    Posts:
    76
    @Amfu, looks awesome! Thank you for making this a part of the TerraVol package as well.
    I think this really helps sell the land visually. I'm really excited about this!
    Question: How does it compare to the performance of Unity grass? Or is it Unity grass, this simply helps with placement?
     
  42. HeavyMcD

    HeavyMcD

    Joined:
    Nov 4, 2012
    Posts:
    317
    This is looking KILLER!!!
     
  43. Psyckosama

    Psyckosama

    Joined:
    Mar 20, 2013
    Posts:
    88
    I'm crossing my fingers for eventual voxel liquid sim and biomes.
     
  44. JohnLib

    JohnLib

    Joined:
    Jul 5, 2013
    Posts:
    2
    I've bought this asset yesterday and just wanted to say it is AWESOME!!!
    I didn't even know it was possible to make terrains like this before!

    I hope LOD system will be out soon, but it's already an awesome package, really.

    Thank you!
     
  45. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Thank you very much! :)

    Grass is almost finished but will come with multithreading that's why a bit more time is needed.
    I'll be back to give you some news!
     
  46. mikezenox

    mikezenox

    Joined:
    Oct 18, 2012
    Posts:
    55
    Hey, I recently bought this for an open world RPG me and a few friends are designing and I was wondering, would it be possible to ask for the ability to import a heightmap for the initial map generation? And also when I attempt to paint a different material over the terrain it changes the entire chunk rather than blending, like this:

    $Untitled.jpg
    Would it be possible to blend the two materials? I'm otherwise very happy with my investment so far and very exited to know the product will be updated and supported. The grass looks pretty amazing.
     
    Last edited: Jul 23, 2013
  47. Leanthar

    Leanthar

    Joined:
    Apr 14, 2011
    Posts:
    4
    I see on one of the reviews that the terrain doesn't generate when it is <0 on the y axis. My question is can I create the terrain (say a cave in the mountains) that is above ground (0) and then when I'm done can I move it to rest below 0? I want a way to be able to create a large cave system that is actually below the terrain 0 value. If I have to move it (assuming I can and it is repetitively easy) that is fine. Is this a Unity draw limitation or a limitation with Teravol?

    The system looks incredible and the new grass system looks amazing.
     
  48. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Hi,

    Sorry for the late answer, I was in holidays without any Internet access.

    @Mikezenox:
    I'm glad to know you're happy with TerraVol :)
    Currently there is no built-in method to generate the terrain from a heightmap, but it shouldn't be too hard to do and I've already planed to add this feature.
    Unfortunately, two different materials can't be automatically blended. Actually, it depends on your shaders: you should use a shader which is able to blend itself with another one.

    @Leanthar:
    Actually you should be able to generate terrain above y=0 by changing GROUND_LEVEL and WATER_LEVEL in TerrainGenerator.cs :

    public static readonly int GROUND_LEVEL = Chunk.SIZE_Y * 1;
    public static readonly int WATER_LEVEL = 0;

    Grass will come with multithreading ;)
     
  49. mikezenox

    mikezenox

    Joined:
    Oct 18, 2012
    Posts:
    55
    That's great news.

    Yea, after reading your documentation more thoroughly I figured that out. I haven't yet found one though, tbh I just haven't had the time to look.

    Edit: Also, how do I load the .terra file I've created into my build? When I use map.load unity spits null reference errors and does some other odd things.. (Yes I used the full path to the map file)
     
    Last edited: Jul 23, 2013
  50. Amfu

    Amfu

    Joined:
    Apr 9, 2013
    Posts:
    180
    Be sure the .terra2d file is also in the same folder, and has the same name (except for the extension). If this is already the case, could you send me the logs?
     
unityunity