1
This commit is contained in:
parent
a678d8047d
commit
28a61308c9
@ -72,16 +72,10 @@ class BattleController extends BaseAuthedController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$data = json_decode(file_get_contents('php://input'), true);
|
$data = json_decode(file_get_contents('php://input'), true);
|
||||||
/*error_log(json_encode(array(
|
|
||||||
'a' => 'battleReport',
|
|
||||||
'post_data' => $data
|
|
||||||
)));*/
|
|
||||||
|
|
||||||
$teamList = array();
|
$teamList = array();
|
||||||
if ($data) {
|
if ($data) {
|
||||||
$teamList = $data['team_list'];
|
$teamList = $data['team_list'];
|
||||||
}
|
}
|
||||||
// error_log(json_encode($teamList));
|
|
||||||
$battleDataService = new services\BattleDataService();
|
$battleDataService = new services\BattleDataService();
|
||||||
$battleDataService->teamList = $teamList;
|
$battleDataService->teamList = $teamList;
|
||||||
$battleDataService->updateBattleData();
|
$battleDataService->updateBattleData();
|
||||||
@ -95,7 +89,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
'modifytime' => $this->_getNowTime(),
|
'modifytime' => $this->_getNowTime(),
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
// error_log(json_encode($battleDataService->getReward()));
|
|
||||||
$data = array(
|
$data = array(
|
||||||
'reward' => $battleDataService->getReward()
|
'reward' => $battleDataService->getReward()
|
||||||
);
|
);
|
||||||
@ -138,7 +131,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$data = json_decode(file_get_contents('php://input'), true);
|
$data = json_decode(file_get_contents('php://input'), true);
|
||||||
error_log(json_encode($data));
|
|
||||||
foreach ($data['team_list'] as $teamData){
|
foreach ($data['team_list'] as $teamData){
|
||||||
$this->_handleTeamReport($teamData);
|
$this->_handleTeamReport($teamData);
|
||||||
}
|
}
|
||||||
@ -214,7 +206,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$data = json_decode(file_get_contents('php://input'), true);
|
$data = json_decode(file_get_contents('php://input'), true);
|
||||||
error_log(json_encode($data));
|
|
||||||
$this->_handleTeamReport($data);
|
$this->_handleTeamReport($data);
|
||||||
// $battle_uuid = getXVal($data,'battle_uuid', 0);
|
// $battle_uuid = getXVal($data,'battle_uuid', 0);
|
||||||
// $room_uuid = getXVal($data,'room_uuid', 0);
|
// $room_uuid = getXVal($data,'room_uuid', 0);
|
||||||
@ -285,9 +276,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$input = json_decode(file_get_contents('php://input'), true);
|
$input = json_decode(file_get_contents('php://input'), true);
|
||||||
if (myself()->_getAccountId() == '6513_2006_U1JcRueKMQxN9BDw8p7pu61gfdzsS7G3') {
|
|
||||||
error_log(json_encode($input));
|
|
||||||
}
|
|
||||||
$roomBattleDataService = new services\RoomBattleDataService();
|
$roomBattleDataService = new services\RoomBattleDataService();
|
||||||
$roomBattleDataService->mapMode = getXVal($input,'map_mode', 0);
|
$roomBattleDataService->mapMode = getXVal($input,'map_mode', 0);
|
||||||
error_log('roomReportMode:'.getXVal($input,'map_mode', 0));
|
error_log('roomReportMode:'.getXVal($input,'map_mode', 0));
|
||||||
@ -361,7 +349,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
error_log(json_encode($realPlayerHash));
|
|
||||||
$accountIdPair = array();
|
$accountIdPair = array();
|
||||||
foreach ($realPlayerHash as $accountId => $val) {
|
foreach ($realPlayerHash as $accountId => $val) {
|
||||||
foreach ($realPlayerHashCopy as $accountIdCopy => $valCopy) {
|
foreach ($realPlayerHashCopy as $accountIdCopy => $valCopy) {
|
||||||
@ -379,7 +366,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
error_log(json_encode($accountIdPair));
|
|
||||||
$nowTime = myself()->_getNowTime();
|
$nowTime = myself()->_getNowTime();
|
||||||
foreach ($accountIdPair as $pair) {
|
foreach ($accountIdPair as $pair) {
|
||||||
$accountId1 = $pair[0];
|
$accountId1 = $pair[0];
|
||||||
@ -422,7 +408,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
|
|
||||||
public function getBattleData()
|
public function getBattleData()
|
||||||
{
|
{
|
||||||
error_log(json_encode($_REQUEST));
|
|
||||||
$data = array(
|
$data = array(
|
||||||
'members' => array()
|
'members' => array()
|
||||||
);
|
);
|
||||||
@ -538,7 +523,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
$customData = array();
|
$customData = array();
|
||||||
{
|
{
|
||||||
$rawData = file_get_contents('php://input');
|
$rawData = file_get_contents('php://input');
|
||||||
error_log($rawData);
|
|
||||||
$sign = strstr($rawData, '|', true);
|
$sign = strstr($rawData, '|', true);
|
||||||
$customData = strstr($rawData, '|');
|
$customData = strstr($rawData, '|');
|
||||||
$customData = substr($customData, 1);
|
$customData = substr($customData, 1);
|
||||||
@ -553,7 +537,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
$customData = json_decode($customData, true);
|
$customData = json_decode($customData, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
error_log(json_encode($customData));
|
|
||||||
$zoneId = $customData['zone_id'];
|
$zoneId = $customData['zone_id'];
|
||||||
$nodeId = $customData['node_id'];
|
$nodeId = $customData['node_id'];
|
||||||
$roomUuid = $customData['room_uuid'];
|
$roomUuid = $customData['room_uuid'];
|
||||||
@ -687,7 +670,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
array_push($data['ob_list'], $info);
|
array_push($data['ob_list'], $info);
|
||||||
}
|
}
|
||||||
error_log(json_encode($data));
|
|
||||||
myself()->_rspData($data);
|
myself()->_rspData($data);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -702,7 +684,7 @@ class BattleController extends BaseAuthedController {
|
|||||||
$customData = array();
|
$customData = array();
|
||||||
{
|
{
|
||||||
$rawData = file_get_contents('php://input');
|
$rawData = file_get_contents('php://input');
|
||||||
error_log($rawData);
|
|
||||||
$headStr = strstr($rawData, '|', true);
|
$headStr = strstr($rawData, '|', true);
|
||||||
$sign = strstr($headStr, ':', true);
|
$sign = strstr($headStr, ':', true);
|
||||||
$customData = strstr($rawData, '|');
|
$customData = strstr($rawData, '|');
|
||||||
@ -719,7 +701,7 @@ class BattleController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$currSeason = mt\RankSeason::getCurrentSeason();
|
$currSeason = mt\RankSeason::getCurrentSeason();
|
||||||
error_log(json_encode($customData));
|
|
||||||
$zoneId = $customData['zone_id'];
|
$zoneId = $customData['zone_id'];
|
||||||
$nodeId = $customData['node_id'];
|
$nodeId = $customData['node_id'];
|
||||||
$modeId = $customData['mode_id'];
|
$modeId = $customData['mode_id'];
|
||||||
@ -833,7 +815,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
array_push($data['team_list'], $teamInfo);
|
array_push($data['team_list'], $teamInfo);
|
||||||
}
|
}
|
||||||
error_log(json_encode($data));
|
|
||||||
$this->decTicket($r, $customData, $mapModeMeta);
|
$this->decTicket($r, $customData, $mapModeMeta);
|
||||||
myself()->_rspData($data);
|
myself()->_rspData($data);
|
||||||
}
|
}
|
||||||
@ -844,7 +825,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
$customData = array();
|
$customData = array();
|
||||||
{
|
{
|
||||||
$rawData = file_get_contents('php://input');
|
$rawData = file_get_contents('php://input');
|
||||||
error_log($rawData);
|
|
||||||
$headStr = strstr($rawData, '|', true);
|
$headStr = strstr($rawData, '|', true);
|
||||||
$sign = strstr($headStr, ':', true);
|
$sign = strstr($headStr, ':', true);
|
||||||
$customData = strstr($rawData, '|');
|
$customData = strstr($rawData, '|');
|
||||||
@ -937,7 +917,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
array_push($data['team_list'], $teamInfo);
|
array_push($data['team_list'], $teamInfo);
|
||||||
}
|
}
|
||||||
error_log(json_encode($data));
|
|
||||||
myself()->_rspData($data);
|
myself()->_rspData($data);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -979,7 +958,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
|
|
||||||
public function getBattleDataNew()
|
public function getBattleDataNew()
|
||||||
{
|
{
|
||||||
error_log(json_encode($_REQUEST));
|
|
||||||
$members = json_decode(getReqVal('members', ''), true);
|
$members = json_decode(getReqVal('members', ''), true);
|
||||||
$data = array(
|
$data = array(
|
||||||
'members' => array()
|
'members' => array()
|
||||||
@ -1197,7 +1175,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
|
|
||||||
public function requestAllocBoxNum()
|
public function requestAllocBoxNum()
|
||||||
{
|
{
|
||||||
error_log(json_encode($_REQUEST));
|
|
||||||
$roomUuid = getReqVal('room_uuid', '');
|
$roomUuid = getReqVal('room_uuid', '');
|
||||||
$row = SqlHelper::ormSelectOne(
|
$row = SqlHelper::ormSelectOne(
|
||||||
$this->_getSelfMysql(),
|
$this->_getSelfMysql(),
|
||||||
@ -1254,7 +1231,6 @@ class BattleController extends BaseAuthedController {
|
|||||||
|
|
||||||
public function requestReturnBoxNum()
|
public function requestReturnBoxNum()
|
||||||
{
|
{
|
||||||
error_log(json_encode($_REQUEST));
|
|
||||||
$roomUuid = getReqVal('room_uuid', '');
|
$roomUuid = getReqVal('room_uuid', '');
|
||||||
$usedNum = getReqVal('used_num', 0);
|
$usedNum = getReqVal('used_num', 0);
|
||||||
$allocBoxNum = getReqVal('alloc_box_num', 0);
|
$allocBoxNum = getReqVal('alloc_box_num', 0);
|
||||||
|
@ -138,7 +138,6 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$data = json_decode(file_get_contents('php://input'), true);
|
$data = json_decode(file_get_contents('php://input'), true);
|
||||||
error_log(json_encode($data));
|
|
||||||
foreach ($data['team_list'] as $teamData){
|
foreach ($data['team_list'] as $teamData){
|
||||||
$this->_handleTeamReport($teamData);
|
$this->_handleTeamReport($teamData);
|
||||||
}
|
}
|
||||||
@ -212,7 +211,6 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$data = json_decode(file_get_contents('php://input'), true);
|
$data = json_decode(file_get_contents('php://input'), true);
|
||||||
error_log(json_encode($data));
|
|
||||||
$this->_handleTeamReport($data);
|
$this->_handleTeamReport($data);
|
||||||
// $battle_uuid = getXVal($data,'battle_uuid', 0);
|
// $battle_uuid = getXVal($data,'battle_uuid', 0);
|
||||||
// $room_uuid = getXVal($data,'room_uuid', 0);
|
// $room_uuid = getXVal($data,'room_uuid', 0);
|
||||||
@ -283,9 +281,6 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$input = json_decode(file_get_contents('php://input'), true);
|
$input = json_decode(file_get_contents('php://input'), true);
|
||||||
if (myself()->_getAccountId() == '6513_2006_U1JcRueKMQxN9BDw8p7pu61gfdzsS7G3') {
|
|
||||||
error_log(json_encode($input));
|
|
||||||
}
|
|
||||||
$roomBattleDataService = new services\RoomBattleDataService();
|
$roomBattleDataService = new services\RoomBattleDataService();
|
||||||
$roomBattleDataService->mapMode = getXVal($input,'map_mode', 0);
|
$roomBattleDataService->mapMode = getXVal($input,'map_mode', 0);
|
||||||
error_log('roomReportMode:'.getXVal($input,'map_mode', 0));
|
error_log('roomReportMode:'.getXVal($input,'map_mode', 0));
|
||||||
@ -359,7 +354,6 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
error_log(json_encode($realPlayerHash));
|
|
||||||
$accountIdPair = array();
|
$accountIdPair = array();
|
||||||
foreach ($realPlayerHash as $accountId => $val) {
|
foreach ($realPlayerHash as $accountId => $val) {
|
||||||
foreach ($realPlayerHashCopy as $accountIdCopy => $valCopy) {
|
foreach ($realPlayerHashCopy as $accountIdCopy => $valCopy) {
|
||||||
@ -377,7 +371,6 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
error_log(json_encode($accountIdPair));
|
|
||||||
$nowTime = myself()->_getNowTime();
|
$nowTime = myself()->_getNowTime();
|
||||||
foreach ($accountIdPair as $pair) {
|
foreach ($accountIdPair as $pair) {
|
||||||
$accountId1 = $pair[0];
|
$accountId1 = $pair[0];
|
||||||
@ -536,7 +529,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
$customData = array();
|
$customData = array();
|
||||||
{
|
{
|
||||||
$rawData = file_get_contents('php://input');
|
$rawData = file_get_contents('php://input');
|
||||||
error_log($rawData);
|
|
||||||
$sign = strstr($rawData, '|', true);
|
$sign = strstr($rawData, '|', true);
|
||||||
$customData = strstr($rawData, '|');
|
$customData = strstr($rawData, '|');
|
||||||
$customData = substr($customData, 1);
|
$customData = substr($customData, 1);
|
||||||
@ -551,7 +544,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
$customData = json_decode($customData, true);
|
$customData = json_decode($customData, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
error_log(json_encode($customData));
|
|
||||||
$zoneId = $customData['zone_id'];
|
$zoneId = $customData['zone_id'];
|
||||||
$nodeId = $customData['node_id'];
|
$nodeId = $customData['node_id'];
|
||||||
$roomUuid = $customData['room_uuid'];
|
$roomUuid = $customData['room_uuid'];
|
||||||
@ -685,7 +678,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
array_push($data['ob_list'], $info);
|
array_push($data['ob_list'], $info);
|
||||||
}
|
}
|
||||||
error_log(json_encode($data));
|
|
||||||
myself()->_rspData($data);
|
myself()->_rspData($data);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -700,7 +693,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
$customData = array();
|
$customData = array();
|
||||||
{
|
{
|
||||||
$rawData = file_get_contents('php://input');
|
$rawData = file_get_contents('php://input');
|
||||||
error_log($rawData);
|
|
||||||
$headStr = strstr($rawData, '|', true);
|
$headStr = strstr($rawData, '|', true);
|
||||||
$sign = strstr($headStr, ':', true);
|
$sign = strstr($headStr, ':', true);
|
||||||
$customData = strstr($rawData, '|');
|
$customData = strstr($rawData, '|');
|
||||||
@ -717,7 +710,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$currSeason = mt\RankSeason::getCurrentSeason();
|
$currSeason = mt\RankSeason::getCurrentSeason();
|
||||||
error_log(json_encode($customData));
|
|
||||||
$zoneId = $customData['zone_id'];
|
$zoneId = $customData['zone_id'];
|
||||||
$nodeId = $customData['node_id'];
|
$nodeId = $customData['node_id'];
|
||||||
$modeId = $customData['mode_id'];
|
$modeId = $customData['mode_id'];
|
||||||
@ -831,7 +824,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
array_push($data['team_list'], $teamInfo);
|
array_push($data['team_list'], $teamInfo);
|
||||||
}
|
}
|
||||||
error_log(json_encode($data));
|
|
||||||
$this->decTicket($r, $customData, $mapModeMeta);
|
$this->decTicket($r, $customData, $mapModeMeta);
|
||||||
myself()->_rspData($data);
|
myself()->_rspData($data);
|
||||||
}
|
}
|
||||||
@ -842,7 +835,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
$customData = array();
|
$customData = array();
|
||||||
{
|
{
|
||||||
$rawData = file_get_contents('php://input');
|
$rawData = file_get_contents('php://input');
|
||||||
error_log($rawData);
|
|
||||||
$headStr = strstr($rawData, '|', true);
|
$headStr = strstr($rawData, '|', true);
|
||||||
$sign = strstr($headStr, ':', true);
|
$sign = strstr($headStr, ':', true);
|
||||||
$customData = strstr($rawData, '|');
|
$customData = strstr($rawData, '|');
|
||||||
@ -935,7 +928,7 @@ class BattleDataController extends BaseAuthedController {
|
|||||||
}
|
}
|
||||||
array_push($data['team_list'], $teamInfo);
|
array_push($data['team_list'], $teamInfo);
|
||||||
}
|
}
|
||||||
error_log(json_encode($data));
|
|
||||||
myself()->_rspData($data);
|
myself()->_rspData($data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user