1
This commit is contained in:
parent
5af3a9ab3f
commit
d88a85b184
@ -579,6 +579,9 @@ CREATE TABLE `t_game_log` (
|
|||||||
|
|
||||||
-- Dump completed on 2015-08-19 18:51:22
|
-- Dump completed on 2015-08-19 18:51:22
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `t_nft_active`
|
||||||
|
--
|
||||||
|
|
||||||
DROP TABLE IF EXISTS `t_nft_active`;
|
DROP TABLE IF EXISTS `t_nft_active`;
|
||||||
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
@ -596,4 +599,42 @@ CREATE TABLE `t_nft_active` (
|
|||||||
) ENGINE=InnoDB AUTO_INCREMENT=10000 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
|
) ENGINE=InnoDB AUTO_INCREMENT=10000 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
|
||||||
/*!40101 SET character_set_client = @saved_cs_client */;
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `t_fragment_pool`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `t_fragment_pool`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!40101 SET character_set_client = utf8 */;
|
||||||
|
CREATE TABLE `t_fragment_pool` (
|
||||||
|
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
|
||||||
|
`fragment_id` int(11) NOT NULL DEFAULT '0' COMMENT '碎片id',
|
||||||
|
`fragment_type` int(11) NOT NULL DEFAULT '0' COMMENT '碎片类型 0:英雄 1:武器',
|
||||||
|
`fragment_num` int(11) NOT NULL DEFAULT '0' COMMENT '碎片数量',
|
||||||
|
`alloc_time` int(11) NOT NULL DEFAULT '0' COMMENT '分配时间',
|
||||||
|
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
|
||||||
|
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
|
||||||
|
PRIMARY KEY (`idx`),
|
||||||
|
KEY `alloc_time_fragment_type` (`alloc_time`, `fragment_type`),
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=10000 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `t_realtime_data`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `t_realtime_data`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!40101 SET character_set_client = utf8 */;
|
||||||
|
CREATE TABLE `t_fragment_data` (
|
||||||
|
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
|
||||||
|
`name` varchar(60) NOT NULL DEFAULT '' COMMENT '参数名',
|
||||||
|
`value1` varchar(60) NOT NULL DEFAULT '' COMMENT '值1',
|
||||||
|
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
|
||||||
|
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
|
||||||
|
PRIMARY KEY (`idx`),
|
||||||
|
UNIQUE KEY `name` (`name`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=10000 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
-- Dump completed on 2015-08-19 18:51:22
|
-- Dump completed on 2015-08-19 18:51:22
|
||||||
|
@ -7,4 +7,14 @@ use phpcommon\SqlHelper;
|
|||||||
|
|
||||||
class FragmentPool extends BaseModel {
|
class FragmentPool extends BaseModel {
|
||||||
|
|
||||||
|
public static function dropHero()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public static function dropGun()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
28
webapp/models/RealtimeData.php
Normal file
28
webapp/models/RealtimeData.php
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace models;
|
||||||
|
|
||||||
|
use mt;
|
||||||
|
use phpcommon\SqlHelper;
|
||||||
|
|
||||||
|
class RealtimeData extends BaseModel {
|
||||||
|
|
||||||
|
//获取在线人数
|
||||||
|
public static function getOnline()
|
||||||
|
{
|
||||||
|
return self::internalGet('online_num');
|
||||||
|
}
|
||||||
|
|
||||||
|
private static function internalGet($name)
|
||||||
|
{
|
||||||
|
$row = SqlHelper::ormSelectOne
|
||||||
|
(myself()->_getMysql($targetId),
|
||||||
|
't_realtime_data',
|
||||||
|
array(
|
||||||
|
'name' => $name
|
||||||
|
)
|
||||||
|
);
|
||||||
|
return $row ? $row : '';
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -528,6 +528,7 @@ class BattleDataService extends BaseService {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private function rewardFragmentPve()
|
private function rewardFragmentPve()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user