Started to add a notification div

We just need to correctly implement Jquery and we will be able to show notifications in the game
Also updated npm modules
This commit is contained in:
2024-01-08 23:34:32 +01:00
parent e1f711e03c
commit 02cf36a131
6 changed files with 163 additions and 4 deletions

View File

@@ -3,6 +3,20 @@ import { getCamera } from './cameras/PerspectiveCamera.js';
import {addAssetsOnScene} from './utils/addAssetsOnScene.js';
import * as PlayerMovement from './utils/playerMovement.js';
import * as Animations from './utils/animateMesh.js';
/*TODO*/
import $ from 'jquery'
function showNotification(HTMLText, color){
$("#notification_bar p").html(HTMLText);
$("#notification_bar").css( 'opacity', 0.9 ).animate({
width:320
}, 500);
}
showNotification("oui")
/*TODO*/
let Clock = new THREE.Clock();
THREE.Cache.enabled = true;//So we can request several time the same file without worrying : https://threejs.org/docs/#api/en/loaders/FileLoader