🐞 fix: Update functions to work, make new game button stay inline

This commit is contained in:
Keith Solomon committed 2025-08-15 18:51:11 -05:00
1 parent 17e925ec8e
commit 428d111cf7
5 files changed
+13 -6

No files matched your search

+2 -2
View File
@@ -17,7 +17,7 @@ session_start();
require_once 'database.php';
// Fetch configuration from the database
$stmt = $db->query('SELECT * FROM configuration');
$stmt = $db->query('SELECT name, value FROM configuration');
$config = $stmt->fetchAll(PDO::FETCH_KEY_PAIR);
if (!isset($_SESSION['scores'])) {
@@ -31,7 +31,7 @@ if (!isset($_SESSION['scores'])) {
$action = $_GET['action'] ?? '';
if ($action === 'roll_dice') {
$event = roll_dice($config);
$event = rollDice($config);
$gameState = checkGameState($config);
if ($gameState !== 'ongoing') {