Quest System

This commit is contained in:
FatBoy committed 2025-01-18 20:08:47 -06:00
1 parent 9ec95b974f
commit da42e2baf4
5 files changed
+183 -11

No files matched your search

+15 -10
View File
@@ -11,6 +11,7 @@ package engine.net.client.msg;
import engine.Enum.DispatchChannel;
import engine.Enum.GuildHistoryType;
import engine.QuestSystem.QuestManager;
import engine.exception.MsgSendException;
import engine.gameManager.BuildingManager;
import engine.gameManager.DbManager;
@@ -125,18 +126,22 @@ public class VendorDialogMsg extends ClientNetMsg {
vd = Contract.HandleBaneCommanderOptions(msg.unknown03, npc, playerCharacter);
msg.updateMessage(3, vd);
}else {
if (contract == null)
vd = VendorDialog.getHostileVendorDialog();
else if (npc.getBuilding() != null) {
if (npc.getBuilding() != null && BuildingManager.IsPlayerHostile(npc.getBuilding(), playerCharacter))
if(QuestManager.grantsQuest(npc)){
vd = Contract.HandleQuestOptions(msg.unknown03, npc, playerCharacter);
msg.updateMessage(3, vd);
}else {
if (contract == null)
vd = VendorDialog.getHostileVendorDialog();
else
else if (npc.getBuilding() != null) {
if (npc.getBuilding() != null && BuildingManager.IsPlayerHostile(npc.getBuilding(), playerCharacter))
vd = VendorDialog.getHostileVendorDialog();
else
vd = contract.getVendorDialog();
} else
vd = contract.getVendorDialog();
} else
vd = contract.getVendorDialog();
if (vd == null)
vd = VendorDialog.getHostileVendorDialog();
if (vd == null)
vd = VendorDialog.getHostileVendorDialog();
}
if (msg.messageType == 1 || msg.unknown03 == vd.getObjectUUID()) {
msg.updateMessage(3, vd);
} else {