{"id":1166,"date":"2014-12-10T21:25:58","date_gmt":"2014-12-10T21:25:58","guid":{"rendered":"http:\/\/phoenixgamedevelopment.com\/blog\/?p=1166"},"modified":"2014-12-10T21:26:35","modified_gmt":"2014-12-10T21:26:35","slug":"p-152-virtual-world-concept-update-23-spherical-terrain-collision-concept-test","status":"publish","type":"post","link":"https:\/\/phoenixgamedevelopment.com\/blog\/p-152-virtual-world-concept-update-23-spherical-terrain-collision-concept-test\/","title":{"rendered":"P-152: Virtual World Concept Update 23: Spherical Terrain: Collision Concept Test"},"content":{"rendered":"<p>I have succeeded in implementing a simple box Collision hull for my spherical terrain. I have basically created a square collision hull and aligned it to the bounds box. I have confirmed player collision is working against this box.<\/p>\n<p>This is an excellent starting point for implementing the much more advanced collision system that I will need for the final system. In fact, I may be able to use a simple system like this in combination with other, more complex systems. I could use a Level of Detail, or &#8220;LOD&#8221; based approach, where I use very simple collision when the player is far away from the object, and then add more complex collision as the player gets closer.<\/p>\n<p>The following resources were extremely useful in understanding T3D&#8217;s collision system:<\/p>\n<p><a href=\"https:\/\/gist.github.com\/eightyeight\/77cedbf5ac56b54469f1\">https:\/\/gist.github.com\/eightyeight\/77cedbf5ac56b54469f1<\/a><\/p>\n<p><a href=\"http:\/\/www.garagegames.com\/community\/forums\/viewthread\/139149\/7#comment-861287\">http:\/\/www.garagegames.com\/community\/forums\/viewthread\/139149\/7#comment-861287<\/a><\/p>\n<p><a href=\"http:\/\/wiki.torque3d.org\/coder:collision-system-overview\">http:\/\/wiki.torque3d.org\/coder:collision-system-overview<\/a><\/p>\n<p>T3D&#8217;s player collision system is based around generating a collision hull from simple objects, and then performing collision calculation on that shape. Based on what I have learned, I think my custom collision system will be to determine where exactly the player is standing on the terrain, and select\u00a0all of the\u00a0polygons from a certain radius around the player, and add them to the polylist, to be checked for collision. By returning only the polys close to the players position, I can keep the poly list small enough to be processed quickly, while at the same time keeping it complex enough to provide realistic collision mechanics.<\/p>\n<p>&nbsp;<\/p>\n<p><a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment06-Dec.-10-20.18.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1172\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment06-Dec.-10-20.18-300x232.jpg\" alt=\"PhoenixGameDevelopment06 Dec. 10 20.18\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment06-Dec.-10-20.18-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment06-Dec.-10-20.18-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment06-Dec.-10-20.18.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment07-Dec.-10-20.18.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1171\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment07-Dec.-10-20.18-300x232.jpg\" alt=\"PhoenixGameDevelopment07 Dec. 10 20.18\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment07-Dec.-10-20.18-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment07-Dec.-10-20.18-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment07-Dec.-10-20.18.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment02-Dec.-10-20.17.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1170\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment02-Dec.-10-20.17-300x232.jpg\" alt=\"PhoenixGameDevelopment02 Dec. 10 20.17\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment02-Dec.-10-20.17-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment02-Dec.-10-20.17-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment02-Dec.-10-20.17.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment03-Dec.-10-20.18.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1169\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment03-Dec.-10-20.18-300x232.jpg\" alt=\"PhoenixGameDevelopment03 Dec. 10 20.18\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment03-Dec.-10-20.18-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment03-Dec.-10-20.18-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment03-Dec.-10-20.18.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment04-Dec.-10-20.18.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1168\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment04-Dec.-10-20.18-300x232.jpg\" alt=\"PhoenixGameDevelopment04 Dec. 10 20.18\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment04-Dec.-10-20.18-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment04-Dec.-10-20.18-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment04-Dec.-10-20.18.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a> <a href=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment05-Dec.-10-20.18.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1167\" src=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment05-Dec.-10-20.18-300x232.jpg\" alt=\"PhoenixGameDevelopment05 Dec. 10 20.18\" width=\"300\" height=\"232\" srcset=\"https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment05-Dec.-10-20.18-300x232.jpg 300w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment05-Dec.-10-20.18-1024x793.jpg 1024w, https:\/\/phoenixgamedevelopment.com\/blog\/wp-content\/uploads\/2014\/12\/PhoenixGameDevelopment05-Dec.-10-20.18.jpg 1040w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I have succeeded in implementing a simple box Collision hull for my spherical terrain. I have basically created a square collision hull and aligned it to the bounds box. I have confirmed player collision is working against this box. This is an excellent starting point for implementing the much more advanced collision system that I [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,10],"tags":[],"class_list":["post-1166","post","type-post","status-publish","format-standard","hentry","category-art-and-designs","category-software-and-games","has-post-title","has-post-date","has-post-category","has-post-tag","has-post-comment","has-post-author",""],"aioseo_notices":[],"builder_content":"","_links":{"self":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/1166"}],"collection":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/comments?post=1166"}],"version-history":[{"count":2,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/1166\/revisions"}],"predecessor-version":[{"id":1174,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/posts\/1166\/revisions\/1174"}],"wp:attachment":[{"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/media?parent=1166"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/categories?post=1166"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/phoenixgamedevelopment.com\/blog\/wp-json\/wp\/v2\/tags?post=1166"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}