Fixed the Druidic Ritual quest log rendering
Implemented two bank noticeboards
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
package core.game.node.entity.player.link.quest;
|
||||
|
||||
import core.game.component.CloseEvent;
|
||||
import core.game.component.Component;
|
||||
import core.game.node.entity.player.Player;
|
||||
import core.plugin.Plugin;
|
||||
@@ -137,7 +138,10 @@ public abstract class Quest implements Plugin<Object> {
|
||||
player.getQuestRepository().setStage(this, 100);
|
||||
player.getQuestRepository().incrementPoints(getQuestPoints());
|
||||
player.getQuestRepository().syncronizeTab(player);
|
||||
player.getInterfaceManager().open(new Component(277));
|
||||
player.getInterfaceManager().open(new Component(277).setCloseEvent((p, c) -> {
|
||||
this.questCloseEvent(p, c);
|
||||
return true;
|
||||
}));
|
||||
player.getPacketDispatch().sendString("" + player.getQuestRepository().getPoints() + "", 277, 7);
|
||||
player.getPacketDispatch().sendString("You have completed the " + getName() + " Quest!", 277, 4);
|
||||
player.getPacketDispatch().sendMessage("Congratulations! Quest complete!");
|
||||
@@ -151,6 +155,12 @@ public abstract class Quest implements Plugin<Object> {
|
||||
*/
|
||||
public void reset(Player player) {}
|
||||
|
||||
/**
|
||||
* Function callback when closing the quest.
|
||||
* Override this to follow up on dialogue after the component closes.
|
||||
*/
|
||||
public void questCloseEvent(Player player, Component component) {}
|
||||
|
||||
/**
|
||||
* Draws a line on the journal component.
|
||||
* @param player The player.
|
||||
|
||||
Reference in New Issue
Block a user