CREATE TABLE `nethook_userinfo` (
  `AutoID` int(11) NOT NULL AUTO_INCREMENT,
  `UserID` int(11) NOT NULL,
  `UserName` varchar(32) NOT NULL,
  `UserPass` varchar(32) NOT NULL,
  `UserLevel` int(11) NOT NULL,
  `IconID` int(11) NOT NULL,
  `OnlineTime` int(11) DEFAULT '0',
  `VipLevel` int(11) DEFAULT '0',
  `Gold` int(11) DEFAULT '0',
  `Bean` int(11) DEFAULT '0',
  `AdminRight` int(11) DEFAULT '0',
  PRIMARY KEY (`AutoID`),
  UNIQUE KEY `UserName` (`UserName`),
  UNIQUE KEY `UserID` (`UserID`)
);

CREATE TABLE `nethook_userfriend` (
  `AutoID` int(11) NOT NULL AUTO_INCREMENT,
  `UserID` int(11) NOT NULL,
  `FriendID` int(11) NOT NULL,
  `GroupID` int(11) NOT NULL,
  `IsAuth` int(11) DEFAULT '0',
  `AddTime` int(11) DEFAULT '0',
  PRIMARY KEY (`AutoID`),
  KEY `UserID` (`UserID`)
);

CREATE TABLE `nethook_userfriendgroup` (
  `AutoID` int(11) NOT NULL AUTO_INCREMENT,
  `UserID` int(11) NOT NULL,
  `GroupID` int(11) NOT NULL,
  `GroupName` varchar(32) NOT NULL,
  `AddTime` int(11) DEFAULT '0',
  PRIMARY KEY (`AutoID`),
  KEY `UserID` (`UserID`)
);

CREATE TABLE `nethook_useractiveinfo` (
  `UserID` int(11) NOT NULL,
  `RegTime` int(11) DEFAULT '0',
  `RegIP` varchar(20) NOT NULL DEFAULT '',
  `LastLoginTime` int(11) DEFAULT '0',
  `LastLoginIP` varchar(20) NOT NULL DEFAULT '',
  `LoginTimes` int(11) DEFAULT '0',  
  PRIMARY KEY (`UserID`)
);