Make initial skin packet delay configurable

This commit is contained in:
fullwall 2020-12-24 19:00:35 +08:00
parent 09c482e2f6
commit aa136420c8
3 changed files with 3 additions and 2 deletions

View File

@ -502,7 +502,8 @@ public class EventListen implements Listener {
@EventHandler(priority = EventPriority.MONITOR)
public void onPlayerJoin(PlayerJoinEvent event) {
skinUpdateTracker.updatePlayer(event.getPlayer(), 6 * 20, true);
skinUpdateTracker.updatePlayer(event.getPlayer(), Setting.INITIAL_PLAYER_JOIN_SKIN_PACKET_DELAY_TICKS.asInt(),
true);
if (Setting.USE_SCOREBOARD_TEAMS.asBoolean()) {
Util.updateNPCTeams(event.getPlayer(), 0);

View File

@ -107,6 +107,7 @@ public class Settings {
ERROR_COLOUR("general.color-scheme.message-error", "<c>"),
FOLLOW_ACROSS_WORLDS("npc.follow.teleport-across-worlds", true),
HIGHLIGHT_COLOUR("general.color-scheme.message-highlight", "<e>"),
INITIAL_PLAYER_JOIN_SKIN_PACKET_DELAY_TICKS("npc.skins.player-join-update-delay-ticks", 3 * 20),
KEEP_CHUNKS_LOADED("npc.chunks.always-keep-loaded", false),
LOCALE("general.translation.locale", ""),
MAX_CONTROLLABLE_GROUND_SPEED("npc.controllable.max-ground-speed", 0.5),

View File

@ -116,7 +116,6 @@ public class Skin {
return false;
}
}
setNPCSkinData(entity, skinName, skinId, skinData);
return true;