{"assets":[],"author_link":"author\/glockenspiel\/","author_name":"Glockenspiel","cat":"LD #29","categories":["LD #29"],"comments":[],"epoch":1398451020,"event":"LD29","likes":5,"metadata":{"p_key":"81849","p_author":"Glockenspiel","p_authorkey":"0","p_urlkey":"290966","p_title":"hexagon voxel engine in unity","p_cat":"LD #29","p_event":"LD29","p_time":"1398451020","p_likes":"5","p_comments":"0","p_status":"WAYBACK","us_key":null,"us_name":null,"us_username":null,"event_start":"1398384000","event_key":"22","event_name":"LD29"},"source_url":"2014\/04\/25\/hexagon-voxel-engine-in-unity\/","text":"<p>Here is my engine i have been working on for this ludum dare. Anyone can feel free to use it. Its an early version that supports bot cubes and hexagons. Chunk management\/culling \u00a0is not completed so you can have infinite \u00a0worlds.<\/p>\n<p><em>(click to enlarge images)<\/em><\/p>\n<p><a href=\"http:\/\/i.imgur.com\/F7JDfzI.png\"><img alt=\"\" class=\"alignleft\" height=\"328\" src=\"http:\/\/i.imgur.com\/F7JDfzI.png\" width=\"583\"\/><\/a><\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>I tried having 110k blocks (4.4m vertices, 2.1m triangles) and I still had 65 fps as seen in the screenshot. There is one thing bugging me that it ins\u2019t 100% efficient as i had a little problem eliminating the faces which i didn\u2019t need to draw. If I get that working in a future version it could result in drawing about half the amount of triangles and possibly more depending on the terrains bumpiness.<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p><a href=\"http:\/\/i.imgur.com\/9pYEGcs.jpg\"><img alt=\"\" class=\"alignleft\" height=\"225\" src=\"http:\/\/i.imgur.com\/9pYEGcs.jpg\" width=\"550\"\/><\/a><\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>This is an example of one chunk (8x4x8)<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p><strong><span style=\"text-decoration: underline\">Unity project<\/span><\/strong><\/p>\n<p>The project is quite complex and is kind of lower level programming with mesh vertices, triangles, uv mapping and collision triangles, rather than the (inefficent) prefab path of doing this. FYI it doesn\u2019t have \u00a0a loading screen.<\/p>\n<p>Download link:<\/p>\n<p>https:\/\/www.dropbox.com\/sh\/z2vlqwh2jcu1m1j\/bajKd5QZUC<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>\u00a0<\/p>\n<p>Tags: <a href=\"http:\/\/ludumdare.com\/compo\/tag\/voxel\/\" rel=\"tag\">voxel<\/a>, <a href=\"http:\/\/ludumdare.com\/compo\/tag\/voxel-engine\/\" rel=\"tag\">voxel engine<\/a><\/p>","time":"April 25th, 2014 6:37 pm","title":"hexagon voxel engine in unity","title_was_empty":false}