Merge branch 'test' of github.com:storytold/GottaGoFast into test

This commit is contained in:
dev committed 2024-03-20 15:09:13 -04:00
commit 8dba6f7ed0
4 files changed
+4 -6

No files matched your search

+2 -4
View File
@@ -72,7 +72,6 @@ class Character {
}
animate(clip) {
console.log(clip);
this.currentAction = this.mixer.clipAction(clip);
this.currentAction.play();
}
@@ -90,10 +89,9 @@ class Character {
}
load_animation(filepath, callback = null) {
let fbxLoader = new FBXLoader();
fbxLoader.load(filepath,
let glbLoader = new GLTFLoader();
glbLoader.load(filepath,
(object) => {
console.log("loaded " + filepath);
let animationAction = this.mixer.clipAction(object.animations[0]);
this.anims.push(animationAction);
if (callback != null) {
+2 -2
View File
@@ -67,7 +67,7 @@ class Scene {
this.scene.add(child);
children_uuids.push(child.uuid);
});
this.characters[character_name].load_animation("/resources/models/fox/hanashi_IdleAnim.fbx", this.play_anim_demo.bind(this));
this.characters[character_name].load_animation("/resources/models/fox/fox_idle.glb", this.play_anim_demo.bind(this));
}
play_anim_demo(character_name) {
@@ -183,7 +183,7 @@ class Scene {
_create_base_lighting() {
const color = 0xFCECE7;
const light = new THREE.AmbientLight(color, 0.8);
const light = new THREE.HemisphereLight(color, 0x8d8d8d, 3.5);
this.scene.add(light);
const directional_light = new THREE.DirectionalLight(color, 3.5);
Binary file not shown.
Binary file not shown.