mirror of
https://github.com/BentoBoxWorld/Challenges.git
synced 2024-11-15 07:05:48 +01:00
Fast bug fix when users could not write a valid input via chat message.
This commit is contained in:
commit
4caeee6d64
2
pom.xml
2
pom.xml
@ -42,7 +42,7 @@
|
||||
<!-- Revision variable removes warning about dynamic version -->
|
||||
<revision>${build.version}-SNAPSHOT</revision>
|
||||
<!-- This allows to change between versions and snapshots. -->
|
||||
<build.version>0.8.1</build.version>
|
||||
<build.version>0.8.2</build.version>
|
||||
<build.number>-LOCAL</build.number>
|
||||
</properties>
|
||||
|
||||
|
@ -1085,7 +1085,13 @@ public abstract class CommonGUI
|
||||
// On cancel conversation will be closed.
|
||||
withEscapeSequence("cancel").
|
||||
// Use null value in consumer to detect if user has abandoned conversation.
|
||||
addConversationAbandonedListener(abandonedEvent -> consumer.accept(null)).
|
||||
addConversationAbandonedListener(abandonedEvent ->
|
||||
{
|
||||
if (!abandonedEvent.gracefulExit())
|
||||
{
|
||||
consumer.accept(null);
|
||||
}
|
||||
}).
|
||||
withPrefix(context -> user.getTranslation("challenges.gui.questions.prefix")).
|
||||
buildConversation(user.getPlayer());
|
||||
|
||||
|
@ -720,7 +720,13 @@ public class AdminGUI extends CommonGUI
|
||||
// On cancel conversation will be closed.
|
||||
withEscapeSequence("cancel").
|
||||
// Use null value in consumer to detect if user has abandoned conversation.
|
||||
addConversationAbandonedListener(abandonedEvent -> consumer.accept(null)).
|
||||
addConversationAbandonedListener(abandonedEvent ->
|
||||
{
|
||||
if (!abandonedEvent.gracefulExit())
|
||||
{
|
||||
consumer.accept(null);
|
||||
}
|
||||
}).
|
||||
withLocalEcho(false).
|
||||
withPrefix(context -> user.getTranslation("challenges.gui.questions.prefix")).
|
||||
buildConversation(user.getPlayer());
|
||||
|
@ -480,7 +480,13 @@ public class NumberGUI
|
||||
// On cancel conversation will be closed.
|
||||
withEscapeSequence("cancel").
|
||||
// Use null value in consumer to detect if user has abandoned conversation.
|
||||
addConversationAbandonedListener(abandonedEvent -> consumer.accept(null)).
|
||||
addConversationAbandonedListener(abandonedEvent ->
|
||||
{
|
||||
if (!abandonedEvent.gracefulExit())
|
||||
{
|
||||
consumer.accept(null);
|
||||
}
|
||||
}).
|
||||
withPrefix(context ->
|
||||
NumberGUI.this.user.getTranslation("challenges.gui.questions.prefix")).
|
||||
buildConversation(user.getPlayer());
|
||||
|
@ -305,7 +305,13 @@ public class StringListGUI
|
||||
// On cancel conversation will be closed.
|
||||
withEscapeSequence("cancel").
|
||||
// Use null value in consumer to detect if user has abandoned conversation.
|
||||
addConversationAbandonedListener(abandonedEvent -> consumer.accept(null)).
|
||||
addConversationAbandonedListener(abandonedEvent ->
|
||||
{
|
||||
if (!abandonedEvent.gracefulExit())
|
||||
{
|
||||
consumer.accept(null);
|
||||
}
|
||||
}).
|
||||
withLocalEcho(false).
|
||||
withPrefix(context -> user.getTranslation("challenges.gui.questions.prefix")).
|
||||
buildConversation(user.getPlayer());
|
||||
|
Loading…
Reference in New Issue
Block a user