On master: Team disguises options
This commit is contained in:
commit
451b4a9465
19
config.yml
19
config.yml
@ -1,47 +1,64 @@
|
||||
# Shall I notify people of a LibsDisguises update?
|
||||
NotifyUpdate: true
|
||||
|
||||
# Should the plugin use scoreboards to disable pushing? Please note that disabling this effectively means that self disguises will push the disguiser around
|
||||
# Alternatively when this is enabled this will remove the player from any scoreboard team he is in
|
||||
DisablePushing: true
|
||||
|
||||
# Whats the permission to get the notification?
|
||||
Permission: 'libsdisguises.update'
|
||||
|
||||
# Whats the max size allowed for command disguiseradius
|
||||
DisguiseRadiusMax: 50
|
||||
|
||||
# Whats the max size allowed for command undisguiseradius
|
||||
UndisguiseRadiusMax: 50
|
||||
|
||||
# Shall the players view their disguises?
|
||||
# Best used when viewing yourself in 3rd person
|
||||
ViewSelfDisguises: true
|
||||
|
||||
# Shall I disguise the sounds?
|
||||
# This turns your damage sound into a MOOOO
|
||||
DisguiseSounds: true
|
||||
|
||||
# Shall the disguised hear their disguise sounds or their damage sounds.
|
||||
# I disable this as it can be a little confusing when not used with self disguises
|
||||
HearSelfDisguise: true
|
||||
|
||||
# Shall I send the velocity packets? I REALLY recommend you don't disable.
|
||||
# This is the only thing allowing the mobs to fly without glitching out.
|
||||
SendVelocity: true
|
||||
|
||||
# For self disguises, they need to have the armor and the held item removed
|
||||
# Else they see floating armor, floating held items.
|
||||
# This turns the items invisible in the disguised players inventory. It does not actually remove them!
|
||||
RemoveArmor: true
|
||||
RemoveHeldItem: false
|
||||
|
||||
# If you set a disguise to burning, it will no longer be able to be shown as sneaking or invisible.
|
||||
# Set this to true if you want the disguise to get the animations of the disguised entity. Such as invisible, on fire, sprinting, sneaking, blocking
|
||||
# This is only valid if you set a animation on the disguise itself. Because the entitys animations are applied otherwise.
|
||||
AddEntityAnimations: true
|
||||
|
||||
# When a sheep or wolf is right clicked with dye. The client automatically assumes it was successful and displays the sheeps wool or the wolfs collar as dyed.
|
||||
# This is a option that either prevents that happening, or it changes their color officially in the plugin so that everyone sees it changed.
|
||||
# Its currently set to false which means that the color is not changed and will refresh itself to the player.
|
||||
# Please note that this will not remove the dye from their hands. This also does not check if the disguised entity is actually a sheep/wolf and wants a say in its color.
|
||||
DyeableSheep: false
|
||||
DyeableWolf: false
|
||||
|
||||
# This is only called into action when the disguise is constructed using the commands.
|
||||
# And when the disguise supports that. This will not be used at all for plugins constructing the disguises for instance.
|
||||
# Such as prophunt. Its also false because its kind of a retarded feature.
|
||||
# This is pretty simple. It shows the players displayname (Name as it appears in chat) above their head.
|
||||
# This also overrides any custom name they have set in their disguise options.
|
||||
ShowNamesAboveDisguises: false
|
||||
|
||||
# This supports the above option.
|
||||
# If this is true, then the name shown above the head appears regardless of if you are looking at the disguise directly or not.
|
||||
NameAboveHeadAlwaysVisible: true
|
||||
|
||||
# This modifys the bounding box, This is stuff like can a arrow hit them.
|
||||
# If you turn this to true, arrows will act like they hit the disguise in the right place!
|
||||
# So someone disguised as a enderdragon will easily get shot down by arrows!
|
||||
@ -49,10 +66,12 @@ NameAboveHeadAlwaysVisible: true
|
||||
# This shouldn't really be enabled for players as it also interferes with their movement because the server thinks the player is larger than he really is.
|
||||
# That makes the player unable to approach this building because the server thinks he is trying to glitch inside blocks.
|
||||
ModifyBoundingBox: false
|
||||
|
||||
# This prevents disguised players from being targeted by monsters.
|
||||
# This doesn't prevent their targeting you if already targeting when disguised
|
||||
# They will just ignore you unless provoked.
|
||||
MonstersIgnoreDisguises: false
|
||||
|
||||
# Sigh. People are going to want this.
|
||||
# So lets make your disguise blown if you are attacked..
|
||||
# Works only for disguised players when attacked by a entity (arrow, monster. etc)
|
||||
|
@ -56,6 +56,7 @@ public class DisguiseConfig {
|
||||
private static String updateNotificationPermission;
|
||||
private static boolean viewSelfDisguise;
|
||||
private static boolean witherSkullEnabled;
|
||||
private static boolean disablePushing;
|
||||
|
||||
public static Entry<String, Disguise> getCustomDisguise(String disguise) {
|
||||
for (Entry<String, Disguise> entry : customDisguises.entrySet()) {
|
||||
@ -68,6 +69,10 @@ public class DisguiseConfig {
|
||||
return null;
|
||||
}
|
||||
|
||||
public static boolean isPushingDisabled() {
|
||||
return disablePushing;
|
||||
}
|
||||
|
||||
public static HashMap<String, Disguise> getCustomDisguises() {
|
||||
return customDisguises;
|
||||
}
|
||||
@ -136,6 +141,7 @@ public class DisguiseConfig {
|
||||
setHideDisguisedPlayers(config.getBoolean("HideDisguisedPlayersFromTab"));
|
||||
setShowDisguisedPlayersInTab(config.getBoolean("ShowPlayerDisguisesInTab"));
|
||||
setDisabledInvisibility(config.getBoolean("DisableInvisibility"));
|
||||
disablePushing = config.getBoolean("DisablePushing");
|
||||
|
||||
customDisguises.clear();
|
||||
|
||||
|
@ -988,6 +988,7 @@ public class DisguiseUtilities {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
if (DisguiseConfig.isPushingDisabled()) {
|
||||
// Code to stop player pushing in 1.9
|
||||
Scoreboard scoreboard = player.getScoreboard();
|
||||
Team t;
|
||||
@ -995,6 +996,7 @@ public class DisguiseUtilities {
|
||||
if ((t = scoreboard.getTeam("LDPushing")) != null) {
|
||||
t.removeEntry(player.getName());
|
||||
}
|
||||
}
|
||||
|
||||
// player.spigot().setCollidesWithEntities(true);
|
||||
// Finish up
|
||||
@ -1071,6 +1073,7 @@ public class DisguiseUtilities {
|
||||
return;
|
||||
}
|
||||
|
||||
if (DisguiseConfig.isPushingDisabled()) {
|
||||
// Code to stop player pushing
|
||||
Scoreboard scoreboard = player.getScoreboard();
|
||||
Team t;
|
||||
@ -1086,6 +1089,7 @@ public class DisguiseUtilities {
|
||||
|
||||
if (!t.hasEntry(player.getName()))
|
||||
t.addEntry(player.getName());
|
||||
}
|
||||
|
||||
// Add himself to his own entity tracker
|
||||
Object trackedPlayersObj = ReflectionManager.getNmsField("EntityTrackerEntry", "trackedPlayers")
|
||||
|
Loading…
Reference in New Issue
Block a user