This commit is contained in:
ui0ppk 2023-02-05 01:40:43 +02:00
commit 3c26911da3
2 changed files with 27 additions and 0 deletions

View File

@ -11,6 +11,10 @@ if($devmode) {
error_reporting(E_ALL);
}
$site = [
"url" => "http://".$_SERVER["HTTP_HOST"]
];
$pagename = ucfirst(str_replace(".php", "", str_replace("/", "", $_SERVER['DOCUMENT_URI'] ?? $_SERVER['PHP_SELF'])));
$maintainers = array("Mario1", "qzip", "nolanwhy");

23
game/PlaceLauncher.php Normal file
View File

@ -0,0 +1,23 @@
<?php
require_once '../core/config.php';
$allstatus = [
1 => "Wait",
2 => "Working",
3 => "Disabled",
4 => "Failed to start",
5 => "Game ended",
6 => "Full"
];
$status = 2;
$ip = "127.0.0.1";
$port = 53640;
$job = 69;
$response = [
"jobId" => $job,
"status" => $status,
"joinScriptUrl" => $site["url"]."/game/join?ip=$ip&port=$port&gameid=1818&jobid=$job",
"authenticationUrl" => $site["url"]."/Login/Negotiate.ashx",
"authenticationTicket" => "1",
"message" => $allstatus[$status]
];
echo json_encode($response);