mirror of
https://github.com/PikaMug/Quests.git
synced 2024-11-27 13:15:55 +01:00
Supply external conversation hooks, part 29
This commit is contained in:
parent
1181ef099e
commit
bca22f2440
@ -110,8 +110,8 @@ public class OptionsPrompt extends QuestsEditorNumericPrompt {
|
||||
}
|
||||
}
|
||||
|
||||
public class TrueFalsePrompt extends QuestsEditorStringPrompt {
|
||||
public TrueFalsePrompt(ConversationContext context) {
|
||||
public class OptionsTrueFalsePrompt extends QuestsEditorStringPrompt {
|
||||
public OptionsTrueFalsePrompt(ConversationContext context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
@ -172,7 +172,7 @@ public class OptionsPrompt extends QuestsEditorNumericPrompt {
|
||||
context.setSessionData(tempKey, false);
|
||||
} else {
|
||||
context.getForWhom().sendRawMessage(ChatColor.RED + Lang.get("itemCreateInvalidInput"));
|
||||
return new TrueFalsePrompt(context);
|
||||
return new OptionsTrueFalsePrompt(context);
|
||||
}
|
||||
} else if (input.equalsIgnoreCase(Lang.get("cmdClear"))) {
|
||||
context.setSessionData(tempKey, null);
|
||||
@ -182,8 +182,8 @@ public class OptionsPrompt extends QuestsEditorNumericPrompt {
|
||||
}
|
||||
}
|
||||
|
||||
public class LevelPrompt extends QuestsEditorStringPrompt {
|
||||
public LevelPrompt(ConversationContext context) {
|
||||
public class OptionsLevelPrompt extends QuestsEditorStringPrompt {
|
||||
public OptionsLevelPrompt(ConversationContext context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
@ -375,11 +375,11 @@ public class OptionsPrompt extends QuestsEditorNumericPrompt {
|
||||
case 1:
|
||||
tempKey = CK.OPT_ALLOW_COMMANDS;
|
||||
tempPrompt = new OptionsGeneralPrompt(context);
|
||||
return new TrueFalsePrompt(context);
|
||||
return new OptionsTrueFalsePrompt(context);
|
||||
case 2:
|
||||
tempKey = CK.OPT_ALLOW_QUITTING;
|
||||
tempPrompt = new OptionsGeneralPrompt(context);
|
||||
return new TrueFalsePrompt(context);
|
||||
return new OptionsTrueFalsePrompt(context);
|
||||
case 3:
|
||||
tempKey = null;
|
||||
tempPrompt = null;
|
||||
@ -521,19 +521,19 @@ public class OptionsPrompt extends QuestsEditorNumericPrompt {
|
||||
case 1:
|
||||
tempKey = CK.OPT_USE_DUNGEONSXL_PLUGIN;
|
||||
tempPrompt = new OptionsMultiplayerPrompt(context);
|
||||
return new TrueFalsePrompt(context);
|
||||
return new OptionsTrueFalsePrompt(context);
|
||||
case 2:
|
||||
tempKey = CK.OPT_USE_PARTIES_PLUGIN;
|
||||
tempPrompt = new OptionsMultiplayerPrompt(context);
|
||||
return new TrueFalsePrompt(context);
|
||||
return new OptionsTrueFalsePrompt(context);
|
||||
case 3:
|
||||
tempKey = CK.OPT_SHARE_PROGRESS_LEVEL;
|
||||
tempPrompt = new OptionsMultiplayerPrompt(context);
|
||||
return new LevelPrompt(context);
|
||||
return new OptionsLevelPrompt(context);
|
||||
case 4:
|
||||
tempKey = CK.OPT_REQUIRE_SAME_QUEST;
|
||||
tempPrompt = new OptionsMultiplayerPrompt(context);
|
||||
return new TrueFalsePrompt(context);
|
||||
return new OptionsTrueFalsePrompt(context);
|
||||
case 5:
|
||||
tempKey = null;
|
||||
tempPrompt = null;
|
||||
|
@ -724,11 +724,7 @@ public class RewardsPrompt extends QuestsEditorNumericPrompt {
|
||||
QuestsEditorPostOpenStringPromptEvent event = new QuestsEditorPostOpenStringPromptEvent(context, this);
|
||||
context.getPlugin().getServer().getPluginManager().callEvent(event);
|
||||
|
||||
String lang1 = getQueryText(context);
|
||||
lang1 = lang1.replace("<comma>", ChatColor.BOLD + "" + ChatColor.RED + "comma" + ChatColor.RESET
|
||||
+ ChatColor.YELLOW);
|
||||
String lang2 = Lang.get("rewCommandPromptHint");
|
||||
return ChatColor.YELLOW + lang1 + "\n" + ChatColor.GOLD + lang2;
|
||||
return ChatColor.YELLOW + getQueryText(context);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -1879,6 +1879,7 @@ public class StageMainPrompt extends QuestsEditorNumericPrompt {
|
||||
}
|
||||
}
|
||||
|
||||
// TODO - should be a Numeric prompt
|
||||
public class DeletePrompt extends QuestsEditorStringPrompt {
|
||||
|
||||
public DeletePrompt(ConversationContext context) {
|
||||
@ -1900,9 +1901,9 @@ public class StageMainPrompt extends QuestsEditorNumericPrompt {
|
||||
QuestsEditorPostOpenStringPromptEvent event = new QuestsEditorPostOpenStringPromptEvent(context, this);
|
||||
context.getPlugin().getServer().getPluginManager().callEvent(event);
|
||||
|
||||
String text = ChatColor.GREEN + "" + ChatColor.BOLD + "1" + ChatColor.RESET + "" + ChatColor.GREEN + " - "
|
||||
String text = ChatColor.GREEN + "" + ChatColor.BOLD + "1" + ChatColor.RESET + " - " + ChatColor.GREEN
|
||||
+ Lang.get("yesWord") + "\n";
|
||||
text += ChatColor.RED + "" + ChatColor.BOLD + "2" + ChatColor.RESET + "" + ChatColor.RED + " - "
|
||||
text += ChatColor.RED + "" + ChatColor.BOLD + "2" + ChatColor.RESET + " - " + ChatColor.RED
|
||||
+ Lang.get("noWord");
|
||||
return ChatColor.RED + getQueryText(context) + " (" + ChatColor.YELLOW + Lang.get("stageEditorStage")
|
||||
+ " " + stageNum + ChatColor.RED + ")\n" + ChatColor.GOLD + "("
|
||||
|
Loading…
Reference in New Issue
Block a user