forked from Jonathan/Peradventure
35 lines
731 B
Bash
Executable File
35 lines
731 B
Bash
Executable File
#!/bin/bash
|
|
|
|
sqlite3 database.sqlite3 "
|
|
CREATE TABLE IF NOT EXISTS map (
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
x TEXT,
|
|
y TEXT,
|
|
occupied_by_type TEXT,
|
|
occupied_by_id INTEGER,
|
|
game_ref INTEGER
|
|
);
|
|
CREATE TABLE IF NOT EXISTS entity_ref (
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
entity_id INTEGER,
|
|
type TEXT,
|
|
hp INTEGER,
|
|
inventory_ref INTEGER,
|
|
game_ref INTEGER
|
|
);
|
|
CREATE TABLE IF NOT EXISTS player_inventory (
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
type TEXT,
|
|
quantity INTEGER,
|
|
game_ref INTEGER
|
|
);
|
|
CREATE TABLE IF NOT EXISTS games (
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
player_id TEXT
|
|
);
|
|
CREATE TABLE IF NOT EXISTS players (
|
|
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
|
player_name TEXT
|
|
)
|
|
"
|