From afac3a4a31ca9cf2f0c2b0f1aaf4578e0a1cde8f Mon Sep 17 00:00:00 2001 From: Thomas G <62822072+Thomasluigi07@users.noreply.github.com> Date: Wed, 14 Sep 2022 19:30:32 +1000 Subject: [PATCH] add CharacterFetch + BodyColors --- app/Http/Controllers/ClientController.php | 10 +++++++++ resources/views/client/BodyColors.blade.php | 22 +++++++++++++++++++ .../views/client/CharacterFetch.blade.php | 7 ++++++ resources/views/client/join.blade.php | 6 ++--- routes/web.php | 3 ++- 5 files changed, 44 insertions(+), 4 deletions(-) create mode 100644 resources/views/client/BodyColors.blade.php create mode 100644 resources/views/client/CharacterFetch.blade.php diff --git a/app/Http/Controllers/ClientController.php b/app/Http/Controllers/ClientController.php index f67b487..bd0bc4d 100644 --- a/app/Http/Controllers/ClientController.php +++ b/app/Http/Controllers/ClientController.php @@ -90,4 +90,14 @@ class ClientController extends Controller { return view('client.login_iframe'); } + + public function bodycolors() + { + return view('client.BodyColors'); + } + + public function characterfetch() + { + return view('client.CharacterFetch'); + } } diff --git a/resources/views/client/BodyColors.blade.php b/resources/views/client/BodyColors.blade.php new file mode 100644 index 0000000..3ff3661 --- /dev/null +++ b/resources/views/client/BodyColors.blade.php @@ -0,0 +1,22 @@ +@php +header("content-type:text/plain"); +$userId = addslashes($_GET["userId"]); +//TODO: add avatar system +@endphp + + + null + nil + + + 45 + 45 + 1003 + Body Colors + 45 + 1003 + 1003 + true + + + \ No newline at end of file diff --git a/resources/views/client/CharacterFetch.blade.php b/resources/views/client/CharacterFetch.blade.php new file mode 100644 index 0000000..ff537ba --- /dev/null +++ b/resources/views/client/CharacterFetch.blade.php @@ -0,0 +1,7 @@ +@php +header("content-type:application/xml"); +ob_start(); +$userId = addslashes($_GET["userId"]); +//TODO: add catalog + avatar system +@endphp +http://morblox.us/Asset/BodyColors.ashx?userId=@php echo $userId @endphp; \ No newline at end of file diff --git a/resources/views/client/join.blade.php b/resources/views/client/join.blade.php index 7dd3039..5962d5c 100644 --- a/resources/views/client/join.blade.php +++ b/resources/views/client/join.blade.php @@ -11,15 +11,15 @@ $app = addslashes($_GET["app"]);*/ if (Auth::check()) { $username = addslashes(Auth::user()->name); $id = addslashes(Auth::id()); + $app = addslashes(Auth::id()); } else { $randName = mt_rand(1, 9999); $username = "Guest " . $randName; $id = 0; + $app = 0 } $ip = addslashes($_GET["ip"]); $port = addslashes($_GET["port"]); -$app = 'test'; -//$app = addslashes($_GET["app"]); ob_start(); @endphp @@ -235,7 +235,7 @@ local success, err = pcall(function() -- Overriden onPlayerAdded(player) - player.CharacterAppearance = "" + player.CharacterAppearance = "http://morblox.us/Asset/CharacterFetch.ashx?userId=" if not test then visit:SetUploadUrl("")end player.Name = "" end) diff --git a/routes/web.php b/routes/web.php index 21a77bd..459362a 100644 --- a/routes/web.php +++ b/routes/web.php @@ -99,4 +99,5 @@ Route::get('/Game/Tools/InsertAsset.ashx', [App\Http\Controllers\ClientControlle Route::get('/UI/Save.aspx', [App\Http\Controllers\ClientController::class, 'modelupload'])->name('modelupload'); Route::get('/Game/Tools/ThumbnailAsset.ashx', [App\Http\Controllers\ClientController::class, 'stampertools'])->name('stampertools'); Route::get('/Game/edit.ashx', [App\Http\Controllers\ClientController::class, 'edit'])->name('edit'); -Route::get('/Login/iFrameLogin.aspx', [App\Http\Controllers\ClientController::class, 'login_iframe'])->name('login_iframe'); \ No newline at end of file +Route::get('/Asset/BodyColors.ashx', [App\Http\Controllers\ClientController::class, 'bodycolors'])->name('bodycolors'); +Route::get('/Asset/CharacterFetch.ashx', [App\Http\Controllers\ClientController::class, 'characterfetch'])->name('characterfetch'); \ No newline at end of file