001_UserStore.sql 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. CREATE TABLE UserAgents (
  2. ProfileID VARCHAR(36) NOT NULL,
  3. AgentIP VARCHAR(24) DEFAULT NULL,
  4. AgentPort INT DEFAULT NULL,
  5. AgentOnline BIT DEFAULT NULL,
  6. SessionID VARCHAR(36) DEFAULT NULL,
  7. SecureSessionID VARCHAR(36) DEFAULT NULL,
  8. InitialRegion VARCHAR(255) DEFAULT NULL,
  9. Region VARCHAR(255) DEFAULT NULL,
  10. LoginTime INT DEFAULT NULL,
  11. LogoutTime INT DEFAULT NULL,
  12. Handle BIGINT DEFAULT NULL,
  13. PositionX DOUBLE DEFAULT NULL,
  14. PositionY DOUBLE DEFAULT NULL,
  15. PositionZ DOUBLE DEFAULT NULL,
  16. LookAtX DOUBLE DEFAULT NULL,
  17. LookAtY DOUBLE DEFAULT NULL,
  18. LookAtZ DOUBLE DEFAULT NULL,
  19. PRIMARY KEY (ProfileID)
  20. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1';
  21. CREATE TABLE UserProfiles (
  22. ID VARCHAR(36) NOT NULL,
  23. WebLoginKey VARCHAR(36) DEFAULT NULL,
  24. FirstName VARCHAR(32) DEFAULT NULL,
  25. SurName VARCHAR(32) DEFAULT NULL,
  26. Email VARCHAR(250) DEFAULT NULL,
  27. PasswordHash VARCHAR(32) DEFAULT NULL,
  28. PasswordSalt VARCHAR(32) DEFAULT NULL,
  29. HomeRegionID VARCHAR(36) DEFAULT NULL,
  30. HomeRegionX INT DEFAULT NULL,
  31. HomeRegionY INT DEFAULT NULL,
  32. HomeLocationX DOUBLE DEFAULT NULL,
  33. HomeLocationY DOUBLE DEFAULT NULL,
  34. HomeLocationZ DOUBLE DEFAULT NULL,
  35. HomeLookAtX DOUBLE DEFAULT NULL,
  36. HomeLookAtY DOUBLE DEFAULT NULL,
  37. HomeLookAtZ DOUBLE DEFAULT NULL,
  38. Created INT DEFAULT NULL,
  39. LastLogin INT DEFAULT NULL,
  40. UserInventoryURI VARCHAR(255) DEFAULT NULL,
  41. UserAssetURI VARCHAR(255) DEFAULT NULL,
  42. Image VARCHAR(36) DEFAULT NULL,
  43. FirstLifeImage VARCHAR(36) DEFAULT NULL,
  44. AboutText TEXT DEFAULT NULL,
  45. FirstLifeAboutText TEXT DEFAULT NULL,
  46. CanDoMask INT DEFAULT NULL,
  47. WantDoMask INT DEFAULT NULL,
  48. UserFlags INT DEFAULT NULL,
  49. GodLevel INT DEFAULT NULL,
  50. CustomType VARCHAR(32) DEFAULT NULL,
  51. Partner VARCHAR(36) DEFAULT NULL,
  52. RootInventoryFolderID VARCHAR(36) DEFAULT NULL,
  53. PRIMARY KEY (ID)
  54. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1';
  55. CREATE INDEX UserSurnameIndex ON UserProfiles (SurName);
  56. CREATE INDEX UserFirstNameIndex ON UserProfiles (FirstName);
  57. CREATE UNIQUE INDEX UserFullNameIndex ON UserProfiles (SurName,FirstName);
  58. CREATE TABLE UserAppearances (
  59. Owner VARCHAR(36) NOT NULL,
  60. BodyItem VARCHAR(36) DEFAULT NULL,
  61. BodyAsset VARCHAR(36) DEFAULT NULL,
  62. SkinItem VARCHAR(36) DEFAULT NULL,
  63. SkinAsset VARCHAR(36) DEFAULT NULL,
  64. HairItem VARCHAR(36) DEFAULT NULL,
  65. HairAsset VARCHAR(36) DEFAULT NULL,
  66. EyesItem VARCHAR(36) DEFAULT NULL,
  67. EyesAsset VARCHAR(36) DEFAULT NULL,
  68. ShirtItem VARCHAR(36) DEFAULT NULL,
  69. ShirtAsset VARCHAR(36) DEFAULT NULL,
  70. PantsItem VARCHAR(36) DEFAULT NULL,
  71. PantsAsset VARCHAR(36) DEFAULT NULL,
  72. ShoesItem VARCHAR(36) DEFAULT NULL,
  73. ShoesAsset VARCHAR(36) DEFAULT NULL,
  74. SocksItem VARCHAR(36) DEFAULT NULL,
  75. SocksAsset VARCHAR(36) DEFAULT NULL,
  76. JacketItem VARCHAR(36) DEFAULT NULL,
  77. JacketAsset VARCHAR(36) DEFAULT NULL,
  78. GlovesItem VARCHAR(36) DEFAULT NULL,
  79. GlovesAsset VARCHAR(36) DEFAULT NULL,
  80. UnderShirtItem VARCHAR(36) DEFAULT NULL,
  81. UnderShirtAsset VARCHAR(36) DEFAULT NULL,
  82. UnderPantsItem VARCHAR(36) DEFAULT NULL,
  83. UnderPantsAsset VARCHAR(36) DEFAULT NULL,
  84. SkirtItem VARCHAR(36) DEFAULT NULL,
  85. SkirtAsset VARCHAR(36) DEFAULT NULL,
  86. Texture LONGBLOB,
  87. VisualParams LONGBLOB,
  88. Serial INT DEFAULT NULL,
  89. AvatarHeight FLOAT DEFAULT NULL,
  90. PRIMARY KEY (Owner)
  91. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1';
  92. CREATE TABLE UserFriends (
  93. UserFriendID VARCHAR(36) NOT NULL,
  94. OwnerID VARCHAR(36) DEFAULT NULL,
  95. FriendID VARCHAR(36) DEFAULT NULL,
  96. FriendPermissions INT DEFAULT NULL,
  97. PRIMARY KEY (UserFriendID)
  98. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Rev. 1';
  99. CREATE UNIQUE INDEX UserFriendsOwnerIdFriendIdIndex ON UserFriends (OwnerID,FriendID);