-- Leo's gemini proxy

-- Connecting to git.thebackupbox.net:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini

repo: janusweb
action: commit
revision:
path_from:
revision_from: 6d2e806c95769dd67ac3cc6d98a8a0539511b074:
path_to:
revision_to:

git.thebackupbox.net

janusweb

git://git.thebackupbox.net/janusweb

commit 6d2e806c95769dd67ac3cc6d98a8a0539511b074
Author: James Baicoianu <james_github@baicoianu.com>
Date:   Fri Jun 23 02:07:06 2017 -0700

    Janus object animations

diff --git a/scripts/object.js b/scripts/object.js

index 0642589fd5939b2434b354967c872cf518df9964..

index ..04db73c3f3b8e5c45554ba81c1a323660e72057b 100644

--- a/scripts/object.js
+++ b/scripts/object.js
@@ -42,9 +42,10 @@ elation.require(['janusweb.janusbase', 'janusweb.websurface'], function() {
         this.pickable = false;
         this.collidable = false;
       }
-      if (this.video_id) {
-        elation.events.add(this, 'click', elation.bind(this, this.pauseVideo));
+      if (this.anim_id) {
+        this.setAnimation(this.anim_id);
       }
+
     }
     this.createObject3D = function() {
       if (this.properties.exists === false) return;
@@ -290,12 +291,20 @@ elation.require(['janusweb.janusbase', 'janusweb.websurface'], function() {
       if (srcfactors[this.properties.blend_dest]) {
         blend_dest = srcfactors[this.properties.blend_dest];
       }
+
+      this.extractAnimations(this.objects['3d']);
+
       var scene = this.engine.systems.world.scene['world-3d'];
       if (!this.hasalpha) this.hasalpha = {};
       var hasalpha = this.hasalpha;
       var remove = [];
       var cloneMaterial = true;//(texture !== false);
+      var useSkinning = this.animations && this.animations.length > 0;
+
       this.objects['3d'].traverse(elation.bind(this, function(n) {
+        n.receiveShadow = this.shadows;
+        n.castShadow = this.shadows;
+
         if (n.material) {
           var materials = [];
           if (elation.utils.isArray(n.material)) {
@@ -378,6 +387,7 @@ elation.require(['janusweb.janusbase', 'janusweb.websurface'], function() {
               m.blending = THREE.NormalBlending;
             }
             m.needsUpdate = true;
+            m.skinning = useSkinning;
           }
         } else if (n instanceof THREE.Light) {
           remove.push(n);

-----END OF PAGE-----

-- Response ended

-- Page fetched on Sun Jun 2 16:49:45 2024