feat(match3): Verbesserung der Drag & Drop-Funktionalität und Hinzufügen von Soundeffekten
- Anpassungen an der Match3Game-Komponente zur Verbesserung der Drag & Drop-Interaktionen, einschließlich neuer Event-Handler für Maus- und Touch-Eingaben. - Einführung von Soundeffekten für Bewegungen, Bomben, Raketen und Regenbogen-Animationen zur Steigerung des Spielerlebnisses. - Erweiterung der CSS-Animationen für Tiles, um neue visuelle Effekte bei Bewegungen und Erscheinen zu implementieren. - Aktualisierung der Animationseffekte für Explosionen und andere Spielereignisse zur Verbesserung der Benutzeroberfläche.
This commit is contained in:
@@ -296,7 +296,8 @@ class Match3Service {
|
|||||||
|
|
||||||
if (isCompleted) {
|
if (isCompleted) {
|
||||||
// Nur wenn das Level abgeschlossen ist, setze currentLevel auf das nächste Level
|
// Nur wenn das Level abgeschlossen ist, setze currentLevel auf das nächste Level
|
||||||
newCurrentLevel = levelsCompleted + 1;
|
// WICHTIG: currentLevel ist das nächste zu spielende Level (nicht das letzte abgeschlossene)
|
||||||
|
newCurrentLevel = Math.max(userProgress.currentLevel, levelsCompleted + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
await userProgress.update({
|
await userProgress.update({
|
||||||
|
|||||||
@@ -42,7 +42,32 @@ const syncModels = async (models) => {
|
|||||||
|
|
||||||
// Intelligente Schema-Synchronisation - prüft ob Updates nötig sind
|
// Intelligente Schema-Synchronisation - prüft ob Updates nötig sind
|
||||||
const syncModelsWithUpdates = async (models) => {
|
const syncModelsWithUpdates = async (models) => {
|
||||||
console.log('🔍 Prüfe ob Schema-Updates nötig sind...');
|
// Prüfe ob wir im Entwicklungsmodus sind
|
||||||
|
if (process.env.STAGE !== 'dev') {
|
||||||
|
console.log('🚫 Nicht im Entwicklungsmodus - überspringe Schema-Updates');
|
||||||
|
console.log('📊 Aktueller Stage:', process.env.STAGE || 'nicht gesetzt');
|
||||||
|
console.log('💡 Setze STAGE=dev in der .env Datei für automatische Schema-Updates');
|
||||||
|
console.log('🔒 Sicherheitsmodus: Schema-Updates sind deaktiviert');
|
||||||
|
|
||||||
|
// Normale Synchronisation ohne Updates
|
||||||
|
for (const model of Object.values(models)) {
|
||||||
|
await model.sync({ alter: false, force: false });
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Zusätzliche Sicherheitsabfrage für Produktionsumgebungen
|
||||||
|
if (process.env.NODE_ENV === 'production' && process.env.STAGE !== 'dev') {
|
||||||
|
console.log('🚨 PRODUKTIONSWARNUNG: Schema-Updates sind in Produktionsumgebungen deaktiviert!');
|
||||||
|
console.log('🔒 Verwende nur normale Synchronisation ohne Schema-Änderungen');
|
||||||
|
|
||||||
|
for (const model of Object.values(models)) {
|
||||||
|
await model.sync({ alter: false, force: false });
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log('🔍 Entwicklungsmodus aktiv - prüfe ob Schema-Updates nötig sind...');
|
||||||
|
|
||||||
try {
|
try {
|
||||||
// Prüfe ob neue Felder existieren müssen
|
// Prüfe ob neue Felder existieren müssen
|
||||||
|
|||||||
@@ -16,6 +16,18 @@ import updateExistingMatch3Levels from './updateExistingMatch3Levels.js';
|
|||||||
|
|
||||||
const syncDatabase = async () => {
|
const syncDatabase = async () => {
|
||||||
try {
|
try {
|
||||||
|
// Zeige den aktuellen Stage an
|
||||||
|
const currentStage = process.env.STAGE || 'nicht gesetzt';
|
||||||
|
console.log(`🚀 Starte Datenbank-Synchronisation (Stage: ${currentStage})`);
|
||||||
|
|
||||||
|
if (currentStage !== 'dev') {
|
||||||
|
console.log('⚠️ WARNUNG: Automatische Schema-Updates sind deaktiviert');
|
||||||
|
console.log('💡 Setze STAGE=dev in der .env Datei für automatische Schema-Updates');
|
||||||
|
console.log('🔒 Produktionsmodus: Nur normale Synchronisation ohne Schema-Änderungen');
|
||||||
|
} else {
|
||||||
|
console.log('✅ Entwicklungsmodus aktiv - Schema-Updates sind aktiviert');
|
||||||
|
}
|
||||||
|
|
||||||
console.log("Initializing database schemas...");
|
console.log("Initializing database schemas...");
|
||||||
await initializeDatabase();
|
await initializeDatabase();
|
||||||
|
|
||||||
|
|||||||
379
frontend/public/assets/index-B4fysdFj.js
Normal file
379
frontend/public/assets/index-B4fysdFj.js
Normal file
File diff suppressed because one or more lines are too long
1
frontend/public/assets/index-B7qXuEZt.css
Normal file
1
frontend/public/assets/index-B7qXuEZt.css
Normal file
File diff suppressed because one or more lines are too long
@@ -4,8 +4,8 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<title>YourPart</title>
|
<title>YourPart</title>
|
||||||
<script type="module" crossorigin src="/assets/index-C2z2YL6l.js"></script>
|
<script type="module" crossorigin src="/assets/index-B4fysdFj.js"></script>
|
||||||
<link rel="stylesheet" crossorigin href="/assets/index-BLkCbvUa.css">
|
<link rel="stylesheet" crossorigin href="/assets/index-B7qXuEZt.css">
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|||||||
BIN
frontend/public/sounds/match3/bomb.wav
Normal file
BIN
frontend/public/sounds/match3/bomb.wav
Normal file
Binary file not shown.
BIN
frontend/public/sounds/match3/falling.wav
Normal file
BIN
frontend/public/sounds/match3/falling.wav
Normal file
Binary file not shown.
BIN
frontend/public/sounds/match3/move.wav
Normal file
BIN
frontend/public/sounds/match3/move.wav
Normal file
Binary file not shown.
BIN
frontend/public/sounds/match3/rainbow.wav
Normal file
BIN
frontend/public/sounds/match3/rainbow.wav
Normal file
Binary file not shown.
BIN
frontend/public/sounds/match3/roket.wav
Normal file
BIN
frontend/public/sounds/match3/roket.wav
Normal file
Binary file not shown.
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user