Improving LoadingScreen global variable
Certurix
I believe there is some missing data in the LoadingScreen global variable, and I would like to suggest improvements to both the data structure and handling.
- Organizing Data into Tables
We should organize the data into tables based on their types. Currently, there are two types: server and player. These can be structured as follows:
var LoadingScreen = {
server: {
ip,
name,
description,
port
},
player: {
nanos_id,
nanos_username
}
};
- Adding New Data Fields
I recommend adding the following new data fields to the player table to better integrate Steam-related information:
- player.steam64_id: Returns a number value corresponding to the 64-bit SteamID.
- player.steam_id: Returns a string value corresponding to the standard SteamID (e.g., STEAM_1:0:11101).
- player.steam_username: Returns a string value for the Steam username.
- player.steam_avatar: Returns a string containing the URL of the Steam user’s avatar.
The above list is not exhaustive, and some fields are probably missing. Feel free to add your own idea or new data to add to this thread.