001_UserStore.sql 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. BEGIN;
  2. SET FOREIGN_KEY_CHECKS=0;
  3. -- ----------------------------
  4. -- Table structure for agents
  5. -- ----------------------------
  6. CREATE TABLE `agents` (
  7. `UUID` varchar(36) NOT NULL,
  8. `sessionID` varchar(36) NOT NULL,
  9. `secureSessionID` varchar(36) NOT NULL,
  10. `agentIP` varchar(16) NOT NULL,
  11. `agentPort` int(11) NOT NULL,
  12. `agentOnline` tinyint(4) NOT NULL,
  13. `loginTime` int(11) NOT NULL,
  14. `logoutTime` int(11) NOT NULL,
  15. `currentRegion` varchar(36) NOT NULL,
  16. `currentHandle` bigint(20) unsigned NOT NULL,
  17. `currentPos` varchar(64) NOT NULL,
  18. PRIMARY KEY (`UUID`),
  19. UNIQUE KEY `session` (`sessionID`),
  20. UNIQUE KEY `ssession` (`secureSessionID`)
  21. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  22. -- Create schema avatar_appearance
  23. --
  24. CREATE TABLE `avatarappearance` (
  25. Owner char(36) NOT NULL,
  26. Serial int(10) unsigned NOT NULL,
  27. Visual_Params blob NOT NULL,
  28. Texture blob NOT NULL,
  29. Avatar_Height float NOT NULL,
  30. Body_Item char(36) NOT NULL,
  31. Body_Asset char(36) NOT NULL,
  32. Skin_Item char(36) NOT NULL,
  33. Skin_Asset char(36) NOT NULL,
  34. Hair_Item char(36) NOT NULL,
  35. Hair_Asset char(36) NOT NULL,
  36. Eyes_Item char(36) NOT NULL,
  37. Eyes_Asset char(36) NOT NULL,
  38. Shirt_Item char(36) NOT NULL,
  39. Shirt_Asset char(36) NOT NULL,
  40. Pants_Item char(36) NOT NULL,
  41. Pants_Asset char(36) NOT NULL,
  42. Shoes_Item char(36) NOT NULL,
  43. Shoes_Asset char(36) NOT NULL,
  44. Socks_Item char(36) NOT NULL,
  45. Socks_Asset char(36) NOT NULL,
  46. Jacket_Item char(36) NOT NULL,
  47. Jacket_Asset char(36) NOT NULL,
  48. Gloves_Item char(36) NOT NULL,
  49. Gloves_Asset char(36) NOT NULL,
  50. Undershirt_Item char(36) NOT NULL,
  51. Undershirt_Asset char(36) NOT NULL,
  52. Underpants_Item char(36) NOT NULL,
  53. Underpants_Asset char(36) NOT NULL,
  54. Skirt_Item char(36) NOT NULL,
  55. Skirt_Asset char(36) NOT NULL,
  56. PRIMARY KEY (`Owner`)
  57. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  58. SET FOREIGN_KEY_CHECKS=0;
  59. -- ----------------------------
  60. -- Table structure for users
  61. -- ----------------------------
  62. CREATE TABLE `userfriends` (
  63. `ownerID` VARCHAR(37) NOT NULL,
  64. `friendID` VARCHAR(37) NOT NULL,
  65. `friendPerms` INT NOT NULL,
  66. `datetimestamp` INT NOT NULL,
  67. UNIQUE KEY (`ownerID`, `friendID`)
  68. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  69. -- ----------------------------
  70. -- Table structure for users
  71. -- ----------------------------
  72. CREATE TABLE `users` (
  73. `UUID` varchar(36) NOT NULL default '',
  74. `username` varchar(32) NOT NULL,
  75. `lastname` varchar(32) NOT NULL,
  76. `passwordHash` varchar(32) NOT NULL,
  77. `passwordSalt` varchar(32) NOT NULL,
  78. `homeRegion` bigint(20) unsigned default NULL,
  79. `homeLocationX` float default NULL,
  80. `homeLocationY` float default NULL,
  81. `homeLocationZ` float default NULL,
  82. `homeLookAtX` float default NULL,
  83. `homeLookAtY` float default NULL,
  84. `homeLookAtZ` float default NULL,
  85. `created` int(11) NOT NULL,
  86. `lastLogin` int(11) NOT NULL,
  87. `userInventoryURI` varchar(255) default NULL,
  88. `userAssetURI` varchar(255) default NULL,
  89. `profileCanDoMask` int(10) unsigned default NULL,
  90. `profileWantDoMask` int(10) unsigned default NULL,
  91. `profileAboutText` text,
  92. `profileFirstText` text,
  93. `profileImage` varchar(36) default NULL,
  94. `profileFirstImage` varchar(36) default NULL,
  95. `webLoginKey` varchar(36) default NULL,
  96. PRIMARY KEY (`UUID`),
  97. UNIQUE KEY `usernames` (`username`,`lastname`)
  98. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  99. -- ----------------------------
  100. -- Records
  101. -- ----------------------------
  102. COMMIT;