Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

[PREVIEW] LandRush - World building and terraforming, with underground building

Discussion in 'Assets and Asset Store' started by snacktime, Jun 23, 2015.

  1. snacktime

    snacktime

    Joined:
    Apr 15, 2013
    Posts:
    3,356
    LandRush is a comprehensive solution for creating player built worlds. Currently I'm just working on documentation and wrapping up a few final touches.

    - Runtime object placement that handles any mesh/mesh combo you can throw at it. Destructable objects with optional physics destruction.

    - Underground tunneling with object placement underground.


    - Complete terraforming system with player owned or public land 'plots'.

    - Designed from the ground up for multiplayer games. Persistence using protocol buffers, with well abstracted storage backend.


    - Tools for handling scenes with many terrains (tested on over 100 terrains, 250k trees). Dynamic tree collider loading/unloading and dynamic terrain activation.

    I put together a collection of videos showing off some of the basic features. After the videos is some more detailed information on the major features.

    Underground building


    Terraforming


    Finished work after some terraforming/building


    Placing buildings


    Building with blocks


    Import tools
    https://www.youtube.com/watch?v=0wph3vlcibM (ran out of allowed embedded slots)

    Object placement
    Object placement can pretty much place anything and there are numerous configuration settings you can set per object. Objects can be placed at ground level or inset into terrain. You can specify the type of collider, or tell it to use existing coliders. Enable/disable physics destruction. You can also use physics for placement where we attack a temporary collider and test if the object moves. You can then set it to place where it moved to, or place where you put it.

    Underground building
    Underground building uses a hybrid voxel system of sorts. Digging is implemented with square cubes (except for the top layer), but you can dig down at increments of anywhere from 0.2 to 1. We do this by flattening vertices until the cube hits it's lowest height, then we remove it.

    Terrain holes are done with depth masks. All of our demo's use Relief Terrain and it works great. We don't use transparent textures and eat up a texture like some solutions.

    Underground building uses a 'chunk' system. It's based on a spatial grid where we can activate/deactivate blocks that are not in range of the player. The chunk system also combines meshes when not in dig mode, so performance even with lots of underground digging is good. Performance while digging can slow down in large dug out areas.

    Terraforming
    Terraforming works for heightmaps, alphamaps, detailmaps, and trees. The UI uses an outlined grid where you can raise/lower each square. It is aware of structures and underground areas and will not allow terraforming if those are too close. Changes are all persisted using protocol buffers, and loaded and applied when the scene loads.

    Multiplayer
    I'm also the author of Game Machine, so multiplayer was in from the very start. LandRush has a storage api that is well abstracted and easy to adapt to any server. We provide a full implementation for Game Machine. We realize not everyone wants to use Game Machine and that's fine. The Game Machine implementation can be used as a basis for any server, and the logic is fairly straight forward. We even provide full sql schema's that match the protocol buffer messages you can use (mysql and postgres).

    There is also an implementation of player owned land. At present there is not a server side implementation, but a full client side implementation exists complete with marker posts that outline the land plot, and permissions that only allow building in public plots, or a plot owned by you. Land plots are simple components you attach to a GameObject that has a box collider trigger defining the plot area.

    Tools for large worlds
    The last project I worked on before this was a large open world mmo. I wanted to see how big you could go in Unity. During that process I encountered the main things that are problematic with large open world games in Unity, and fixed them. Those fixes are part of LandRush.

    The major fix has to do with trees. Large numbers of trees can cause freezes in fps, which I tracked down to how Unity handles tree colliders. With LandRush you disable terrain tree colliders, and it will place colliders on trees for you when they are within range. So instead of Unity loading/unloading 10k+ colliders every few frames, you are loading/unloading 20-50 colliders every 5-10 seconds.

    The other part is a system for activating/deactivating terrains and arbitrary meshes based on range.

    Both of these tools are optional, although the tree handling is required if you want to cut down trees. You need a similar system anyways to handle that.

    UI
    The UI is done using the Unity UI, and is designed to be customized. We intentionally just used colors on standard components to make this easier. Objects are organized by configurable categories. You can easily plug into the UI for things like controlling player access to objects, and/or tie it into your own inventory system.

    Customization
    LandRush is highly customizable without any coding, although integrating with a real game will most likely require some coding on your part, if even only for the UI. LandRush is by definition a complex system, as evidenced by all of the configuration options.

    Currently customization hooks are provided via a C# interface that you must implement. A default implementation is included. Right now this includes hooks for before/after destroy and placement, what's considered a 'foundation' (maybe you don't use terrains), and most of the physics handling. In the future I'll add more hooks as user requests dictate.

    The goal is to not have to touch any core code outside of the UI. Nothing is worse then buying some asset, having to customize it, then a new version comes out with major internal changes and you are stuck. I want to avoid that.
     
  2. eskimojoe

    eskimojoe

    Joined:
    Jun 4, 2012
    Posts:
    1,440
    I get this error:
    1) Serialization depth limit exceeded at 'io.gamemachine.messages::Subscribers'. There may be an object composition cycle in one or more of your serialized classes.
    when I play gm_login scene.

    2) Your site is down - http://www.gamemachine.io/

    3) io/console not supported; tty will not be manipulated
    NameError: cannot load Java class com.dyuproject.protostuff.compiler.CachingProtoLoader
    for_name at org/jruby/javasupport/JavaClass.java:204
    get_proxy_class at org/jruby/javasupport/JavaUtilities.java:34
    java_import at file:/gamemachine-master/server/jruby/lib/jruby.jar!/jruby/java/core_ext/object.rb:27
    map at org/jruby/RubyArray.java:2414
    java_import at file:/gamemachine-master/server/jruby/lib/jruby.jar!/jruby/java/core_ext/object.rb:22
    initialize at gamemachine-master/server/lib/game_machine/protobuf/generate.rb:23
    generate_java_code at gamemachine-master/server/lib/game_machine/console/build.rb:57
    generate_code at gamemachine-master/server/lib/game_machine/console/build.rb:62
    run! at gamemachine-master/server/lib/game_machine/console/build.rb:111
    (root) at gamemachine-master\server\bin\../bin/game_machine:49
     
  3. eskimojoe

    eskimojoe

    Joined:
    Jun 4, 2012
    Posts:
    1,440
    ^ Friendly bump.