Added callbacks to help with quest management. Abandoning a quest now works.

This commit is contained in:
Filip Maj
2017-04-04 01:10:26 -04:00
parent 9d63be52e3
commit 7fa4a1eb80
4 changed files with 78 additions and 2 deletions

View File

@@ -894,6 +894,17 @@ namespace FFXIVClassic_Map_Server.Actors
}
public int GetHighestLevel()
{
int max = 0;
foreach (short level in charaWork.battleSave.skillLevel)
{
if (level > max)
max = level;
}
return max;
}
public InventoryItem[] GetGearset(ushort classId)
{
return Database.GetEquipment(this, classId);
@@ -1113,6 +1124,14 @@ namespace FFXIVClassic_Map_Server.Actors
}
}
//TODO: Add checks for you being in an instance or main scenario
public void AbandonQuest(uint id)
{
Quest quest = GetQuest(id);
RemoveQuestByQuestId(id);
quest.DoAbandon();
}
public void RemoveQuestByQuestId(uint id)
{
RemoveQuest((0xA0F00000 | id));