mirror of
https://github.com/goatcorp/Dalamud.git
synced 2026-02-25 14:11:48 +01:00
Reorder, bail out early in Recipe and McGuffin
This commit is contained in:
parent
4c5b5a604a
commit
98ef505b38
1 changed files with 15 additions and 9 deletions
|
|
@ -310,12 +310,6 @@ internal unsafe class UnlockState : IInternalDisposableService, IUnlockState
|
||||||
return nativeRow != null && UIState.Instance()->IsItemActionUnlocked(nativeRow) == 1;
|
return nativeRow != null && UIState.Instance()->IsItemActionUnlocked(nativeRow) == 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <inheritdoc/>
|
|
||||||
public bool IsMcGuffinUnlocked(McGuffin row)
|
|
||||||
{
|
|
||||||
return PlayerState.Instance()->IsMcGuffinUnlocked(row.RowId);
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool IsMJILandmarkUnlocked(MJILandmark row)
|
public bool IsMJILandmarkUnlocked(MJILandmark row)
|
||||||
{
|
{
|
||||||
|
|
@ -328,6 +322,15 @@ internal unsafe class UnlockState : IInternalDisposableService, IUnlockState
|
||||||
return this.IsUnlockLinkUnlocked(row.UnlockLink);
|
return this.IsUnlockLinkUnlocked(row.UnlockLink);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <inheritdoc/>
|
||||||
|
public bool IsMcGuffinUnlocked(McGuffin row)
|
||||||
|
{
|
||||||
|
if (!this.IsLoaded)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
return PlayerState.Instance()->IsMcGuffinUnlocked(row.RowId);
|
||||||
|
}
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool IsMountUnlocked(Mount row)
|
public bool IsMountUnlocked(Mount row)
|
||||||
{
|
{
|
||||||
|
|
@ -388,6 +391,9 @@ internal unsafe class UnlockState : IInternalDisposableService, IUnlockState
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool IsRecipeUnlocked(Recipe row)
|
public bool IsRecipeUnlocked(Recipe row)
|
||||||
{
|
{
|
||||||
|
if (!this.IsLoaded)
|
||||||
|
return false;
|
||||||
|
|
||||||
return this.recipeData.IsRecipeUnlocked(row);
|
return this.recipeData.IsRecipeUnlocked(row);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -808,15 +814,15 @@ internal class UnlockStatePluginScoped : IInternalDisposableService, IUnlockStat
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool IsItemUnlocked(Item row) => this.unlockStateService.IsItemUnlocked(row);
|
public bool IsItemUnlocked(Item row) => this.unlockStateService.IsItemUnlocked(row);
|
||||||
|
|
||||||
/// <inheritdoc/>
|
|
||||||
public bool IsMcGuffinUnlocked(McGuffin row) => this.unlockStateService.IsMcGuffinUnlocked(row);
|
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool IsMJILandmarkUnlocked(MJILandmark row) => this.unlockStateService.IsMJILandmarkUnlocked(row);
|
public bool IsMJILandmarkUnlocked(MJILandmark row) => this.unlockStateService.IsMJILandmarkUnlocked(row);
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool IsMKDLoreUnlocked(MKDLore row) => this.unlockStateService.IsMKDLoreUnlocked(row);
|
public bool IsMKDLoreUnlocked(MKDLore row) => this.unlockStateService.IsMKDLoreUnlocked(row);
|
||||||
|
|
||||||
|
/// <inheritdoc/>
|
||||||
|
public bool IsMcGuffinUnlocked(McGuffin row) => this.unlockStateService.IsMcGuffinUnlocked(row);
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool IsMountUnlocked(Mount row) => this.unlockStateService.IsMountUnlocked(row);
|
public bool IsMountUnlocked(Mount row) => this.unlockStateService.IsMountUnlocked(row);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue