From 2cfa672890b70de6212f4e9bb7e85e139e9c017f Mon Sep 17 00:00:00 2001 From: Flatlogic Bot Date: Thu, 26 Feb 2026 01:39:06 +0000 Subject: [PATCH] Autosave: 20260226-013905 --- admin.php | 205 +++++++++-- db/migrate_status_rules.php | 30 ++ gm_console.php | 17 +- includes/status_helper.php | 53 +++ index.php | 662 ++++++++++-------------------------- 5 files changed, 458 insertions(+), 509 deletions(-) create mode 100644 db/migrate_status_rules.php create mode 100644 includes/status_helper.php diff --git a/admin.php b/admin.php index 51624d9..e6c5c9c 100644 --- a/admin.php +++ b/admin.php @@ -41,7 +41,6 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['action']) && $_POST[' $slug = $_POST['slug']; $icon = $_POST['icon']; $description = $_POST['description']; - $is_blinking = isset($_POST['is_blinking']) ? 1 : 0; $modifier_ids = isset($_POST['modifiers']) ? $_POST['modifiers'] : []; $image_url = null; @@ -119,13 +118,43 @@ if (isset($_GET['delete_status'])) { exit; } +// Handle Status Rules CRUD +if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['action']) && $_POST['action'] === 'upsert_status_rule') { + $id = (int)$_POST['id']; + $name = $_POST['name']; + $status_id = (int)$_POST['status_id']; + $object_type_id = $_POST['object_type_id'] !== "" ? (int)$_POST['object_type_id'] : null; + $priority = (int)$_POST['priority']; + $is_active = isset($_POST['is_active']) ? 1 : 0; + $condition_type = $_POST['condition_type']; + $min_control_value = $_POST['min_control_value'] !== "" ? (float)$_POST['min_control_value'] : null; + $max_control_value = $_POST['max_control_value'] !== "" ? (float)$_POST['max_control_value'] : null; + $description = $_POST['description']; + + if ($id > 0) { + $stmt = $db->prepare("UPDATE celestial_object_status_rules SET name = ?, status_id = ?, object_type_id = ?, priority = ?, is_active = ?, condition_type = ?, min_control_value = ?, max_control_value = ?, description = ? WHERE id = ?"); + $stmt->execute([$name, $status_id, $object_type_id, $priority, $is_active, $condition_type, $min_control_value, $max_control_value, $description, $id]); + } else { + $stmt = $db->prepare("INSERT INTO celestial_object_status_rules (name, status_id, object_type_id, priority, is_active, condition_type, min_control_value, max_control_value, description) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)"); + $stmt->execute([$name, $status_id, $object_type_id, $priority, $is_active, $condition_type, $min_control_value, $max_control_value, $description]); + } + header("Location: admin.php?tab=status_rules&success=1"); + exit; +} + +if (isset($_GET['delete_status_rule'])) { + $id = (int)$_GET['delete_status_rule']; + $db->prepare("DELETE FROM celestial_object_status_rules WHERE id = ?")->execute([$id]); + header("Location: admin.php?tab=status_rules&success=1"); + exit; +} + // Handle Settlement Type CRUD if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['action']) && $_POST['action'] === 'upsert_settlement_type') { $id = (int)$_POST['id']; $name = $_POST['name']; $slug = $_POST['slug']; $description = $_POST['description']; - $is_blinking = isset($_POST['is_blinking']) ? 1 : 0; if ($id > 0) { $stmt = $db->prepare("UPDATE settlement_types SET name = ?, slug = ?, description = ? WHERE id = ?"); @@ -152,7 +181,6 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['action']) && $_POST[' $slug = $_POST['slug']; $type = $_POST['type']; $description = $_POST['description']; - $is_blinking = isset($_POST['is_blinking']) ? 1 : 0; if ($id > 0) { $stmt = $db->prepare("UPDATE modifiers SET name = ?, slug = ?, type = ?, description = ? WHERE id = ?"); @@ -232,7 +260,6 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['action']) && $_POST[' $slug = $_POST['slug']; $icon = $_POST['icon']; $description = $_POST['description']; - $is_blinking = isset($_POST['is_blinking']) ? 1 : 0; $show_in_header = isset($_POST["show_in_header"]) ? 1 : 0; $image_url = null; @@ -279,7 +306,6 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['action']) && $_POST[' $name = $_POST['name']; $slug = $_POST['slug']; $description = $_POST['description']; - $is_blinking = isset($_POST['is_blinking']) ? 1 : 0; if ($id > 0) { $stmt = $db->prepare("UPDATE lootboxes SET name = ?, slug = ?, description = ? WHERE id = ?"); @@ -359,6 +385,7 @@ if (isset($_GET["delete_project_log"])) { $users_list = []; $objects_list = []; $statuses_list = []; +$status_rules_list = []; $settlement_types_list = []; $modifiers_list = []; $factions_list = []; @@ -379,6 +406,14 @@ if ($tab === 'users') { $modifiers_list = $db->query("SELECT * FROM modifiers ORDER BY type, name ASC")->fetchAll(); } elseif ($tab === 'statuses') { $statuses_list = $db->query("SELECT * FROM celestial_object_statuses ORDER BY name ASC")->fetchAll(); +} elseif ($tab === 'status_rules') { + $status_rules_list = $db->query("SELECT r.*, s.name as status_name, s.color as status_color, t.name as object_type_name + FROM celestial_object_status_rules r + JOIN celestial_object_statuses s ON r.status_id = s.id + LEFT JOIN celestial_object_types t ON r.object_type_id = t.id + ORDER BY r.priority DESC, r.name ASC")->fetchAll(); + $statuses_list = $db->query("SELECT id, name FROM celestial_object_statuses ORDER BY name ASC")->fetchAll(); + $objects_list = $db->query("SELECT id, name FROM celestial_object_types ORDER BY name ASC")->fetchAll(); } elseif ($tab === 'settlement_types') { $settlement_types_list = $db->query("SELECT * FROM settlement_types ORDER BY name ASC")->fetchAll(); } elseif ($tab === 'modifiers') { @@ -408,8 +443,6 @@ if ($tab === 'users') { $lb['items'] = $stmt_i->fetchAll(); } unset($lb); -} elseif ($tab === "project_logs") { - $project_logs_list = $db->query("SELECT * FROM project_logs ORDER BY created_at DESC")->fetchAll(); } ?> @@ -496,6 +529,7 @@ if ($tab === 'users') { Utilisateurs Objets Célestes Bonus & Malus + Règles Statuts Statuts / États Types d'Établissements Factions @@ -698,6 +732,132 @@ if ($tab === 'users') { + +

Règles d'Activation des Statuts

+
+

Créer / Modifier une Règle

+
+ + + +
+
+ + +
+
+ + +
+
+ + +
+
+ +
+
+ + +
+
+ + +
+
+ + +
+
+ + +
+
+ +
+ + Activée +
+
+
+ +
+ + +
+ + + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + '; ?> + +
PrioritéNom de la RègleStatut AppliquéCibleConditionStatutActions
+ +
+ +
+
Global'; ?> + + + + + + Actif + + Inactif + + + + Suppr +
Aucune règle configurée.
+

Statuts / États

@@ -718,13 +878,13 @@ if ($tab === 'users') {
+ +
- -
@@ -934,16 +1094,6 @@ if ($tab === 'users') {
-
-
- - -
-
- - -
-
@@ -1045,7 +1195,7 @@ if ($tab === 'users') { document.getElementById('logForm').reset(); } - +

Système de Lootboxes

Créer / Modifier une Lootbox

@@ -1210,6 +1360,21 @@ if ($tab === 'users') { document.getElementById('st_is_blinking').checked = false; } + function editStatusRule(data) { + document.getElementById('rule_id').value = data.id; + document.getElementById('rule_name').value = data.name; + document.getElementById('rule_status_id').value = data.status_id; + document.getElementById('rule_object_type_id').value = data.object_type_id || ''; + document.getElementById('rule_priority').value = data.priority; + document.getElementById('rule_is_active').checked = data.is_active == 1; + document.getElementById('rule_condition_type').value = data.condition_type; + document.getElementById('rule_min_val').value = data.min_control_value || ''; + document.getElementById('rule_max_val').value = data.max_control_value || ''; + document.getElementById('rule_desc').value = data.description || ''; + window.scrollTo(0,0); + } + function resetStatusRuleForm() { document.getElementById('statusRuleForm').reset(); document.getElementById('rule_id').value = 0; document.getElementById('rule_is_active').checked = true; } + function editSettlementType(data) { document.getElementById('set_t_id').value = data.id; document.getElementById('set_t_name').value = data.name; diff --git a/db/migrate_status_rules.php b/db/migrate_status_rules.php new file mode 100644 index 0000000..9cf77ae --- /dev/null +++ b/db/migrate_status_rules.php @@ -0,0 +1,30 @@ +exec($sql); + echo "Table celestial_object_status_rules created successfully.\n"; +} catch (PDOException $e) { + echo "Error creating table: " . $e->getMessage() . "\n"; +} + diff --git a/gm_console.php b/gm_console.php index 11a4de9..1bf82ef 100644 --- a/gm_console.php +++ b/gm_console.php @@ -269,26 +269,13 @@ if ($view === 'sector') { } function getStatusColor($status, $type, $statuses_map, $object_types_map) { - -function isStatusBlinking($status, $statuses_map) { - return ($statuses_map[$status]["is_blinking"] ?? 0) == 1; -} - if ($type === 'empty') return 'rgba(255,255,255,0.05)'; - -function isStatusBlinking($status, $statuses_map) { - return ($statuses_map[$status]["is_blinking"] ?? 0) == 1; -} - return $statuses_map[$status]['color'] ?? 'rgba(255,255,255,0.05)'; - -function isStatusBlinking($status, $statuses_map) { - return ($statuses_map[$status]["is_blinking"] ?? 0) == 1; -} + if ($type === "empty") return "rgba(255,255,255,0.05)"; + return $statuses_map[$status]["color"] ?? "rgba(255,255,255,0.05)"; } function isStatusBlinking($status, $statuses_map) { return ($statuses_map[$status]["is_blinking"] ?? 0) == 1; } -?> diff --git a/includes/status_helper.php b/includes/status_helper.php new file mode 100644 index 0000000..ae59034 --- /dev/null +++ b/includes/status_helper.php @@ -0,0 +1,53 @@ += $min && $val <= $max) $match = true; + break; + case 'terrestrial_control': + $val = (float)($planet['terrestrial_control'] ?? 0); + $min = $rule['min_control_value'] !== null ? (float)$rule['min_control_value'] : -1; + $max = $rule['max_control_value'] !== null ? (float)$rule['max_control_value'] : 101; + if ($val >= $min && $val <= $max) $match = true; + break; + case 'uncontrolled': + $orb = (float)($planet['orbital_control'] ?? 0); + $terr = (float)($planet['terrestrial_control'] ?? 0); + if ($orb == 0 && $terr == 0) $match = true; + break; + } + + if ($match) { + // Find status slug from id + // We should probably pass the status slug in the rule too or join it. + return $rule['status_slug']; + } + } + + return $planet['status']; +} diff --git a/index.php b/index.php index 9ea3881..58a4850 100644 --- a/index.php +++ b/index.php @@ -70,7 +70,7 @@ if ($view === 'sector') { } // Fetch Cities - unset($slot_data); + unset($slot_data); $stmt = $db->prepare("SELECT c.*, st.name as type_name FROM cities c LEFT JOIN settlement_types st ON c.settlement_type_id = st.id @@ -118,7 +118,7 @@ if ($view === 'sector') { } } } - unset($slot_data); + unset($slot_data); $stmt = $db->prepare("SELECT name FROM sectors WHERE id = ?"); $stmt->execute([$sector_id]); @@ -139,15 +139,7 @@ if ($view === 'sector') { } function getStatusColor($status, $statuses_map) { - -function isStatusBlinking($status, $statuses_map) { - return ($statuses_map[$status]["is_blinking"] ?? 0) == 1; -} return $statuses_map[$status]['color'] ?? 'rgba(255,255,255,0.05)'; - -function isStatusBlinking($status, $statuses_map) { - return ($statuses_map[$status]["is_blinking"] ?? 0) == 1; -} } function isStatusBlinking($status, $statuses_map) { @@ -198,406 +190,131 @@ function isStatusBlinking($status, $statuses_map) { justify-content: center; cursor: pointer; transition: all 0.2s; - overflow: hidden; - } - .slot:hover { background: rgba(136, 192, 208, 0.1); border-color: #88c0d0; z-index: 10; } - .slot-id { position: absolute; top: 5px; left: 8px; font-size: 9px; color: #4c566a; font-weight: bold; z-index: 5; } - - .slot-icons { - position: absolute; - top: 5px; - right: 5px; - display: flex; - flex-direction: column; - gap: 5px; - align-items: center; - z-index: 6; } + .slot:hover { border-color: #88c0d0; background: rgba(136, 192, 208, 0.1); } + .slot.empty { cursor: default; } + .slot.empty:hover { border-color: #3b4252; background: rgba(46, 52, 64, 0.3); } - .faction-icon-sm { - width: 22px; - height: 22px; - filter: drop-shadow(0 0 2px rgba(0,0,0,0.8)); - display: flex; - align-items: center; - justify-content: center; - } - - .info-icon-sm { - width: 20px; - height: 20px; - font-size: 14px; - color: #ebcb8b; - filter: drop-shadow(0 0 2px rgba(0,0,0,0.8)); - display: flex; - align-items: center; - justify-content: center; - } + .object-image { width: 100%; height: 100%; object-fit: contain; } + .object-icon-container { font-size: 40px; margin-bottom: 10px; width: 60px; height: 60px; display: flex; align-items: center; justify-content: center; position: relative; } + .object-name { font-size: 12px; font-weight: bold; text-align: center; padding: 0 5px; color: #d8dee9; } - .object-icon { - position: absolute; - top: 50%; - left: 50%; - transform: translate(-50%, -50%); - width: 90px; - height: 90px; - display: flex; - align-items: center; - justify-content: center; - transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); - line-height: 1; - font-size: 90px; - z-index: 2; - } - .object-image { width: 90px; height: 90px; object-fit: contain; margin: 0; } - .slot:hover .object-icon { transform: translate(-50%, -50%) scale(1.1); } - - .object-name { - position: absolute; - bottom: 8px; - font-size: 11px; - font-weight: bold; - color: #eceff4; - text-align: center; - width: 95%; - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; - z-index: 3; - text-shadow: 0 0 4px rgba(0,0,0,0.8); - } - - .sector-grid { - display: grid; - grid-template-columns: repeat(6, 180px); - grid-template-rows: repeat(6, 180px); - gap: 15px; - } - .sector-card { background: rgba(10, 15, 30, 0.95); border: 1px solid #2d3545; padding: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-decoration: none; color: #fff; transition: all 0.2s; position: relative; width: 180px; height: 180px; box-sizing: border-box; } - .sector-card:hover { border-color: #88c0d0; background: #1a202c; transform: translateY(-3px); } + .sector-grid { display: grid; grid-template-columns: repeat(6, 140px); grid-template-rows: repeat(6, 140px); gap: 10px; } + .sector-card { background: rgba(46, 52, 64, 0.4); border: 1px solid #3b4252; display: flex; flex-direction: column; align-items: center; justify-content: center; text-decoration: none; color: #fff; transition: all 0.2s; } + .sector-card:hover { border-color: #88c0d0; background: rgba(136, 192, 208, 0.1); transform: translateY(-2px); } .sector-card.empty { opacity: 0.6; } - - .mini-map { display: grid; grid-template-columns: repeat(6, 12px); gap: 4px; margin-bottom: 15px; background: #000; padding: 6px; border-radius: 2px; } - .mini-dot { width: 12px; height: 12px; border-radius: 1px; } + .mini-map { display: grid; grid-template-columns: repeat(6, 4px); grid-template-rows: repeat(6, 4px); gap: 1px; margin-bottom: 10px; } + .mini-dot { width: 4px; height: 4px; border-radius: 50%; } - /* MODAL STYLES */ - .modal-overlay { - display: none; - position: fixed; - top: 0; left: 0; - width: 100%; height: 100%; - background: rgba(0, 0, 0, 0.85); - backdrop-filter: blur(5px); - z-index: 2000; - align-items: center; - justify-content: center; - } - .modal-container { - background: #0f172a; - border: 1px solid #1e293b; - border-radius: 12px; - width: 600px; - max-height: 90vh; - overflow-y: auto; - position: relative; - box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5); - } - .modal-header { - padding: 20px; - border-bottom: 1px solid #1e293b; - display: flex; - justify-content: space-between; - align-items: center; - background: rgba(30, 41, 59, 0.5); - } - .modal-header h2 { margin: 0; font-size: 20px; color: #88c0d0; } - .modal-close { - background: none; border: none; color: #8c92a3; font-size: 24px; cursor: pointer; - transition: color 0.2s; - } + .legend { margin-top: 30px; display: flex; gap: 20px; flex-wrap: wrap; justify-content: center; background: rgba(0,0,0,0.5); padding: 15px; border-radius: 5px; border: 1px solid #2d3545; } + .legend-item { display: flex; align-items: center; gap: 8px; font-size: 11px; color: #8c92a3; } + .dot { width: 10px; height: 10px; border-radius: 50%; } + + .admin-footer { position: fixed; bottom: 20px; right: 20px; display: flex; gap: 10px; } + .btn-mj { background: #bf616a; color: #fff; padding: 10px 15px; border-radius: 5px; text-decoration: none; font-weight: bold; font-size: 12px; display: flex; align-items: center; gap: 8px; box-shadow: 0 4px 15px rgba(191, 97, 106, 0.3); transition: all 0.2s; } + .btn-adm { background: #5e81ac; color: #fff; padding: 10px 15px; border-radius: 5px; text-decoration: none; font-weight: bold; font-size: 12px; display: flex; align-items: center; gap: 8px; box-shadow: 0 4px 15px rgba(94, 129, 172, 0.3); transition: all 0.2s; } + .btn-mj:hover, .btn-adm:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.4); filter: brightness(1.1); } + + /* Modal Styles */ + .modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.85); backdrop-filter: blur(5px); display: none; align-items: center; justify-content: center; z-index: 1000; } + .modal-container { background: #1a202c; border: 1px solid #2d3545; width: 600px; max-width: 90%; border-radius: 8px; box-shadow: 0 20px 50px rgba(0,0,0,0.5); overflow: hidden; } + .modal-header { padding: 20px; border-bottom: 1px solid #2d3545; display: flex; justify-content: space-between; align-items: flex-start; background: #242c3d; } + .modal-header h2 { margin: 0; color: #ebcb8b; font-size: 24px; } + .modal-close { background: none; border: none; color: #8c92a3; font-size: 30px; cursor: pointer; line-height: 1; } .modal-close:hover { color: #fff; } - .modal-body { padding: 25px; } - .planet-hero { - display: flex; - gap: 25px; - margin-bottom: 25px; - align-items: center; - } - .planet-preview-img { - width: 120px; - height: 120px; - object-fit: contain; - filter: drop-shadow(0 0 15px rgba(136, 192, 208, 0.3)); - } + .modal-body { padding: 25px; max-height: 80vh; overflow-y: auto; } + + .planet-hero { display: flex; gap: 20px; margin-bottom: 25px; } + .planet-preview-img { width: 120px; height: 120px; object-fit: contain; background: rgba(0,0,0,0.3); border-radius: 10px; padding: 10px; border: 1px solid #3b4252; } .planet-meta { flex: 1; } - .planet-status-badge { - display: inline-block; - padding: 4px 10px; - border-radius: 20px; - font-size: 11px; - font-weight: bold; - text-transform: uppercase; - margin-bottom: 10px; - } - .planet-description { - font-size: 13px; - color: #94a3b8; - line-height: 1.6; - margin-bottom: 15px; - } + .planet-status-badge { display: inline-block; padding: 4px 12px; border-radius: 20px; font-size: 11px; font-weight: bold; margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.5px; } + + .control-section { margin-bottom: 25px; padding: 15px; background: rgba(0,0,0,0.2); border-radius: 6px; border: 1px solid #2d3545; } + .control-title { font-size: 13px; font-weight: bold; color: #88c0d0; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; text-transform: uppercase; } + .multi-control-bar { height: 12px; background: #2e3440; border-radius: 6px; display: flex; overflow: hidden; margin-bottom: 10px; border: 1px solid #3b4252; } + .control-segment { height: 100%; transition: width 0.3s; } + .control-legend { display: flex; flex-wrap: wrap; gap: 15px; font-size: 11px; } + .legend-tag { display: flex; align-items: center; gap: 5px; color: #d8dee9; } + .legend-tag .color-box { width: 8px; height: 8px; border-radius: 2px; } - .control-section { - margin-bottom: 25px; - padding: 15px; - background: rgba(30, 41, 59, 0.3); - border-radius: 8px; - border: 1px solid rgba(136, 192, 208, 0.1); - } - .control-title { - font-size: 12px; - font-weight: bold; - color: #88c0d0; - text-transform: uppercase; - margin-bottom: 15px; - display: flex; - align-items: center; - gap: 10px; - } - .control-title i { font-size: 14px; } + .city-item { display: flex; justify-content: space-between; align-items: center; padding: 12px; background: #242c3d; border: 1px solid #3b4252; border-radius: 5px; margin-bottom: 10px; } + .city-info { display: flex; flex-direction: column; gap: 4px; } + .city-name { font-weight: bold; color: #eceff4; font-size: 14px; } + .city-type { font-size: 11px; color: #88c0d0; opacity: 0.8; } + + .mod-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; } + .mod-badge { font-size: 9px; padding: 2px 6px; border-radius: 3px; background: rgba(136, 192, 208, 0.1); color: #88c0d0; border: 1px solid rgba(136, 192, 208, 0.3); } - /* Multi-colored Progress Bar */ - .multi-control-bar { - height: 14px; - background: #1e293b; - border-radius: 7px; - overflow: hidden; - display: flex; - margin-bottom: 10px; - box-shadow: inset 0 2px 4px rgba(0,0,0,0.3); - } - .control-segment { - height: 100%; - transition: width 0.3s ease; - position: relative; - } - .control-legend { - display: flex; - flex-wrap: wrap; - gap: 15px; - margin-top: 10px; - } - .legend-tag { - display: flex; - align-items: center; - gap: 6px; - font-size: 11px; - color: #cbd5e1; - } - .legend-color { width: 10px; height: 10px; border-radius: 2px; } - - .settlement-card { - background: rgba(15, 23, 42, 0.6); - border: 1px solid #1e293b; - border-radius: 8px; - padding: 15px; - margin-bottom: 15px; - } - .settlement-header { - display: flex; - justify-content: space-between; - align-items: center; - margin-bottom: 10px; - } - .settlement-name { font-weight: bold; font-size: 14px; color: #fff; } - .settlement-type { font-size: 10px; color: #8c92a3; text-transform: uppercase; } - - .tooltip-box { display: none; position: absolute; top: -10px; left: 105%; width: 240px; background: #1e293b; border: 1px solid #88c0d0; padding: 15px; z-index: 100; pointer-events: none; box-shadow: 10px 10px 20px rgba(0,0,0,0.5); } - .slot:hover .tooltip-box { display: block; } - .tooltip-title { font-size: 14px; color: #88c0d0; font-weight: bold; border-bottom: 1px solid #334155; padding-bottom: 8px; margin-bottom: 8px; } - .tooltip-desc { font-size: 11px; color: #d8dee9; line-height: 1.4; font-style: italic; margin-bottom: 10px; } - .mod-list { display: flex; flex-direction: column; gap: 5px; } - .mod-item { font-size: 10px; padding: 4px 8px; border-radius: 3px; display: flex; align-items: center; gap: 8px; } - .mod-bonus { background: rgba(163, 190, 140, 0.15); color: #a3be8c; border: 1px solid rgba(163, 190, 140, 0.3); } - .mod-malus { background: rgba(191, 97, 106, 0.15); color: #bf616a; border: 1px solid rgba(191, 97, 106, 0.3); } - .mod-item i { font-size: 12px; } - - .settlement-title { font-size: 10px; color: #ebcb8b; font-weight: bold; border-top: 1px solid #334155; margin-top: 8px; padding-top: 5px; margin-bottom: 5px; } - .settlement-item-tool { font-size: 9px; color: #fff; margin-bottom: 10px; background: rgba(0,0,0,0.2); padding: 5px; border-radius: 3px; } - .control-bars-mini { margin-top: 5px; display: flex; flex-direction: column; gap: 3px; } - .control-bar-mini { height: 4px; background: #000; border-radius: 2px; overflow: hidden; display: flex; } - .control-fill { height: 100%; } - .control-label-mini { font-size: 7px; color: #8c92a3; display: flex; justify-content: space-between; margin-bottom: 1px; } - - .legend { margin-top: 20px; background: rgba(10, 15, 30, 0.95); border: 1px solid #2d3545; padding: 10px 20px; display: flex; gap: 15px; font-size: 10px; flex-wrap: wrap; max-width: 1000px; justify-content: center; } - .legend-item { display: flex; align-items: center; gap: 5px; } - .dot { width: 8px; height: 8px; border-radius: 1px; } - .breadcrumb { margin-bottom: 20px; font-size: 14px; color: #88c0d0; } - .breadcrumb a { color: #fff; text-decoration: none; } - .breadcrumb a:hover { text-decoration: underline; } - .admin-footer { position: fixed; bottom: 0; left: 0; width: 100%; background: rgba(0,0,0,0.8); padding: 5px 20px; display: flex; justify-content: flex-end; gap: 15px; border-top: 1px solid #2d3545; } - .admin-footer a { color: #fff; text-decoration: none; font-size: 11px; font-weight: bold; padding: 5px 10px; border-radius: 3px; } - .btn-mj { background: #ebcb8b; color: #000 !important; } - .btn-adm { background: #bf616a; } + .resource-header { background: rgba(10, 15, 30, 0.9); border-bottom: 1px solid #2d3545; padding: 10px 30px; display: flex; justify-content: center; gap: 30px; position: sticky; top: 0; z-index: 100; backdrop-filter: blur(10px); } + .res-item { display: flex; align-items: center; gap: 10px; } + .res-item img { width: 24px; height: 24px; object-fit: contain; } + .res-item i { font-size: 18px; width: 24px; text-align: center; } + .res-val { font-family: 'Courier New', monospace; font-weight: bold; color: #eceff4; font-size: 15px; } + .res-prod { font-size: 10px; color: #a3be8c; }
-
- -
- $res): ?> -
-
- - ?v="> - - "> - -
-
-
-
- - -
+
+ $r): ?> +
+ + <?php echo $name; ?> + + + +
+ +
- -
+
-