Skip to content

Commit

Permalink
Update app.js
Browse files Browse the repository at this point in the history
  • Loading branch information
davespser authored Dec 5, 2024
1 parent f847eac commit ce4bf12
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions js/app.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,17 @@
// app.js
import { database } from './firebase-config.js';

// Guardar datos en la base de datos
function savePlayerData(playerData) {
database.ref('players/123').set(playerData);
}

// Cargar datos desde la base de datos
function loadPlayerData() {
database.ref('players/123').once('value', (snapshot) => {
console.log(snapshot.val());
});
}// firebase-config.js

// Crear escena de Three.js
const scene = new THREE.Scene();
Expand Down

0 comments on commit ce4bf12

Please sign in to comment.