<?php
require_once __DIR__ . '/config.php';
$db = db();
$sql = "CREATE TABLE IF NOT EXISTS planets (
    id INT AUTO_INCREMENT PRIMARY KEY,
    galaxy_id INT,
    sector_id INT,
    slot INT,
    name VARCHAR(255),
    type VARCHAR(255),
    status VARCHAR(255),
    faction_id INT,
    orbital_control INT,
    terrestrial_control INT
);";
$db->exec($sql);
echo "Table 'planets' checked/created.";