hykilpikonna / AquaDX

A certain magical arcade server
https://aquadx.net
Other
285 stars 66 forks source link

Added UserBox page (Chunithm) #42

Closed alexay7 closed 3 months ago

alexay7 commented 5 months ago

Fixes #41

It connects to the chuni v2 endpoints in the AQUA_HOST server in order to fetch the data about the user's current userbox, the item's labels and the items unlocked by the user.

Getting the aimeId was required for having access to this data, this is done using the endpoint getByAccessCode.

I also added a new variable in config.ts with name HAS_USERBOX_ASSETS that should be turned off if the server does not have the images of the userbox items ready. If this variable is set as false, the selects will still work but the user wont be able to preview what it chooses.

Requirements for assets to be shown

Ex.

{
"1":"This is my trophy",
"927":"Should be easy to access"
}

Ex.

systemVoice/46.png
avatarAccessory/2194730.png

This is how the assets folder should look like

|- throphies.json
|- 00/
|- systemVoice/
|- namePlate/
|- music/
|- mapIcon/
|- avatarAccessory
|- frame/

Things that can be improved

clansty commented 5 months ago

If this feature is accepted in official aquadx.net instance, I will add the same feature for maimai