Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-26 16:12:42 +01:00
Allow disabling of auto-complete in 1.13 via disable-1_13-auto-complete in config #891
Dieser Commit ist enthalten in:
Ursprung
84aaec6bff
Commit
527b5e6f99
@ -209,4 +209,9 @@ public class BukkitConfigAPI extends Config implements ViaVersionConfig {
|
|||||||
public boolean isSuppress1_13ConversionErrors() {
|
public boolean isSuppress1_13ConversionErrors() {
|
||||||
return getBoolean("suppress-1_13-conversion-errors", false);
|
return getBoolean("suppress-1_13-conversion-errors", false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isDisable1_13AutoComplete() {
|
||||||
|
return getBoolean("disable-1_13-auto-complete", false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -262,4 +262,9 @@ public class BungeeConfigAPI extends Config implements ViaVersionConfig {
|
|||||||
public boolean isSuppress1_13ConversionErrors() {
|
public boolean isSuppress1_13ConversionErrors() {
|
||||||
return getBoolean("suppress-1_13-conversion-errors", false);
|
return getBoolean("suppress-1_13-conversion-errors", false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isDisable1_13AutoComplete() {
|
||||||
|
return getBoolean("disable-1_13-auto-complete", false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -252,4 +252,11 @@ public interface ViaVersionConfig {
|
|||||||
* @return True if enabled
|
* @return True if enabled
|
||||||
*/
|
*/
|
||||||
boolean isSuppress1_13ConversionErrors();
|
boolean isSuppress1_13ConversionErrors();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Should we disable the 1.13 auto-complete feature to stop spam kicks? (for any server lower than 1.13)
|
||||||
|
*
|
||||||
|
* @return True if enabled
|
||||||
|
*/
|
||||||
|
boolean isDisable1_13AutoComplete();
|
||||||
}
|
}
|
||||||
|
@ -536,6 +536,10 @@ public class Protocol1_13To1_12_2 extends Protocol {
|
|||||||
handler(new PacketHandler() {
|
handler(new PacketHandler() {
|
||||||
@Override
|
@Override
|
||||||
public void handle(PacketWrapper wrapper) throws Exception {
|
public void handle(PacketWrapper wrapper) throws Exception {
|
||||||
|
// Disable auto-complete if configured
|
||||||
|
if (Via.getConfig().isDisable1_13AutoComplete()) {
|
||||||
|
wrapper.cancel();
|
||||||
|
}
|
||||||
int tid = wrapper.read(Type.VAR_INT);
|
int tid = wrapper.read(Type.VAR_INT);
|
||||||
// Save transaction id
|
// Save transaction id
|
||||||
wrapper.user().get(TabCompleteTracker.class).setTransactionId(tid);
|
wrapper.user().get(TabCompleteTracker.class).setTransactionId(tid);
|
||||||
|
@ -90,6 +90,8 @@ quick-move-action-fix: false
|
|||||||
team-colour-fix: true
|
team-colour-fix: true
|
||||||
# We warn when there's a error converting from pre-1.13 to 1.13, should we suppress these? (Only suggested if spamming)
|
# We warn when there's a error converting from pre-1.13 to 1.13, should we suppress these? (Only suggested if spamming)
|
||||||
suppress-1_13-conversion-errors: false
|
suppress-1_13-conversion-errors: false
|
||||||
|
# 1.13 introduced new auto complete which can trigger "Kicked for spamming" for servers older than 1.13, the following option will disable it completely.
|
||||||
|
disable-1_13-auto-complete: false
|
||||||
#
|
#
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
# 1.9 & 1.10 CLIENTS ON 1.8 SERVERS OPTIONS #
|
# 1.9 & 1.10 CLIENTS ON 1.8 SERVERS OPTIONS #
|
||||||
|
@ -215,4 +215,9 @@ public class SpongeConfigAPI extends Config implements ViaVersionConfig {
|
|||||||
public boolean isSuppress1_13ConversionErrors() {
|
public boolean isSuppress1_13ConversionErrors() {
|
||||||
return getBoolean("suppress-1_13-conversion-errors", false);
|
return getBoolean("suppress-1_13-conversion-errors", false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isDisable1_13AutoComplete() {
|
||||||
|
return getBoolean("disable-1_13-auto-complete", false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren