1
This commit is contained in:
parent
2c7a64bfea
commit
2d645b19c1
@ -699,6 +699,25 @@ CREATE TABLE `t_battle_settlement_team` (
|
|||||||
) 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_battle_settlement_team`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `t_battle_input`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!40101 SET character_set_client = utf8 */;
|
||||||
|
CREATE TABLE `t_battle_input` (
|
||||||
|
`idx` bigint NOT NULL AUTO_INCREMENT COMMENT '自增id',
|
||||||
|
`battle_uuid` varchar(60) NOT NULL DEFAULT '' COMMENT '战斗记录唯一id',
|
||||||
|
`room_uuid` varchar(60) CHARACTER SET utf8 NOT NULL COMMENT 'room_id',
|
||||||
|
`input` mediumblob COMMENT 'input',
|
||||||
|
`createtime` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
|
||||||
|
`modifytime` int(11) NOT NULL DEFAULT '0' COMMENT '修改时间',
|
||||||
|
PRIMARY KEY (`idx`),
|
||||||
|
UNIQUE KEY `battle_room_uuid` (`battle_uuid`, `room_uuid`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=10000 DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Table structure for table `t_battle_history`
|
-- Table structure for table `t_battle_history`
|
||||||
--
|
--
|
||||||
|
@ -129,6 +129,24 @@ class BattleController extends BaseAuthedController {
|
|||||||
$this->_rspErr(1, 'Repeated request');
|
$this->_rspErr(1, 'Repeated request');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
SqlHelper::upsert
|
||||||
|
(myself()->_getSelfMysql(),
|
||||||
|
't_battle_input',
|
||||||
|
array(
|
||||||
|
'battle_uuid' => $battle_uuid,
|
||||||
|
'room_uuid' => $room_uuid,
|
||||||
|
),
|
||||||
|
array(
|
||||||
|
'input' => json_encode($data)
|
||||||
|
),
|
||||||
|
array(
|
||||||
|
'battle_uuid' => $battle_uuid,
|
||||||
|
'room_uuid' => $room_uuid,
|
||||||
|
'input' => json_encode($data),
|
||||||
|
'createtime' => myself()->_getNowTime(),
|
||||||
|
'modifytime' => myself()->_getNowTime(),
|
||||||
|
)
|
||||||
|
);
|
||||||
$teamList = array();
|
$teamList = array();
|
||||||
if ($data) {
|
if ($data) {
|
||||||
$teamList = $data['team_list'];
|
$teamList = $data['team_list'];
|
||||||
|
@ -130,17 +130,17 @@ class UserController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private function _addFreeItem(){
|
private function _addFreeItem(){
|
||||||
$chipMeta = \mt\Item::getMetaListByType(\mt\Item::CHIP_TYPE);
|
// $chipMeta = \mt\Item::getMetaListByType(\mt\Item::CHIP_TYPE);
|
||||||
foreach ($chipMeta as $row){
|
// foreach ($chipMeta as $row){
|
||||||
Chip::addChip($row);
|
// Chip::addChip($row);
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
foreach (mt\Parameter::getListValue('creator_hero_id') as $heroId) {
|
// foreach (mt\Parameter::getListValue('creator_hero_id') as $heroId) {
|
||||||
$heroMeta = mt\Item::get($heroId);
|
// $heroMeta = mt\Item::get($heroId);
|
||||||
if ($heroMeta) {
|
// if ($heroMeta) {
|
||||||
Hero::addHero($heroMeta);
|
// Hero::addHero($heroMeta);
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
$addItems =array();
|
$addItems =array();
|
||||||
foreach (mt\Parameter::getListValue('creator_present_items') as $itemsStr) {
|
foreach (mt\Parameter::getListValue('creator_present_items') as $itemsStr) {
|
||||||
list($itemId, $itemNum) = explode(':', $itemsStr);
|
list($itemId, $itemNum) = explode(':', $itemsStr);
|
||||||
@ -152,11 +152,11 @@ class UserController extends BaseAuthedController {
|
|||||||
));
|
));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
array_push($addItems,
|
// array_push($addItems,
|
||||||
array(
|
// array(
|
||||||
'item_id' => V_ITEM_GOLD,
|
// 'item_id' => V_ITEM_GOLD,
|
||||||
'item_num' => 50
|
// 'item_num' => 50
|
||||||
));
|
// ));
|
||||||
|
|
||||||
$awardService = new services\AwardService();
|
$awardService = new services\AwardService();
|
||||||
$propertyChgService = new services\PropertyChgService();
|
$propertyChgService = new services\PropertyChgService();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user