DROP TABLE IF EXISTS character_macros;
CREATE TABLE character_macros (
	id           INTEGER PRIMARY KEY,
	char_id      INTEGER NOT NULL DEFAULT 0,
	macro_number INTEGER NOT NULL DEFAULT 0,
	macro_icon   INTEGER NOT NULL DEFAULT 0,
	macro_name   TEXT,
	macro_text   TEXT,
	FOREIGN KEY (char_id) REFERENCES characters(id) ON DELETE CASCADE ON UPDATE CASCADE
);
CREATE INDEX idx_character_macros_char_id ON character_macros(char_id);
