|
|
@ -11,6 +11,7 @@ include_once(ROOT_PATH.'/include/clan.inc.php');
|
|
|
|
include_once(ROOT_PATH.'/include/fehlerausgabe.inc.php');
|
|
|
|
include_once(ROOT_PATH.'/include/fehlerausgabe.inc.php');
|
|
|
|
include_once(ROOT_PATH.'/include/parse.inc.php');
|
|
|
|
include_once(ROOT_PATH.'/include/parse.inc.php');
|
|
|
|
include_once(ROOT_PATH.'/include/char.inc.php');
|
|
|
|
include_once(ROOT_PATH.'/include/char.inc.php');
|
|
|
|
|
|
|
|
include_once(ROOT_PATH.'/include/user.inc.php');
|
|
|
|
|
|
|
|
|
|
|
|
defineIfNotDefined('DENY_CHALLENGE', 1);
|
|
|
|
defineIfNotDefined('DENY_CHALLENGE', 1);
|
|
|
|
defineIfNotDefined('WITHDRAW_CHALLENGE', 2);
|
|
|
|
defineIfNotDefined('WITHDRAW_CHALLENGE', 2);
|
|
|
@ -25,6 +26,7 @@ $challangedclan_id = validateUnsignedInteger($_GET['challangedclan_id'], null);
|
|
|
|
$inquirychallenge_clanid = validateUnsignedInteger($_GET['clanid'], null);
|
|
|
|
$inquirychallenge_clanid = validateUnsignedInteger($_GET['clanid'], null);
|
|
|
|
$clan_challange_id = validateUnsignedInteger($_GET['challenge'], null);
|
|
|
|
$clan_challange_id = validateUnsignedInteger($_GET['challenge'], null);
|
|
|
|
$char_id = validateUnsignedInteger($_GET['char'], null);
|
|
|
|
$char_id = validateUnsignedInteger($_GET['char'], null);
|
|
|
|
|
|
|
|
$type = validateUnsignedInteger($_GET['type'], null);
|
|
|
|
|
|
|
|
|
|
|
|
//unkritisch
|
|
|
|
//unkritisch
|
|
|
|
if($action == null) {
|
|
|
|
if($action == null) {
|
|
|
@ -84,13 +86,28 @@ function displayDenyChallenge($clan_id, $type) {
|
|
|
|
<?php }?>
|
|
|
|
<?php }?>
|
|
|
|
</tr>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<tr>
|
|
|
|
<td align="center"><?php echo '<a href="index.php?as=clan/kampf_info&action=denychallenge&clanid='.$clan_id.'">ja</a>';?>
|
|
|
|
<td align="center"><?php echo '<a href="index.php?as=clan/kampf_info&action=denychallenge&clanid='.$clan_id.'&type='.$type.'">ja</a>';?>
|
|
|
|
</td>
|
|
|
|
</td>
|
|
|
|
<td align="center"><?php echo '<a href="index.php?as=clan/kampf_info">nein</a>';?>
|
|
|
|
<td align="center"><?php echo '<a href="index.php?as=clan/kampf_info">nein</a>';?>
|
|
|
|
</td>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tr>
|
|
|
|
</table>
|
|
|
|
</table>
|
|
|
|
<?php
|
|
|
|
<?php
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function denyChallenge($type, $clan_id, $user) {
|
|
|
|
|
|
|
|
if($type == DENY_CHALLENGE) {
|
|
|
|
|
|
|
|
$success = denyChallengeRequest($clan_id, $user);
|
|
|
|
|
|
|
|
} elseif($type == WITHDRAW_CHALLENGE) {
|
|
|
|
|
|
|
|
$success = cancelChallengeRequest($clan_id, $user);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($success == null) {
|
|
|
|
|
|
|
|
displayClanFightMenu($user_ida);
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
displayErrorMessage(NULL, $success, displayHistoryBackLink());
|
|
|
|
|
|
|
|
exit;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function displayShowChallenge($clan_challenge_id, $user) {
|
|
|
|
function displayShowChallenge($clan_challenge_id, $user) {
|
|
|
@ -117,7 +134,6 @@ function displayShowChallenge($clan_challenge_id, $user) {
|
|
|
|
$slots = array();
|
|
|
|
$slots = array();
|
|
|
|
|
|
|
|
|
|
|
|
?>
|
|
|
|
?>
|
|
|
|
|
|
|
|
|
|
|
|
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="POST">
|
|
|
|
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="POST">
|
|
|
|
<input type="hidden" name="as" value=clan/kampf_info> <input
|
|
|
|
<input type="hidden" name="as" value=clan/kampf_info> <input
|
|
|
|
type="hidden" name="action" value="joinchallenge"> <input
|
|
|
|
type="hidden" name="action" value="joinchallenge"> <input
|
|
|
@ -148,7 +164,9 @@ function displayShowChallenge($clan_challenge_id, $user) {
|
|
|
|
echo '<td><b>Slot '.$i.'</b></td>';
|
|
|
|
echo '<td><b>Slot '.$i.'</b></td>';
|
|
|
|
if($user_clan_chars[$i] != null) {
|
|
|
|
if($user_clan_chars[$i] != null) {
|
|
|
|
$char = getChar($user_clan_chars[$i]);
|
|
|
|
$char = getChar($user_clan_chars[$i]);
|
|
|
|
echo '<td align="center">'.$char['name'].'</td>';
|
|
|
|
$char_owner = getOwnerOfChar($char['id']);
|
|
|
|
|
|
|
|
echo '<td align="center"><a href="index.php?as=info&charm=1&char_id='.$char['id'].'">'.$char['name'].'</a> ';
|
|
|
|
|
|
|
|
echo '(<a href="index.php?as=info&user_id='.$char_owner['id'].'">'.$char_owner['nickname'].'</a></td>)';
|
|
|
|
if(isUserOwnerOf($user['id'], $char['id'])) {
|
|
|
|
if(isUserOwnerOf($user['id'], $char['id'])) {
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=leavechallenge&challenge='.$clan_challenge_id.'&char='.$char['id'].'">abmelden</a></td>';
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=leavechallenge&challenge='.$clan_challenge_id.'&char='.$char['id'].'">abmelden</a></td>';
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -270,7 +288,7 @@ function displayJoinChallenge($user, $clan_challenge_id, $char_id, $slot) {
|
|
|
|
exit;
|
|
|
|
exit;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
echo 'Der Charakter wurde erfoglreich angemeldet.<br><br>';
|
|
|
|
echo 'Der Charakter wurde erfoglreich angemeldet.<br><br>';
|
|
|
|
echo '<a href="index.php?as=clan/kampf_info">weiter</a>';
|
|
|
|
echo '<a href="index.php?as=clan/kampf_info&action=showchallenge&challenge='.$clan_challenge_id.'">weiter</a>';
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -289,7 +307,43 @@ function displayLeaveChallenge($user, $clan_challenge_id, $char_id) {
|
|
|
|
exit;
|
|
|
|
exit;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
echo 'Der Charakter wurde erfoglreich abgemeldet.<br><br>';
|
|
|
|
echo 'Der Charakter wurde erfoglreich abgemeldet.<br><br>';
|
|
|
|
echo '<a href="index.php?as=clan/kampf_info">weiter</a>';
|
|
|
|
echo '<a href="index.php?as=clan/kampf_info&action=showchallenge&challenge='.$clan_challenge_id.'">weiter</a>';
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function displayCancelChallenge($user, $clan_challange_id) {
|
|
|
|
|
|
|
|
if(!is_numeric($clan_challange_id)) {
|
|
|
|
|
|
|
|
displayErrorMessage(NULL, 'Wollte da jemand schummeln? ;)', displayHistoryBackLink());
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
<table>
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<th colspan="2">Clankampf wirklich abbrechen?</th>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<td align="center"><?php echo '<a href="index.php?as=clan/kampf_info&action=cancelchallenge&challenge='.$clan_challange_id.'">ja</a>';?>
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td align="center"><?php echo '<a href="index.php?as=clan/kampf_info">nein</a>';?>
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function cancelThisChallenge($user, $clan_challange_id) {
|
|
|
|
|
|
|
|
if(!is_numeric($clan_challange_id)) {
|
|
|
|
|
|
|
|
displayErrorMessage(NULL, 'Wollte da jemand schummeln? ;)', displayHistoryBackLink());
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$success = cancelChallenge($clan_challange_id, $user);
|
|
|
|
|
|
|
|
if($success != null) {
|
|
|
|
|
|
|
|
displayErrorMessage(NULL, $success, displayHistoryBackLink());
|
|
|
|
|
|
|
|
exit;
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
displayClanFightMenu($user);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -312,14 +366,16 @@ function displayClanFightMenu($user) {
|
|
|
|
$clans[] = getClan($clan_tmp_id);
|
|
|
|
$clans[] = getClan($clan_tmp_id);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
$active_clan_challange_ids = getActiveChallengeIDs($user_clan['id']);
|
|
|
|
$open_challenge_requests = getOpenChallengeRequests($user_clan['id']);
|
|
|
|
$open_challenge_requests = getOpenChallengeRequests($user_clan['id']);
|
|
|
|
$open_challenge_ids = getOpenChallengeIDs($user_clan['id']);
|
|
|
|
$open_challenge_ids = getOpenChallengeIDs($user_clan['id']);
|
|
|
|
$old_challenge_ids = getHistoricalChallengeIDs($user_clan['id']);
|
|
|
|
$old_challenge_ids = getHistoricalChallengeIDs($user_clan['id']);
|
|
|
|
|
|
|
|
|
|
|
|
?>
|
|
|
|
?>
|
|
|
|
<div align="center">
|
|
|
|
<div align="center">
|
|
|
|
<table width="100%" border="1">
|
|
|
|
<table width="100%" border="1">
|
|
|
|
<tr>
|
|
|
|
<tr>
|
|
|
|
<th height="30" colspan="2" align="center">Herausforderungen</th>
|
|
|
|
<th height="30" colspan="3" align="center">Herausforderungen</th>
|
|
|
|
</tr>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<tr>
|
|
|
|
<th align="Left" height="25">Clan herausfordern</th>
|
|
|
|
<th align="Left" height="25">Clan herausfordern</th>
|
|
|
@ -348,37 +404,40 @@ function displayClanFightMenu($user) {
|
|
|
|
<th align="center" height="25">Anzahl</th>
|
|
|
|
<th align="center" height="25">Anzahl</th>
|
|
|
|
<th align="center" height="25">Status</th>
|
|
|
|
<th align="center" height="25">Status</th>
|
|
|
|
</tr>
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
<?php
|
|
|
|
<?php
|
|
|
|
foreach ($open_challenge_requests as $challenge) {
|
|
|
|
if(count($open_challenge_requests) == 0) {
|
|
|
|
$requester_clan = getClan($challenge['clan_requester']);
|
|
|
|
echo '<td align ="center" colspan="5" height="20">Keine</td>';
|
|
|
|
$challenged_clan = getClan($challenge['clan_challenged']);
|
|
|
|
} else {
|
|
|
|
|
|
|
|
foreach ($open_challenge_requests as $challenge) {
|
|
|
|
//unterscheidung zwischen herausforder und herausgeforderter
|
|
|
|
$requester_clan = getClan($challenge['clan_requester']);
|
|
|
|
if($user_clan['id'] == $challenge['clan_requester']) {
|
|
|
|
$challenged_clan = getClan($challenge['clan_challenged']);
|
|
|
|
echo '<tr><td align ="center">'.$challenged_clan['clanname'].'</td><td align ="center">'.formatTimestamp($challenge['challenged_time']).'</td>';
|
|
|
|
|
|
|
|
echo '<td align ="center">'.getFightType($challenge['type']).'</td><td align ="center">'.$challenge['anzahl_chars'].'</td>';
|
|
|
|
//unterscheidung zwischen herausforder und herausgeforderter
|
|
|
|
echo '<td align ="center">ausstehend (<a href="index.php?as=clan/kampf_info&action=q_withdrawchallenge&clanid='.$requester_clan['id'].'">zurückziehen</a>)</td></tr>';
|
|
|
|
if($user_clan['id'] == $challenge['clan_requester']) {
|
|
|
|
} else {
|
|
|
|
echo '<tr><td align ="center">'.$challenged_clan['clanname'].'</td><td align ="center">'.formatTimestamp($challenge['challenged_time']).'</td>';
|
|
|
|
echo '<tr><td align ="center">'.$requester_clan['clanname'].'</td><td align ="center">'.formatTimestamp($challenge['challenged_time']).'</td>';
|
|
|
|
echo '<td align ="center">'.getFightType($challenge['type']).'</td><td align ="center">'.$challenge['anzahl_chars'].'</td>';
|
|
|
|
echo '<td align ="center">'.getFightType($challenge['type']).'</td><td align ="center">'.$challenge['anzahl_chars'].'</td>';
|
|
|
|
echo '<td align ="center">ausstehend (<a href="index.php?as=clan/kampf_info&action=q_withdrawclanchallenge&clanid='.$challenged_clan['id'].'">zurückziehen</a>)</td></tr>';
|
|
|
|
echo '<td align ="center"><a href="index.php?as=clan/kampf_info&action=acceptchallenge&clanid='.$requester_clan['id'].'">annehmen</a> |';
|
|
|
|
} else {
|
|
|
|
echo '<a href="index.php?as=clan/kampf_info&action=q_denychallenge&clanid='.$requester_clan['id'].'">ablehnen</a></td></tr>';
|
|
|
|
echo '<tr><td align ="center">'.$requester_clan['clanname'].'</td><td align ="center">'.formatTimestamp($challenge['challenged_time']).'</td>';
|
|
|
|
|
|
|
|
echo '<td align ="center">'.getFightType($challenge['type']).'</td><td align ="center">'.$challenge['anzahl_chars'].'</td>';
|
|
|
|
|
|
|
|
echo '<td align ="center"><a href="index.php?as=clan/kampf_info&action=acceptclanchallenge&clanid='.$requester_clan['id'].'">annehmen</a> |';
|
|
|
|
|
|
|
|
echo '<a href="index.php?as=clan/kampf_info&action=q_denyclanchallenge&clanid='.$requester_clan['id'].'">ablehnen</a></td></tr>';
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
?>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
</table>
|
|
|
|
</table>
|
|
|
|
</td>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<tr>
|
|
|
|
<th height="30" colspan="2" align="center">offene Herausforderungen</th>
|
|
|
|
<th height="30" colspan="3" align="center">offene Herausforderungen</th>
|
|
|
|
</tr>
|
|
|
|
</tr>
|
|
|
|
<?php
|
|
|
|
|
|
|
|
if(count($open_challenge_ids) == 0) {
|
|
|
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
<tr>
|
|
|
|
<td height="20" colspan="2" align="center">Keine</td>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
<?php
|
|
|
|
|
|
|
|
if(count($open_challenge_ids) == 0) {
|
|
|
|
|
|
|
|
echo '<td height="20" colspan="2" align="center">Keine</td>';
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
foreach ($open_challenge_ids as $oci) {
|
|
|
|
foreach ($open_challenge_ids as $oci) {
|
|
|
|
$participating_clan_ids = getParticipatingClanIDs($oci);
|
|
|
|
$participating_clan_ids = getParticipatingClanIDs($oci);
|
|
|
@ -388,30 +447,47 @@ function displayClanFightMenu($user) {
|
|
|
|
echo '<tr>';
|
|
|
|
echo '<tr>';
|
|
|
|
echo '<td> '.$challenged_clan['clanname'].'</td>';
|
|
|
|
echo '<td> '.$challenged_clan['clanname'].'</td>';
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=showchallenge&challenge='.$oci.'">'.anzeigen.'</a></td>';
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=showchallenge&challenge='.$oci.'">'.anzeigen.'</a></td>';
|
|
|
|
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=q_cancelclanchallenge&challenge='.$oci.'">'.abbrechen.'</a></td>';
|
|
|
|
echo '</tr>';
|
|
|
|
echo '</tr>';
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
?>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<th height="30" colspan="3" align="center">Laufende Herausforderungen</th>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
if(count($active_clan_challange_ids) == 0) {
|
|
|
|
|
|
|
|
echo '<td height="20" colspan="3" align="center">Keine</td>';
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
foreach ($active_clan_challange_ids as $acci) {
|
|
|
|
|
|
|
|
$participating_clan_ids = getParticipatingClanIDs($acci);
|
|
|
|
|
|
|
|
foreach ($participating_clan_ids as $pci)
|
|
|
|
|
|
|
|
if($pci != $user_clan['id']) {
|
|
|
|
|
|
|
|
$challenged_clan = getClan($pci);
|
|
|
|
|
|
|
|
echo '<tr><td align="center"> '.$challenged_clan['clanname'].'</td>';
|
|
|
|
|
|
|
|
//TODO: hier muss javascript fenster aufgerufen werden
|
|
|
|
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=showoldchallenge&challenge='.$acci.'">'.anzeigen.'</a></td></tr>';
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
|
|
|
<tr>
|
|
|
|
<tr>
|
|
|
|
<th height="30" colspan="2" align="center">Beendete Herausforderungen</th>
|
|
|
|
<th height="30" colspan="3" align="center">Beendete Herausforderungen</th>
|
|
|
|
</tr>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<tr>
|
|
|
|
<?php
|
|
|
|
<?php
|
|
|
|
if(count($old_challenge_ids) == 0) {
|
|
|
|
if(count($old_challenge_ids) == 0) {
|
|
|
|
?>
|
|
|
|
echo '<td height="20" colspan="3" align="center">Keine</td>';
|
|
|
|
<td height="20" colspan="2" align="center">Keine</td>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
foreach ($old_challenge_ids as $oci) {
|
|
|
|
foreach ($old_challenge_ids as $oci) {
|
|
|
|
$participating_clan_ids = getParticipatingClanIDs($oci);
|
|
|
|
$participating_clan_ids = getParticipatingClanIDs($oci);
|
|
|
|
foreach ($participating_clan_ids as $pci)
|
|
|
|
foreach ($participating_clan_ids as $pci)
|
|
|
|
if($pci != $user_clan['id']) {
|
|
|
|
if($pci != $user_clan['id']) {
|
|
|
|
$challenged_clan = getClan($pci);
|
|
|
|
$challenged_clan = getClan($pci);
|
|
|
|
echo '<tr>';
|
|
|
|
echo '<tr><td> '.$challenged_clan['clanname'].'</td>';
|
|
|
|
echo '<td> '.$challenged_clan['clanname'].'</td>';
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=showoldchallenge&challenge='.$oci.'">'.anzeigen.'</a></td></tr>';
|
|
|
|
echo '<td align="center"><a href="index.php?as=clan/kampf_info&action=showoldchallenge&challenge='.$oci.'">'.anzeigen.'</a></td>';
|
|
|
|
|
|
|
|
echo '</tr>';
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -426,18 +502,17 @@ switch($action) {
|
|
|
|
case 'challengeclan':
|
|
|
|
case 'challengeclan':
|
|
|
|
displayChallengeClan($user_ida, $challangedclan_id);
|
|
|
|
displayChallengeClan($user_ida, $challangedclan_id);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case 'acceptchallenge':
|
|
|
|
case 'acceptclanchallenge':
|
|
|
|
displayChallengeAccepted($user_ida, $inquirychallenge_clanid);
|
|
|
|
displayChallengeAccepted($user_ida, $inquirychallenge_clanid);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case 'q_denychallenge':
|
|
|
|
case 'q_denyclanchallenge':
|
|
|
|
displayDenyChallenge($inquirychallenge_clanid, DENY_CHALLENGE);
|
|
|
|
displayDenyChallenge($inquirychallenge_clanid, DENY_CHALLENGE);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case 'q_withdrawchallenge':
|
|
|
|
case 'q_withdrawclanchallenge':
|
|
|
|
displayDenyChallenge($inquirychallenge_clanid, WITHDRAW_CHALLENGE);
|
|
|
|
displayDenyChallenge($inquirychallenge_clanid, WITHDRAW_CHALLENGE);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case 'denychallenge':
|
|
|
|
case 'denychallenge':
|
|
|
|
denyChallengeRequest($inquirychallenge_clanid, $user_ida);
|
|
|
|
denyChallenge($type, $inquirychallenge_clanid, $user_ida);
|
|
|
|
displayClanFightMenu($user_ida);
|
|
|
|
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case 'showchallenge':
|
|
|
|
case 'showchallenge':
|
|
|
|
displayShowChallenge($clan_challange_id, $user_ida);
|
|
|
|
displayShowChallenge($clan_challange_id, $user_ida);
|
|
|
@ -451,6 +526,12 @@ switch($action) {
|
|
|
|
case 'leavechallenge':
|
|
|
|
case 'leavechallenge':
|
|
|
|
displayLeaveChallenge($user_ida, $clan_challange_id, $char_id);
|
|
|
|
displayLeaveChallenge($user_ida, $clan_challange_id, $char_id);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
|
|
|
|
case 'q_cancelclanchallenge':
|
|
|
|
|
|
|
|
displayCancelChallenge($user_ida, $clan_challange_id);
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case 'cancelchallenge':
|
|
|
|
|
|
|
|
cancelThisChallenge($user_ida, $clan_challange_id);
|
|
|
|
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
default:
|
|
|
|
displayClanFightMenu($user_ida);
|
|
|
|
displayClanFightMenu($user_ida);
|
|
|
|
}
|
|
|
|
}
|
|
|
|