mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-15 05:04:15 +01:00
Merge branch 'master' of https://github.com/goatcorp/Dalamud
This commit is contained in:
commit
9d7d3b3885
4 changed files with 62 additions and 7 deletions
|
|
@ -51,7 +51,7 @@ namespace Dalamud.Game.ClientState.Fates
|
||||||
if (Struct->Fates.First == null || Struct->Fates.Last == null)
|
if (Struct->Fates.First == null || Struct->Fates.Last == null)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
return (int)Struct->Fates.Capacity();
|
return (int)Struct->Fates.Size();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -99,7 +99,7 @@ namespace Dalamud.Game.ClientState.Fates
|
||||||
if (fateTable == IntPtr.Zero)
|
if (fateTable == IntPtr.Zero)
|
||||||
return IntPtr.Zero;
|
return IntPtr.Zero;
|
||||||
|
|
||||||
return *(IntPtr*)this.Struct->Fates.Get((ulong)index).Value;
|
return (IntPtr)this.Struct->Fates.Get((ulong)index).Value;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
||||||
|
|
@ -13,16 +13,16 @@ namespace Dalamud.Game.ClientState.JobGauge.Enums
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Mage's Ballad type.
|
/// Mage's Ballad type.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
MAGE = 5,
|
MAGE = 1,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Army's Paeon type.
|
/// Army's Paeon type.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
ARMY = 10,
|
ARMY = 2,
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The Wanderer's Minuet type.
|
/// The Wanderer's Minuet type.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
WANDERER = 15,
|
WANDERER = 3,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
using System;
|
using System;
|
||||||
|
|
||||||
using Dalamud.Game.ClientState.JobGauge.Enums;
|
using Dalamud.Game.ClientState.JobGauge.Enums;
|
||||||
|
using FFXIVClientStructs.FFXIV.Client.Game.Gauge;
|
||||||
|
|
||||||
namespace Dalamud.Game.ClientState.JobGauge.Types
|
namespace Dalamud.Game.ClientState.JobGauge.Types
|
||||||
{
|
{
|
||||||
|
|
@ -36,6 +37,60 @@ namespace Dalamud.Game.ClientState.JobGauge.Types
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets the type of song that is active.
|
/// Gets the type of song that is active.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public Song Song => (Song)this.Struct->Song;
|
public Song Song
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (this.Struct->SongFlags.HasFlag(SongFlags.WanderersMinuet))
|
||||||
|
return Song.WANDERER;
|
||||||
|
|
||||||
|
if (this.Struct->SongFlags.HasFlag(SongFlags.ArmysPaeon))
|
||||||
|
return Song.ARMY;
|
||||||
|
|
||||||
|
if (this.Struct->SongFlags.HasFlag(SongFlags.MagesBallad))
|
||||||
|
return Song.MAGE;
|
||||||
|
|
||||||
|
return Song.NONE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets the type of song that was last played.
|
||||||
|
/// </summary>
|
||||||
|
public Song LastSong
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (this.Struct->SongFlags.HasFlag(SongFlags.WanderersMinuetLastPlayed))
|
||||||
|
return Song.WANDERER;
|
||||||
|
|
||||||
|
if (this.Struct->SongFlags.HasFlag(SongFlags.ArmysPaeonLastPlayed))
|
||||||
|
return Song.ARMY;
|
||||||
|
|
||||||
|
if (this.Struct->SongFlags.HasFlag(SongFlags.MagesBalladLastPlayed))
|
||||||
|
return Song.MAGE;
|
||||||
|
|
||||||
|
return Song.NONE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets the song Coda that are currently active.
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// This will always return an array of size 3, inactive Coda are represented by <see cref="Song.NONE"/>.
|
||||||
|
/// </remarks>
|
||||||
|
public Song[] Coda
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return new[]
|
||||||
|
{
|
||||||
|
this.Struct->SongFlags.HasFlag(SongFlags.MagesBalladCoda) ? Song.MAGE : Song.NONE,
|
||||||
|
this.Struct->SongFlags.HasFlag(SongFlags.ArmysPaeonCoda) ? Song.ARMY : Song.NONE,
|
||||||
|
this.Struct->SongFlags.HasFlag(SongFlags.WanderersMinuetCoda) ? Song.WANDERER : Song.NONE,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
Subproject commit f1c535062c315b055b05c35f9f4b25fd960712ee
|
Subproject commit 64848695224c25f5f459c42100a5ab75bf611d3f
|
||||||
Loading…
Add table
Add a link
Reference in a new issue