
An extremely simple mod for FTBQuests that does exactly one thing: make it so when you select multiple quests in Editor Mode, you can right-click -> "Complete Instantly" to complete them all at once.
I made this in like half an hour cause my TFG quest progression got corrupted after updating. Great pack btw. 4/10 too much greg.
Only works on 1.20.1 cause I made this for personal use, and it probably won't be maintained for future versions. It works, though.
Logo: https://commons.wikimedia.org/wiki/File:Eo_circle_green_checkmark.svg licensed under Creative Commons Attribution-Share Alike 4.0 International
Anyway, I made this in my "screwing around" mod project that gets reused for everything, so there's no GitHub. Here's the source code though, minus the janky reflection I had to do since I wasn't on Architectury:
@Mixin(value = QuestButton.class, remap = false)
abstract class MCompleteMultiple {
@Final
@Shadow
protected QuestScreen questScreen;
@Redirect(
method="onClicked",
at=@At(
value="INVOKE",
target="java/util/List.add (Ljava/lang/Object;)Z",
ordinal = 5
)
)
private boolean inject(List original, Object it, @Local(name="selected") Collection<Quest> selected) {
original.add(it);
var file = ((QuestScreenAccessor)questScreen).getFile();
// copied directly from FTBQuests' single-item "Complete Instantly" button, with a "for all selected" inserted
return original.add(new ContextMenuItem(Component.translatable("ftbquests.gui.complete_instantly"), ThemeProperties.CHECK_ICON.get(), (b) -> selected.forEach((q) -> ChangeProgressMessage.sendToServer(file.selfTeamData, q, progressChange-> progressChange.setReset(false)).setYesNoText(Component.translatable("ftbquests.gui.complete_instantly_q")));
}
}