From f8d08eb37ca24ca835b7f44548bc300dd99b8d53 Mon Sep 17 00:00:00 2001 From: duckietm Date: Mon, 19 Dec 2022 08:50:59 +0100 Subject: [PATCH] Add missing file & add ENV setting for URL Path --- .env.new | 1 + index.ts | 1 + src/main.ts | 7 ++++--- 3 files changed, 6 insertions(+), 3 deletions(-) create mode 100644 index.ts diff --git a/.env.new b/.env.new index 99f6d7e..dbe36ad 100644 --- a/.env.new +++ b/.env.new @@ -1,5 +1,6 @@ API_HOST=localhost API_PORT=3030 +IMAGER_PATH='/' AVATAR_SAVE_PATH=C:/nitro-converted-assets AVATAR_ACTIONS_URL=https://website.com/gamedata/HabboAvatarActions.json AVATAR_FIGUREDATA_URL=https://website.com/gamedata/FigureData.json diff --git a/index.ts b/index.ts new file mode 100644 index 0000000..c5e2375 --- /dev/null +++ b/index.ts @@ -0,0 +1 @@ +require('./src/main'); \ No newline at end of file diff --git a/src/main.ts b/src/main.ts index 83fa90b..f36b3f8 100644 --- a/src/main.ts +++ b/src/main.ts @@ -17,9 +17,10 @@ async function init(): Promise await AvatarRenderManager.init(); const router = express(); - - router.get('/', HttpRouter); - + const urlpath = (process.env.IMAGER_PATH as string); + + router.get(urlpath, HttpRouter); + const host = (process.env.API_HOST as string); const port = parseInt(process.env.API_PORT);