A Typescript server emulator for Box Critters, a defunct virtual world.
1# Localbox 2 3Reopen the dusty box of the world of Box Critters! This repository features a 4Typescript server emulator, **built using Deno**. The version of the game the 5server is built around is **client version 161**. 6 7This repository appears empty because it is a fork of my private repository so 8that the assets didn't get included in the public version of the repository. 9 10_project start: late November 2024_ 11 12## Assets 13 14The assets for the game are not included in this repository, since I've been 15told that Rocketsnail has taken down GitHub repositories for hosting the assets. 16Though, I find it ironic since the modding community has been allowed to freely 17host asset archives [here](https://github.com/boxcrittersmods/BCArchive) for 5 18years at this point. As far as I can see, Localbox has the most comprehensive 19archive of Box Critters assets, compiling several sources & custom spritesheet 20JSON for spritesheet mis-matches. 21 22### Archive Statistics 23 24Below is a break down of the archive compilation, to be consider archived the 25spritesheet has to be archived (spritesheet JSON is not taken into 26consideration, as it is pretty easy to custom make). To get the assets, feel 27free message me on Discord: @index.lua 28 29> _Note:_ I do plan on manually cropping some rooms to make custom spritesheets, 30> but when I do those will be marked as custom and not legit. 31 32- **6/7** full-time rooms archived 33 - Full-time rooms are rooms that were always available, no matter the party. 34 - Missing: [_Jungle_](https://box-critters.fandom.com/wiki/Jungle) 35 36- **6/10** party-exclusive rooms archived 37 - Party-exclusive rooms are rooms that were only available during specific 38 parties. 39 - Missing: 40 [_Holiday Cliff_](https://box-critters.fandom.com/wiki/Holiday_Cliff), 41 [_Holiday Forest_](https://box-critters.fandom.com/wiki/Holiday_Forest), 42 [_CritterCon Hall_](https://box-critters.fandom.com/wiki/Critter_Con_Hall), 43 [_Box Realm_](https://box-critters.fandom.com/wiki/Box_Realm) 44 45- **465/590** released items archived 46 47- **12/12** critters archived 48 49- **2/2** mini-games archived 50 - This count excludes _Critter Ball_, because that requires an entirely 51 separate backend. If you want to relive _Critter Ball_, check out 52 [FarawayDrip30's Critter Ball server](https://farawaydrip30.itch.io/critterball-server). 53 54## Party Switcher 55 56A custom party switcher has been implemented, you can change the party on the 57log-in page, or using the `/party [ID]` command in-game. For a breakdown of 58party room recreation progress, go [here](Events.md). 59 60## Development 61 62### CLI 63 64> Installation 65 66```bash 67deno install 68``` 69 70> Serving 71 72```bash 73deno run start 74> Listening on http://localhost:3257/ 75``` 76 77> Building to an executable (shorthand invocation of `deno compile` using 78> already-set flags & config) 79 80```bash 81deno run build 82> If the command is a success, a "Localbox" executable will appear in the project directory. 83``` 84 85### APIs 86 87The game has 4 APIs for debugging or for use by the game client: 88 89- (GET) `/api/server/players` 90 - This API returns information on the player(s) in-game, if any. 91 92- (GET) `/api/server/rooms` 93 - This API returns almost-identical information as the `/api/client/rooms` 94 API, however it returns information on all hashes of all rooms with no 95 required party ID URL parameter. 96 97- (POST) `/api/client/login` 98 - This API takes in all the information provided by the user on log-in and 99 generates a JWT for that session. 100 101- (GET) `/api/client/rooms?partyId=` 102 - This API returns information on the parties the game supports, and depending 103 on the party ID provided in the URL, information for each room that party 104 changes in some way. If the party does not change the room in any way, the 105 default version of that room will be returned. All the data is gathered by 106 the server reading the `/public/media/rooms/` directory of the game - and 107 cached for future requests. 108 109## Contributors 110 111- [jonastisell](https://github.com/jonastisell) - spritesheet extraction help & 112 moral support 113- [Boo0](https://github.com/Boo6447) - provided archived assets of party room 114 versions & moral support 115- [@boxcrittersmods/BCArchive](https://github.com/boxcrittersmods/BCArchive) - 116 provided a lot of archived assets of early rooms