1
This commit is contained in:
parent
1520ae6710
commit
7e1619290b
@ -347,7 +347,7 @@ class QuestController{
|
|||||||
'item_num' => $item_num,
|
'item_num' => $item_num,
|
||||||
));
|
));
|
||||||
if ($item_id == 10001) {
|
if ($item_id == 10001) {
|
||||||
$row = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
$row1 = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id
|
':accountid' => $account_id
|
||||||
));
|
));
|
||||||
@ -355,7 +355,7 @@ class QuestController{
|
|||||||
' WHERE accountid=:accountid;',
|
' WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id,
|
':accountid' => $account_id,
|
||||||
':coin_num' => $item_num + $row['coin_num']
|
':coin_num' => $item_num + $row1['coin_num']
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -365,7 +365,7 @@ class QuestController{
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
$reward = $q['gold'];
|
$reward = $q['gold'];
|
||||||
$row = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
$row1 = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id
|
':accountid' => $account_id
|
||||||
));
|
));
|
||||||
@ -373,7 +373,7 @@ class QuestController{
|
|||||||
' WHERE accountid=:accountid;',
|
' WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id,
|
':accountid' => $account_id,
|
||||||
':coin_num' => $reward + $row['coin_num']
|
':coin_num' => $reward + $row1['coin_num']
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
if ($row['quest_type'] == 1) {
|
if ($row['quest_type'] == 1) {
|
||||||
|
@ -54,19 +54,6 @@ class SignController{
|
|||||||
die();
|
die();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
echo json_encode(array(
|
|
||||||
'errcode' => 0,
|
|
||||||
'errmsg' => '',
|
|
||||||
'game_times' => 0,
|
|
||||||
'win_times' => 0,
|
|
||||||
'high_kill' => 0,
|
|
||||||
'kills' => 0,
|
|
||||||
'high_harm' => 0,
|
|
||||||
'harm' => 0,
|
|
||||||
'add_HP' => 0,
|
|
||||||
'alive_time' => 0,
|
|
||||||
'coin_num' => 100000,
|
|
||||||
));
|
|
||||||
}
|
}
|
||||||
$row = $conn->execQueryOne('SELECT * FROM sign WHERE accountid=:accountid;',
|
$row = $conn->execQueryOne('SELECT * FROM sign WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
@ -91,11 +78,15 @@ class SignController{
|
|||||||
$s = $this->getSign($sign_days + 90000);
|
$s = $this->getSign($sign_days + 90000);
|
||||||
$item_id = $s['item_id'];
|
$item_id = $s['item_id'];
|
||||||
$num = $s['num'];
|
$num = $s['num'];
|
||||||
|
$row2 = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
||||||
|
array(
|
||||||
|
':accountid' => $account_id
|
||||||
|
));
|
||||||
$ret = $conn->execScript('UPDATE user SET coin_num=:coin_num ' .
|
$ret = $conn->execScript('UPDATE user SET coin_num=:coin_num ' .
|
||||||
' WHERE accountid=:accountid;',
|
' WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id,
|
':accountid' => $account_id,
|
||||||
':coin_num' => $num
|
':coin_num' => $num + $row2['coin_num']
|
||||||
));
|
));
|
||||||
$quest = new classes\Quest();
|
$quest = new classes\Quest();
|
||||||
$quest->triggerQuest(QUEST_DAY_LOGIN, 1, 1, $account_id);
|
$quest->triggerQuest(QUEST_DAY_LOGIN, 1, 1, $account_id);
|
||||||
@ -120,7 +111,7 @@ class SignController{
|
|||||||
$s = $this->getSign($sign_days % 7 + 90000);
|
$s = $this->getSign($sign_days % 7 + 90000);
|
||||||
$item_id = $s['item_id'];
|
$item_id = $s['item_id'];
|
||||||
$num = $s['num'];
|
$num = $s['num'];
|
||||||
$row = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
$row2 = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id
|
':accountid' => $account_id
|
||||||
));
|
));
|
||||||
@ -128,7 +119,7 @@ class SignController{
|
|||||||
' WHERE accountid=:accountid;',
|
' WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id,
|
':accountid' => $account_id,
|
||||||
':coin_num' => $num + $row['coin_num']
|
':coin_num' => $num + $row2['coin_num']
|
||||||
));
|
));
|
||||||
|
|
||||||
//刷新每日任务
|
//刷新每日任务
|
||||||
|
@ -201,7 +201,7 @@ class SupplyBoxController{
|
|||||||
'item_num' => $item_num,
|
'item_num' => $item_num,
|
||||||
));
|
));
|
||||||
if ($item_id == 10001) {
|
if ($item_id == 10001) {
|
||||||
$row = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
$row1 = $conn->execQueryOne('SELECT * FROM user WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id
|
':accountid' => $account_id
|
||||||
));
|
));
|
||||||
@ -209,7 +209,7 @@ class SupplyBoxController{
|
|||||||
' WHERE accountid=:accountid;',
|
' WHERE accountid=:accountid;',
|
||||||
array(
|
array(
|
||||||
':accountid' => $account_id,
|
':accountid' => $account_id,
|
||||||
':coin_num' => $item_num + $row['coin_num']
|
':coin_num' => $item_num + $row1['coin_num']
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
$quest = new classes\Quest();
|
$quest = new classes\Quest();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user