From The Mana World
 
m
Line 6: Line 6:
     -- Username
     -- Username
     user varchar(32) unique primary key not null,
     user varchar(32) unique primary key not null,
     -- Password hash
     -- Password hash
     password varchar(32) not null,
     password varchar(32) not null,
     -- Email address
     -- Email address
     email varchar(128) not null
     email varchar(128) not null
Line 25: Line 23:
     level int not null,
     level int not null,
     money int not null,
     money int not null,
     -- Coordinates & map
     -- Coordinates & map
     x int not null,
     x int not null,
     y int not null,
     y int not null,
     map text not null,
     map text not null,
     -- Statistics
     -- Statistics
     strength int not null,
     strength int not null,
Line 38: Line 34:
     dexterity int not null,
     dexterity int not null,
     luck int not null,
     luck int not null,
     -- Player equipment
     -- Player equipment
     inventory blob not null,
     inventory blob not null,
     equipment blob not null,
     equipment blob not null,
     -- Table relationship
     -- Table relationship
     foreign key(user) references tmw_accounts(user)
     foreign key(user) references tmw_accounts(user)
)
)

Revision as of 08:24, 23 May 2005

Server Database Specification:

SQL[ite] Table Specifications:

  • Account Information Table

create table tmw_accounts (

   -- Username
   user varchar(32) unique primary key not null,
   -- Password hash
   password varchar(32) not null,
   -- Email address
   email varchar(128) not null

)

  • Character/Player Information Table

create table tmw_characters (

   -- Character name
   name varchar(32) unique primary key not null,
   -- Username
   user varchar(32) not null,
   -- Player information
   gender int not null,
   level int not null,
   money int not null,
   -- Coordinates & map
   x int not null,
   y int not null,
   map text not null,
   -- Statistics
   strength int not null,
   agility int not null,
   vitality int not null,
   intelligence int not null,
   dexterity int not null,
   luck int not null,
   -- Player equipment
   inventory blob not null,
   equipment blob not null,
   -- Table relationship
   foreign key(user) references tmw_accounts(user)

)