diff --git a/packages/universe/src/server/index.js b/packages/universe/src/server/index.js index 3cef227..a9f3eb9 100644 --- a/packages/universe/src/server/index.js +++ b/packages/universe/src/server/index.js @@ -5,8 +5,8 @@ import UniverseInput from './packets/decorators/universe-input'; export default { hooks: { - '@latus/core/up': async (latus) => { - const {config: {'@humus/universe': {running}}} = latus; + '@latus/core/server/up': async (latus) => { + const {config: {'@humus/universe/server': {running}}} = latus; if (!running) { return; } @@ -22,9 +22,6 @@ export default { throw new Error(`Couldn't run universe '${running}': ${error.stack}`); } }, - '@latus/http/plugins': (req, {config: {'@humus/universe': {uuid}}}) => ({ - '@humus/universe/client': {uuid}, - }), '@latus/socket/packets': gatherWithLatus( require.context('./packets', false, /\.js$/), ), diff --git a/packages/universe/src/server/packets/join.js b/packages/universe/src/server/packets/join.js index d648595..60faf8e 100644 --- a/packages/universe/src/server/packets/join.js +++ b/packages/universe/src/server/packets/join.js @@ -16,11 +16,7 @@ export default (latus) => class ServerJoin extends Join() { static async respond(packet, socket) { // eslint-disable-next-line no-unused-vars const {req: {user}} = socket; - const { - config: { - '%universe': universe, - }, - } = latus; + const universe = latus.get('%universe'); let player = universe.playerForUser(user.id); if (player) { return player.entity.instanceUuid;