Permalink
Browse files

Added landing gear to MEteor. Did some mesh improvements.

  • Loading branch information...
1 parent cee28c7 commit f76fc792e6605421223e26e65879706b7bfecda7 @AaronSenese committed Apr 28, 2012
@@ -1,3 +1,18 @@
+define_model('meteor_gear', {
+ info = {
+ scale = 1.0,
+ bounding_radius = 5,
+ lod_pixels = {100},
+ materials = {'default'},
+ },
+ static = function(lod)
+ set_material('default', 0.8,0.8,0.8,1, .3,.3,.3,5, 0,0,0)
+ use_material('default')
+ texture('ramjetcraft.png')
+ load_obj('meteor_gear.obj')
+ end
+})
+
define_model('meteor', {
info = {
scale = 1.2,
@@ -52,12 +67,10 @@ define_model('meteor', {
end,
dynamic = function(lod)
--no point in visible gear on lowest lod
- --if lod > 1 then
- --gear animation. In Blender we have determined that the gear
- --should be translated 0.5 units downwards.
- -- local gearpos = get_animation_position('WHEEL_STATE')
- -- call_model('gear', v(0,-0.5 * gearpos,0), v(1,0,0), v(0,1,0), 1.0)
- --end
+ if lod > 1 then
+ local gearpos = get_animation_position('WHEEL_STATE')
+ call_model('meteor_gear', v(0,.5 * (1-gearpos),2.56 * (1-gearpos)), v(1,0,0), v(0,1-.4*gearpos,.2-.2*gearpos), 1.0)
+ end
--lights visible when the craft is docking, landing
--or landing gear is down
Oops, something went wrong.

0 comments on commit f76fc79

Please sign in to comment.