Skip to content

Instantly share code, notes, and snippets.

@lucaspiller
Created July 25, 2012 22:05
Show Gist options
  • Save lucaspiller/3178990 to your computer and use it in GitHub Desktop.
Save lucaspiller/3178990 to your computer and use it in GitHub Desktop.
THREE.Mesh.prototype.rotateAboutObjectAxis = (axis, radians) ->
rotationMatrix = new THREE.Matrix4()
rotationMatrix.makeRotationAxis axis.normalize(), radians
@matrix.multiplySelf rotationMatrix
@rotation.getRotationFromMatrix @matrix
THREE.Mesh.prototype.rotateAboutWorldAxis = (axis, radians) ->
rotationMatrix = new THREE.Matrix4()
rotationMatrix.makeRotationAxis axis.normalize(), radians
rotationMatrix.multiplySelf @matrix
@matrix = rotationMatrix
@rotation.getRotationFromMatrix @matrix
THREE.AxisX = new THREE.Vector3(1, 0, 0)
THREE.AxisY = new THREE.Vector3(0, 1, 0)
THREE.AxisZ = new THREE.Vector3(0, 0, 1)
class Controller
VIEW_ANGLE = 45
NEAR = 1
FAR = 1000
CAMERA_Z = 1000
models: [
'turret.js'
'turret_base.js',
]
constructor: ->
@setupRenderer()
@setupScene()
@load()
width: ->
window.innerWidth
height: ->
window.innerHeight
setupRenderer: ->
@renderer = new THREE.WebGLRenderer {
antialias: true # smoother output
}
# clear to black background
@renderer.setClearColorHex 0x080808, 1
@renderer.setSize @width(), @height()
@container = document.createElement 'div'
document.body.appendChild @container
@container.appendChild @renderer.domElement
if window.Stats
@stats = new Stats()
@stats.domElement.style.position = 'absolute'
@stats.domElement.style.top = '0px'
@container.appendChild @stats.domElement
setupScene: ->
@scene = new THREE.Scene()
# add a camera
@camera = new THREE.PerspectiveCamera VIEW_ANGLE, @width() / @height(), NEAR, FAR
@camera.position.set 0, 0, CAMERA_Z
@scene.add @camera
# add light sources
@scene.add new THREE.AmbientLight 0x999999
@light = new THREE.PointLight 0xffffff
@scene.add @light
screen_range: (depth) ->
range_x = Math.tan(@camera.fov * Math.PI / 180) * (@camera.position.z - depth) * 2
range_y = range_x / @camera.aspect
[range_x, range_y]
camera_x_min: (range_x) ->
@camera.position.x - (range_x) / 2
camera_x_max: (range_x) ->
@camera.position.x + (range_x) / 2
camera_y_min: (range_y) ->
@camera.position.y - (range_y) / 2
camera_y_max: (range_y) ->
@camera.position.y + (range_y) / 2
load: ->
@geometries = {}
loader = new THREE.JSONLoader()
for model in @models
@loadModel loader, model
loadModel: (loader, model) ->
loader.load model, (geometry) =>
geometry.computeVertexNormals()
@geometries[model] = geometry
if _.size(@geometries) == _.size(@models)
@continueLoad()
continueLoad: ->
@objects = for i in [0..100]
new Turret {
controller: this
}
@render()
render: =>
requestAnimationFrame (=> @render())
for object in @objects
object.step()
@light.position.set @camera.position.x, @camera.position.y, CAMERA_Z * 10
@renderer.render @scene, @camera
@stats.update() if @stats
class TurretBase
constructor: (options) ->
@controller = options.controller
@mesh = @buildMesh()
@mesh.position = new THREE.Vector3 options.position.x, options.position.y, 500
@controller.scene.add @mesh
buildMesh: ->
material = new THREE.MeshFaceMaterial
geometry = @controller.geometries['turret_base.js']
for material in geometry.materials
material.shading = THREE.FlatShading
new THREE.Mesh geometry, material
class Turret
rotationalVelocity: Math.PI / 64
constructor: (options) ->
@controller = options.controller
@mesh = @buildMesh()
@mesh.rotateAboutWorldAxis THREE.AxisZ, 0.001 # hack to fix a bug in ThreeJS?
@controller.scene.add @mesh
@position = @mesh.position = new THREE.Vector3 0, 0, 500
@rotation = 0
@position.x = (Math.random() * 500) - 250
@position.y = (Math.random() * 500) - 250
@base = new TurretBase {
controller: options.controller,
position: @position
}
buildMesh: ->
material = new THREE.MeshFaceMaterial
geometry = @controller.geometries['turret.js']
for material in geometry.materials
material.shading = THREE.FlatShading
new THREE.Mesh geometry, material
step: ->
if Math.abs(@rotationalVelocity) > 0
@mesh.rotateAboutWorldAxis(THREE.AxisZ, @rotationalVelocity)
@rotation = (@rotation + @rotationalVelocity) % (Math.PI * 2)
$ ->
new Controller
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=UTF-8" />
<title>88etag</title>
<script src="http://cdnjs.cloudflare.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.3.3/underscore-min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/three.js/r49/Three.js"></script>
<script src="https://raw.github.com/mrdoob/stats.js/master/src/Stats.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/coffee-script/1.3.1/coffee-script.min.js"></script>
<script src="demo.coffee" type="text/coffeescript">
<style>
body {
margin: 0px;
overflow: hidden;
}
</style>
</head>
<body>
<div id="container"></div>
</body>
</html>
{
"metadata" :
{
"formatVersion" : 3,
"generatedBy" : "Blender 2.60 Exporter",
"vertices" : 224,
"faces" : 200,
"normals" : 86,
"colors" : 0,
"uvs" : 0,
"materials" : 1,
"morphTargets" : 0
},
"scale" : 1.000000,
"materials": [ {
"DbgColor" : 15658734,
"DbgIndex" : 0,
"DbgName" : "Material.001",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.5300403237342834, 0.6503549814224243, 0.699999988079071],
"colorSpecular" : [0.6574147765526561, 0.8066423142845807, 0.86821762407574],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "Material.001",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.5300403237342834, 0.6503549814224243, 0.699999988079071],
"colorSpecular" : [0.6574147765526561, 0.8066423142845807, 0.86821762407574],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "Material.001",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.5300403237342834, 0.6503549814224243, 0.699999988079071],
"colorSpecular" : [0.6574147765526561, 0.8066423142845807, 0.86821762407574],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "Material.001",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.5300403237342834, 0.6503549814224243, 0.699999988079071],
"colorSpecular" : [0.6574147765526561, 0.8066423142845807, 0.86821762407574],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "Material.001",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.5300403237342834, 0.6503549814224243, 0.699999988079071],
"colorSpecular" : [0.6574147765526561, 0.8066423142845807, 0.86821762407574],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "Material.001",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.5300403237342834, 0.6503549814224243, 0.699999988079071],
"colorSpecular" : [0.6574147765526561, 0.8066423142845807, 0.86821762407574],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "Material.001",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.5300403237342834, 0.6503549814224243, 0.699999988079071],
"colorSpecular" : [0.6574147765526561, 0.8066423142845807, 0.86821762407574],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
}],
"vertices": [0.000000,8.010000,0.000005,1.560723,7.856282,0.000005,3.061468,7.401036,0.000004,4.444562,6.661757,0.000004,5.656854,5.666854,0.000003,6.651757,4.454562,0.000003,7.391036,3.071467,0.000002,7.846282,1.570723,0.000001,8.000000,0.010001,-0.000000,7.846282,-1.550722,-0.000001,7.391037,-3.051466,-0.000002,6.651757,-4.434561,-0.000003,5.656854,-5.646854,-0.000003,4.444561,-6.641757,-0.000004,3.061466,-7.381037,-0.000004,1.560721,-7.836282,-0.000005,-0.000003,-7.990000,-0.000005,-1.560726,-7.836281,-0.000005,-3.061471,-7.381034,-0.000004,-4.444566,-6.641754,-0.000004,-5.656858,-5.646851,-0.000003,-6.651760,-4.434557,-0.000003,-7.391039,-3.051461,-0.000002,-7.846283,-1.550716,-0.000001,-8.000000,0.010008,-0.000000,-7.846281,1.570731,0.000001,-7.391033,3.071476,0.000002,-6.651752,4.454570,0.000003,-5.656847,5.666862,0.000003,-4.444553,6.661763,0.000004,-3.061457,7.401041,0.000004,-1.560711,7.856285,0.000005,-2.341066,11.779425,0.000007,-4.592185,11.096560,0.000007,-6.666830,9.987644,0.000006,-8.485271,8.495291,0.000005,-9.977629,6.676854,0.000004,-11.086551,4.602212,0.000003,-11.769422,2.351095,0.000001,-12.000001,0.010010,-0.000000,-11.769426,-2.331075,-0.000001,-11.086559,-4.582193,-0.000003,-9.977641,-6.656837,-0.000004,-8.485288,-8.475277,-0.000005,-6.666850,-9.967632,-0.000006,-4.592207,-11.076553,-0.000007,-2.341089,-11.759424,-0.000007,-0.000005,-11.990000,-0.000007,2.341080,-11.759424,-0.000007,4.592199,-11.076557,-0.000007,6.666842,-9.967636,-0.000006,8.485280,-8.475283,-0.000005,9.977634,-6.656843,-0.000004,11.086554,-4.582201,-0.000003,11.769423,-2.331084,-0.000001,11.999999,0.010000,-0.000000,11.769422,2.351083,0.000001,11.086553,4.602200,0.000003,9.977634,6.676841,0.000004,8.485280,8.495279,0.000005,6.666842,9.987635,0.000006,4.592201,11.096554,0.000007,2.341083,11.779423,0.000007,-0.000001,12.009998,0.000007,-0.000001,12.009997,1.898473,2.341083,11.779422,1.898473,4.592201,11.096553,1.898472,6.666842,9.987634,1.898472,8.485280,8.495278,1.898471,9.977634,6.676840,1.898470,11.086553,4.602199,1.898468,11.769422,2.351082,1.898467,11.999999,0.009999,1.898466,11.769423,-2.331085,1.898464,11.086554,-4.582201,1.898463,9.977634,-6.656844,1.898462,8.485280,-8.475284,1.898461,6.666842,-9.967637,1.898460,4.592199,-11.076558,1.898459,2.341080,-11.759425,1.898459,-0.000005,-11.990001,1.898458,-2.341089,-11.759425,1.898459,-4.592207,-11.076554,1.898459,-6.666850,-9.967633,1.898460,-8.485288,-8.475278,1.898461,-9.977641,-6.656838,1.898462,-11.086559,-4.582194,1.898463,-11.769426,-2.331076,1.898464,-12.000001,0.010009,1.898466,-11.769422,2.351094,1.898467,-11.086551,4.602211,1.898468,-9.977629,6.676853,1.898470,-8.485271,8.495290,1.898471,-6.666830,9.987643,1.898472,-4.592185,11.096559,1.898472,-2.341066,11.779424,1.898473,-1.560711,7.856284,1.898470,-3.061457,7.401040,1.898470,-4.444553,6.661762,1.898470,-5.656847,5.666861,1.898469,-6.651752,4.454569,1.898468,-7.391033,3.071475,1.898467,-7.846281,1.570730,1.898467,-8.000000,0.010007,1.898466,-7.846283,-1.550717,1.898465,-7.391039,-3.051463,1.898464,-6.651760,-4.434558,1.898463,-5.656858,-5.646852,1.898462,-4.444566,-6.641755,1.898462,-3.061471,-7.381035,1.898461,-1.560726,-7.836282,1.898461,-0.000003,-7.990001,1.898461,1.560721,-7.836283,1.898461,3.061466,-7.381038,1.898461,4.444561,-6.641758,1.898462,5.656854,-5.646855,1.898462,6.651757,-4.434562,1.898463,7.391037,-3.051467,1.898464,7.846282,-1.550723,1.898465,8.000000,0.009999,1.898466,7.846282,1.570722,1.898467,7.391036,3.071466,1.898467,6.651757,4.454561,1.898468,5.656854,5.666853,1.898469,4.444562,6.661756,1.898470,3.061468,7.401035,1.898470,1.560723,7.856281,1.898470,0.000000,8.009999,1.898470,25.250000,-0.501868,-6.280038,25.250000,-8.280040,1.498132,22.750000,-8.280040,1.498131,22.750000,-0.501866,-6.280039,25.250000,1.280038,-4.498127,25.250000,-6.498135,3.280043,22.750000,-6.498131,3.280039,22.750000,1.280040,-4.498129,25.250000,-1.280041,-4.498128,25.250000,6.498133,3.280039,22.750000,6.498132,3.280038,22.750000,-1.280043,-4.498130,25.250000,0.501868,-6.280036,25.250000,8.280043,1.498131,22.750000,8.280040,1.498128,22.750000,0.501866,-6.280038,25.250000,-8.280040,3.501873,25.250000,-0.501866,11.280039,22.750000,-0.501866,11.280039,22.750000,-8.280042,3.501871,25.250000,-6.498130,1.719964,25.250000,1.280044,9.498132,22.750000,1.280041,9.498129,22.750000,-6.498132,1.719963,25.250000,6.549576,1.719961,25.250000,-1.228597,9.498130,22.750000,-1.228596,9.498129,22.750000,6.549578,1.719959,25.250000,8.331483,3.501872,25.250000,0.553309,11.280042,22.750000,0.553313,11.280038,22.750000,8.331485,3.501870,-8.750000,-0.501868,-6.280038,-8.750000,-8.280040,1.498132,-11.250000,-8.280040,1.498131,-11.250000,-0.501866,-6.280039,-8.749999,1.280038,-4.498127,-8.750001,-6.498135,3.280043,-11.250000,-6.498131,3.280039,-11.250000,1.280040,-4.498129,-8.750000,-1.280041,-4.498128,-8.750000,6.498133,3.280039,-11.250000,6.498132,3.280038,-11.250000,-1.280043,-4.498130,-8.749999,0.501868,-6.280036,-8.750001,8.280043,1.498131,-11.250000,8.280040,1.498128,-11.250000,0.501866,-6.280038,-8.750000,-8.280040,3.501873,-8.750000,-0.501866,11.280039,-11.250000,-0.501866,11.280039,-11.250000,-8.280042,3.501871,-8.749999,-6.498130,1.719964,-8.750001,1.280044,9.498132,-11.250000,1.280041,9.498129,-11.250000,-6.498132,1.719963,-8.750000,6.549576,1.719961,-8.750000,-1.228597,9.498130,-11.250000,-1.228596,9.498129,-11.250000,6.549578,1.719959,-8.749999,8.331483,3.501872,-8.750001,0.553309,11.280042,-11.250000,0.553313,11.280038,-11.250000,8.331485,3.501870,25.999998,-1.250000,9.250000,25.999998,-1.250000,11.750000,-12.000002,-1.250000,11.750000,-11.999992,-1.250000,9.250000,26.000010,1.250000,9.250001,25.999987,1.250000,11.750001,-12.000008,1.250000,11.750000,-11.999998,1.250000,9.250000,25.999998,-1.250000,-6.750000,25.999998,-1.250000,-4.250000,-12.000002,-1.250000,-4.250000,-11.999992,-1.250000,-6.750000,26.000010,1.250000,-6.749999,25.999987,1.250000,-4.249999,-12.000008,1.250000,-4.250000,-11.999998,1.250000,-6.750000,25.999998,6.750000,1.250000,25.999998,6.750000,3.750000,-12.000002,6.750000,3.750000,-11.999992,6.750000,1.249999,26.000010,9.250000,1.250000,25.999987,9.250000,3.750000,-12.000008,9.250000,3.749999,-11.999998,9.250000,1.250000,25.999998,-9.250000,1.250000,25.999998,-9.250000,3.750000,-12.000002,-9.250000,3.750000,-11.999992,-9.250000,1.250000,26.000010,-6.750000,1.250001,25.999987,-6.750000,3.750001,-12.000008,-6.750000,3.750000,-11.999998,-6.750000,1.250000],
"morphTargets": [],
"normals": [1.000000,0.000000,0.000000,0.133335,-0.670461,-0.729820,-0.142003,0.713889,-0.685690,-1.000000,0.000000,0.000000,0.261605,-0.631550,-0.729820,-0.278542,0.672475,-0.685690,0.379772,-0.568377,-0.729820,-0.404370,0.605213,-0.685690,0.483383,-0.483383,-0.729820,-0.514664,0.514695,-0.685690,0.568377,-0.379772,-0.729820,-0.605213,0.404370,-0.685690,-0.382672,-0.923856,0.000000,0.382672,0.923856,0.000000,0.195074,0.980773,0.000000,-0.195074,-0.980773,0.000000,0.683584,0.000000,-0.729820,-0.727866,0.000000,-0.685690,0.195074,-0.980773,0.000000,-0.195074,0.980773,0.000000,-0.631550,-0.261605,0.729820,0.672475,0.278542,0.685690,-0.568377,-0.379772,0.729820,0.605213,0.404370,0.685690,-0.483383,-0.483383,0.729820,0.514664,0.514664,0.685690,-0.831446,0.555559,0.000000,0.831446,-0.555559,0.000000,0.923856,-0.382672,0.000000,-0.923856,0.382672,0.000000,-0.980773,0.195074,0.000000,0.980773,-0.195074,0.000000,0.000000,0.683584,-0.729820,0.000000,-0.727866,-0.685690,0.980773,0.195074,0.000000,-0.980773,-0.195074,0.000000,0.261605,-0.631550,0.729820,-0.278542,0.672475,0.685690,0.379772,-0.568377,0.729820,-0.404370,0.605213,0.685690,0.483383,-0.483383,0.729820,-0.514664,0.514664,0.685690,-0.555559,-0.831446,0.000000,0.555559,0.831446,0.000000,-0.631550,0.261605,-0.729820,0.672475,-0.278542,-0.685690,0.683584,0.000000,0.729820,-0.727866,0.000000,0.685690,-0.382672,0.923856,0.000000,0.382672,-0.923856,0.000000,0.568377,0.379772,0.729820,-0.605213,-0.404370,0.685690,0.707083,-0.707083,0.000000,-0.707083,0.707083,0.000000,-0.605213,-0.404370,-0.685690,0.672475,-0.278542,0.685690,0.000000,-0.727866,0.685690,0.514664,0.514664,-0.685690,0.605213,0.404370,-0.685690,0.672475,0.278542,-0.685690,-0.605213,0.404370,0.685690,-0.142003,0.713889,0.685690,0.133335,-0.670461,0.729820,0.568377,-0.379772,0.729820,-0.631550,-0.261605,-0.729820,-0.568377,-0.379772,-0.729820,-0.483383,-0.483383,-0.729820,0.000000,0.683584,0.729820,-0.631550,0.261605,0.729820,0.568377,0.379772,-0.729820,0.577349,0.000000,-0.816492,0.577349,-0.816492,0.000000,-0.577349,-0.816492,0.000000,-0.577349,0.000000,-0.816492,0.577349,0.816492,0.000000,-0.577349,0.816492,0.000000,-0.577349,0.000000,0.816492,0.577349,0.000000,0.816492,0.577349,-0.577349,-0.577349,0.577349,-0.577349,0.577349,-0.577349,-0.577349,0.577349,-0.577319,-0.577349,-0.577349,0.577349,0.577349,-0.577319,-0.577349,0.577349,-0.577349,-0.577349,0.577349,0.577349,0.577319,0.577349,0.577349],
"colors": [],
"uvs": [[]],
"faces": [35,0,31,32,63,0,0,1,2,3,35,31,30,33,32,0,1,4,5,2,35,30,29,34,33,0,4,6,7,5,35,29,28,35,34,0,6,8,9,7,35,28,27,36,35,0,8,10,11,9,35,27,26,37,36,0,10,12,13,11,35,25,26,37,38,0,14,12,13,15,35,25,24,39,38,0,14,16,17,15,35,24,23,40,39,0,16,18,19,17,35,22,23,40,41,0,20,18,19,21,35,21,22,41,42,0,22,20,21,23,35,20,21,42,43,0,24,22,23,25,35,19,20,43,44,0,26,24,25,27,35,19,18,45,44,0,26,28,29,27,35,17,18,45,46,0,30,28,29,31,35,17,16,47,46,0,30,32,33,31,35,16,15,48,47,0,32,34,35,33,35,14,15,48,49,0,36,34,35,37,35,13,14,49,50,0,38,36,37,39,35,12,13,50,51,0,40,38,39,41,35,11,12,51,52,0,42,40,41,43,35,11,10,53,52,0,42,44,45,43,35,10,9,54,53,0,44,14,15,45,35,8,9,54,55,0,46,14,15,47,35,7,8,55,56,0,18,46,47,19,35,7,6,57,56,0,18,48,49,19,35,5,6,57,58,0,50,48,49,51,35,4,5,58,59,0,52,50,51,53,35,4,3,60,59,0,52,26,27,53,35,2,3,60,61,0,28,26,27,29,35,2,1,62,61,0,28,30,31,29,35,0,1,62,63,0,0,30,31,3,35,63,62,65,64,0,3,31,31,3,35,61,62,65,66,0,29,31,31,29,35,61,60,67,66,0,29,27,27,29,35,59,60,67,68,0,53,27,27,53,35,59,58,69,68,0,53,51,54,53,35,58,57,70,69,0,51,49,49,54,35,56,57,70,71,0,19,49,49,19,35,56,55,72,71,0,19,47,17,19,35,55,54,73,72,0,47,15,15,17,35,53,54,73,74,0,45,15,15,55,35,52,53,74,75,0,43,45,55,43,35,52,51,76,75,0,43,41,9,43,35,51,50,77,76,0,41,39,7,9,35,50,49,78,77,0,39,37,5,7,35,49,48,79,78,0,37,35,35,5,35,47,48,79,80,0,33,35,35,56,35,46,47,80,81,0,31,33,56,31,35,46,45,82,81,0,31,29,29,31,35,44,45,82,83,0,27,29,29,27,35,44,43,84,83,0,27,25,57,27,35,43,42,85,84,0,25,23,58,57,35,42,41,86,85,0,23,21,59,58,35,41,40,87,86,0,21,19,19,59,35,39,40,87,88,0,17,19,19,47,35,38,39,88,89,0,15,17,47,15,35,38,37,90,89,0,15,13,13,15,35,36,37,90,91,0,11,13,13,60,35,35,36,91,92,0,9,11,60,41,35,34,35,92,93,0,7,9,41,39,35,33,34,93,94,0,5,7,39,37,35,32,33,94,95,0,2,5,37,61,35,63,32,95,64,0,3,2,61,3,35,31,0,127,96,0,1,0,0,62,35,30,31,96,97,0,4,1,62,36,35,29,30,97,98,0,6,4,36,38,35,28,29,98,99,0,8,6,38,40,35,27,28,99,100,0,10,8,40,63,35,26,27,100,101,0,12,10,63,12,35,26,25,102,101,0,12,14,14,12,35,24,25,102,103,0,16,14,14,46,35,23,24,103,104,0,18,16,46,18,35,23,22,105,104,0,18,20,64,18,35,22,21,106,105,0,20,22,65,64,35,21,20,107,106,0,22,24,66,65,35,20,19,108,107,0,24,26,26,66,35,18,19,108,109,0,28,26,26,28,35,18,17,110,109,0,28,30,30,28,35,16,17,110,111,0,32,30,30,67,35,15,16,111,112,0,34,32,67,34,35,15,14,113,112,0,34,36,4,34,35,14,13,114,113,0,36,38,6,4,35,13,12,115,114,0,38,40,8,6,35,12,11,116,115,0,40,42,42,8,35,10,11,116,117,0,44,42,42,68,35,9,10,117,118,0,14,44,68,14,35,9,8,119,118,0,14,46,16,14,35,8,7,120,119,0,46,18,18,16,35,6,7,120,121,0,48,18,18,48,35,6,5,122,121,0,48,50,69,48,35,5,4,123,122,0,50,52,52,69,35,3,4,123,124,0,26,52,52,26,35,3,2,125,124,0,26,28,28,26,35,1,2,125,126,0,30,28,28,30,35,1,0,127,126,0,30,0,0,30,35,95,96,127,64,0,61,62,0,3,35,94,97,96,95,0,37,36,62,61,35,93,98,97,94,0,39,38,36,37,35,92,99,98,93,0,41,40,38,39,35,91,100,99,92,0,60,63,40,41,35,90,101,100,91,0,13,12,63,60,35,90,101,102,89,0,13,12,14,15,35,88,103,102,89,0,47,46,14,15,35,87,104,103,88,0,19,18,46,47,35,87,104,105,86,0,19,18,64,59,35,86,105,106,85,0,59,64,65,58,35,85,106,107,84,0,58,65,66,57,35,84,107,108,83,0,57,66,26,27,35,82,109,108,83,0,29,28,26,27,35,82,109,110,81,0,29,28,30,31,35,80,111,110,81,0,56,67,30,31,35,79,112,111,80,0,35,34,67,56,35,79,112,113,78,0,35,34,4,5,35,78,113,114,77,0,5,4,6,7,35,77,114,115,76,0,7,6,8,9,35,76,115,116,75,0,9,8,42,43,35,74,117,116,75,0,55,68,42,43,35,73,118,117,74,0,15,14,68,55,35,73,118,119,72,0,15,14,16,17,35,72,119,120,71,0,17,16,18,19,35,70,121,120,71,0,49,48,18,19,35,70,121,122,69,0,49,48,69,54,35,69,122,123,68,0,54,69,52,53,35,67,124,123,68,0,27,26,52,53,35,67,124,125,66,0,27,26,28,29,35,65,126,125,66,0,31,30,28,29,35,65,126,127,64,0,31,30,0,3,35,128,129,130,131,1,70,71,72,73,35,132,135,134,133,1,74,75,76,77,35,128,132,133,129,1,70,74,77,71,35,129,133,134,130,1,71,77,76,72,35,130,134,135,131,1,72,76,75,73,35,132,128,131,135,1,74,70,73,75,35,136,137,138,139,1,71,77,76,72,35,140,143,142,141,1,70,73,75,74,35,136,140,141,137,1,71,70,74,77,35,137,141,142,138,1,77,74,75,76,35,138,142,143,139,1,76,75,73,72,35,140,136,139,143,1,70,71,72,73,35,144,145,146,147,1,71,77,76,72,35,148,151,150,149,1,70,73,75,74,35,144,148,149,145,1,71,70,74,77,35,145,149,150,146,1,77,74,75,76,35,146,150,151,147,1,76,75,73,72,35,148,144,147,151,1,70,71,72,73,35,152,153,154,155,1,70,71,72,73,35,156,159,158,157,1,74,75,76,77,35,152,156,157,153,1,70,74,77,71,35,153,157,158,154,1,71,77,76,72,35,154,158,159,155,1,72,76,75,73,35,156,152,155,159,1,74,70,73,75,35,160,161,162,163,2,70,71,72,73,35,164,167,166,165,2,74,75,76,77,35,160,164,165,161,2,70,74,77,71,35,161,165,166,162,2,71,77,76,72,35,162,166,167,163,2,72,76,75,73,35,164,160,163,167,2,74,70,73,75,35,168,169,170,171,2,71,77,76,72,35,172,175,174,173,2,70,73,75,74,35,168,172,173,169,2,71,70,74,77,35,169,173,174,170,2,77,74,75,76,35,170,174,175,171,2,76,75,73,72,35,172,168,171,175,2,70,71,72,73,35,176,177,178,179,2,71,77,76,72,35,180,183,182,181,2,70,73,75,74,35,176,180,181,177,2,71,70,74,77,35,177,181,182,178,2,77,74,75,76,35,178,182,183,179,2,76,75,73,72,35,180,176,179,183,2,70,71,72,73,35,184,185,186,187,2,70,71,72,73,35,188,191,190,189,2,74,75,76,77,35,184,188,189,185,2,70,74,77,71,35,185,189,190,186,2,71,77,76,72,35,186,190,191,187,2,72,76,75,73,35,188,184,187,191,2,74,70,73,75,35,192,193,194,195,3,78,79,80,81,35,196,199,198,197,3,82,83,84,85,35,192,196,197,193,3,78,82,85,79,35,193,197,198,194,3,79,85,84,80,35,194,198,199,195,3,80,84,83,81,35,196,192,195,199,3,82,78,81,83,35,200,201,202,203,4,78,79,80,81,35,204,207,206,205,4,82,83,84,85,35,200,204,205,201,4,78,82,85,79,35,201,205,206,202,4,79,85,84,80,35,202,206,207,203,4,80,84,83,81,35,204,200,203,207,4,82,78,81,83,35,208,209,210,211,5,78,79,80,81,35,212,215,214,213,5,82,83,84,85,35,208,212,213,209,5,78,82,85,79,35,209,213,214,210,5,79,85,84,80,35,210,214,215,211,5,80,84,83,81,35,212,208,211,215,5,82,78,81,83,35,216,217,218,219,6,78,79,80,81,35,220,223,222,221,6,82,83,84,85,35,216,220,221,217,6,78,82,85,79,35,217,221,222,218,6,79,85,84,80,35,218,222,223,219,6,80,84,83,81,35,220,216,219,223,6,82,78,81,83]
}
{
"metadata" :
{
"formatVersion" : 3,
"generatedBy" : "Blender 2.60 Exporter",
"vertices" : 96,
"faces" : 72,
"normals" : 15,
"colors" : 0,
"uvs" : 0,
"materials" : 1,
"morphTargets" : 0
},
"scale" : 1.000000,
"materials": [ {
"DbgColor" : 15658734,
"DbgIndex" : 0,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
},
{
"DbgColor" : 15597568,
"DbgIndex" : 1,
"DbgName" : "base",
"colorAmbient" : [0.0, 0.0, 0.0],
"colorDiffuse" : [0.7304608821868896, 0.8962692618370056, 0.9646862745285034],
"colorSpecular" : [0.6574148838410139, 0.806642582505475, 0.8682178922966344],
"shading" : "Lambert",
"specularCoef" : 50,
"transparency" : 1.0,
"vertexColors" : false
}],
"vertices": [-11.250007,-10.999998,-1.249999,-11.250007,-10.999998,1.250000,-11.249993,11.000002,1.249999,-11.249993,10.999997,-1.250000,-8.750007,-11.000007,-1.249998,-8.750007,-10.999993,1.250001,-8.749993,11.000003,1.249998,-8.749993,10.999998,-1.250000,8.749993,-10.999998,-1.249999,8.749993,-10.999998,1.250000,8.750007,11.000002,1.249999,8.750007,10.999997,-1.250000,11.249993,-11.000007,-1.249998,11.249993,-10.999993,1.250001,11.250007,11.000003,1.249998,11.250007,10.999998,-1.250000,10.999999,-11.250000,-1.249999,10.999999,-11.250000,1.250000,-11.000001,-11.250000,1.250000,-10.999996,-11.250000,-1.249999,11.000006,-8.750000,-1.249998,10.999992,-8.750000,1.250001,-11.000004,-8.750000,1.249999,-10.999999,-8.750000,-1.249999,10.999999,8.750000,-1.250000,10.999999,8.750000,1.249999,-11.000001,8.750000,1.249999,-10.999996,8.750000,-1.250000,11.000006,11.250000,-1.249999,10.999992,11.250000,1.250000,-11.000004,11.250000,1.249998,-10.999999,11.250000,-1.250000,14.999999,12.750000,-1.250000,14.999999,12.750000,1.249999,-15.000002,12.750000,1.249999,-14.999994,12.750000,-1.250000,15.000008,15.250000,-1.249999,14.999990,15.250000,1.250000,-15.000006,15.250000,1.249998,-14.999999,15.250000,-1.250000,14.999999,-15.250000,-1.249999,14.999999,-15.250000,1.250000,-15.000002,-15.250000,1.250000,-14.999994,-15.250000,-1.249999,15.000008,-12.750000,-1.249998,14.999990,-12.750000,1.250001,-15.000006,-12.750000,1.250000,-14.999999,-12.750000,-1.249999,12.749990,-14.999998,-1.249999,12.749990,-14.999998,1.250000,12.750010,15.000003,1.249998,12.750010,14.999995,-1.250001,15.249990,-15.000009,-1.249998,15.249990,-14.999990,1.250001,15.250010,15.000005,1.249998,15.250010,14.999998,-1.250000,-15.250010,-14.999998,-1.249999,-15.250010,-14.999998,1.250000,-15.249990,15.000003,1.249998,-15.249990,14.999995,-1.250001,-12.750010,-15.000009,-1.249998,-12.750010,-14.999990,1.250001,-12.749990,15.000005,1.249998,-12.749990,14.999998,-1.250000,16.749989,-18.999998,-1.249998,16.749989,-18.999998,1.250000,16.750011,19.000002,1.249998,16.750011,18.999992,-1.250001,19.249989,-19.000010,-1.249998,19.249989,-18.999987,1.250001,19.250011,19.000008,1.249998,19.250011,18.999998,-1.250000,-19.250011,-18.999998,-1.249998,-19.250011,-18.999998,1.250000,-19.249989,19.000002,1.249998,-19.249989,18.999992,-1.250001,-16.750011,-19.000010,-1.249998,-16.750011,-18.999987,1.250001,-16.749989,19.000008,1.249998,-16.749989,18.999998,-1.250000,18.999998,-19.250000,-1.249998,18.999998,-19.250000,1.250000,-19.000002,-19.250000,1.250000,-18.999992,-19.250000,-1.249999,19.000010,-16.750000,-1.249998,18.999987,-16.750000,1.250001,-19.000008,-16.750000,1.250000,-18.999998,-16.750000,-1.249999,18.999998,16.750000,-1.250000,18.999998,16.750000,1.249998,-19.000002,16.750000,1.249998,-18.999992,16.750000,-1.250001,19.000010,19.250000,-1.250000,18.999987,19.250000,1.249999,-19.000008,19.250000,1.249998,-18.999998,19.250000,-1.250000],
"morphTargets": [],
"normals": [-0.577349,-0.577349,-0.577349,-0.577349,-0.577349,0.577349,-0.577349,0.577349,0.577349,-0.577349,0.577349,-0.577349,0.577349,-0.577349,-0.577319,0.577349,0.577349,-0.577349,0.577349,0.577349,0.577349,0.577349,-0.577319,0.577349,0.577349,-0.577349,-0.577349,0.577349,-0.577349,0.577349,0.577349,0.577349,-0.577319,0.577319,0.577349,0.577349,-0.577319,-0.577349,-0.577349,-0.577349,0.577319,-0.577349,0.577349,0.577349,0.577319],
"colors": [],
"uvs": [[]],
"faces": [35,0,1,2,3,0,0,1,2,3,35,4,7,6,5,0,4,5,6,7,35,0,4,5,1,0,0,4,7,1,35,1,5,6,2,0,1,7,6,2,35,2,6,7,3,0,2,6,5,3,35,4,0,3,7,0,4,0,3,5,35,8,9,10,11,1,0,1,2,3,35,12,15,14,13,1,4,5,6,7,35,8,12,13,9,1,0,4,7,1,35,9,13,14,10,1,1,7,6,2,35,10,14,15,11,1,2,6,5,3,35,12,8,11,15,1,4,0,3,5,35,16,17,18,19,2,8,9,1,0,35,20,23,22,21,2,10,3,2,11,35,16,20,21,17,2,8,10,11,9,35,17,21,22,18,2,9,11,2,1,35,18,22,23,19,2,1,2,3,0,35,20,16,19,23,2,10,8,0,3,35,24,25,26,27,3,8,9,1,0,35,28,31,30,29,3,10,3,2,11,35,24,28,29,25,3,8,10,11,9,35,25,29,30,26,3,9,11,2,1,35,26,30,31,27,3,1,2,3,0,35,28,24,27,31,3,10,8,0,3,35,32,33,34,35,4,8,9,1,12,35,36,39,38,37,4,10,3,2,11,35,32,36,37,33,4,8,10,11,9,35,33,37,38,34,4,9,11,2,1,35,34,38,39,35,4,1,2,3,12,35,36,32,35,39,4,10,8,12,3,35,40,41,42,43,5,8,9,1,12,35,44,47,46,45,5,10,3,2,11,35,40,44,45,41,5,8,10,11,9,35,41,45,46,42,5,9,11,2,1,35,42,46,47,43,5,1,2,3,12,35,44,40,43,47,5,10,8,12,3,35,48,49,50,51,6,0,1,2,13,35,52,55,54,53,6,4,5,6,7,35,48,52,53,49,6,0,4,7,1,35,49,53,54,50,6,1,7,6,2,35,50,54,55,51,6,2,6,5,13,35,52,48,51,55,6,4,0,13,5,35,56,57,58,59,7,0,1,2,13,35,60,63,62,61,7,4,5,6,7,35,56,60,61,57,7,0,4,7,1,35,57,61,62,58,7,1,7,6,2,35,58,62,63,59,7,2,6,5,13,35,60,56,59,63,7,4,0,13,5,35,64,65,66,67,8,0,1,2,13,35,68,71,70,69,8,4,5,14,7,35,64,68,69,65,8,0,4,7,1,35,65,69,70,66,8,1,7,14,2,35,66,70,71,67,8,2,14,5,13,35,68,64,67,71,8,4,0,13,5,35,72,73,74,75,9,0,1,2,13,35,76,79,78,77,9,4,5,14,7,35,72,76,77,73,9,0,4,7,1,35,73,77,78,74,9,1,7,14,2,35,74,78,79,75,9,2,14,5,13,35,76,72,75,79,9,4,0,13,5,35,80,81,82,83,10,8,9,1,12,35,84,87,86,85,10,10,3,2,11,35,80,84,85,81,10,8,10,11,9,35,81,85,86,82,10,9,11,2,1,35,82,86,87,83,10,1,2,3,12,35,84,80,83,87,10,10,8,12,3,35,88,89,90,91,11,8,9,1,12,35,92,95,94,93,11,10,3,2,11,35,88,92,93,89,11,8,10,11,9,35,89,93,94,90,11,9,11,2,1,35,90,94,95,91,11,1,2,3,12,35,92,88,91,95,11,10,8,12,3]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment