mirror of
https://github.com/xivdev/Penumbra.git
synced 2026-01-02 05:43:42 +01:00
tmp
This commit is contained in:
parent
f5fccb0235
commit
46581780e0
37 changed files with 2343 additions and 2444 deletions
|
|
@ -1,5 +1,6 @@
|
|||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using Penumbra.GameData.Enums;
|
||||
|
||||
namespace Penumbra.Interop.Structs;
|
||||
|
||||
|
|
@ -14,10 +15,11 @@ public unsafe struct CharacterUtility
|
|||
public const int HairEstIdx = 65;
|
||||
public const int BodyEstIdx = 66;
|
||||
public const int HeadEstIdx = 67;
|
||||
public const int NumEqdpFiles = 2 * 28;
|
||||
|
||||
public static int EqdpIdx( ushort raceCode, bool accessory )
|
||||
public static int EqdpIdx( GenderRace raceCode, bool accessory )
|
||||
=> ( accessory ? 28 : 0 )
|
||||
+ raceCode switch
|
||||
+ ( int )raceCode switch
|
||||
{
|
||||
0101 => 2,
|
||||
0201 => 3,
|
||||
|
|
@ -65,7 +67,7 @@ public unsafe struct CharacterUtility
|
|||
public ResourceHandle* Resource( int idx )
|
||||
=> ( ResourceHandle* )Resources[ idx ];
|
||||
|
||||
public ResourceHandle* EqdpResource( ushort raceCode, bool accessory )
|
||||
public ResourceHandle* EqdpResource( GenderRace raceCode, bool accessory )
|
||||
=> Resource( EqdpIdx( raceCode, accessory ) );
|
||||
|
||||
[FieldOffset( 8 + HumanCmpIdx * 8 )]
|
||||
|
|
|
|||
|
|
@ -9,6 +9,9 @@ public unsafe struct ResourceHandle
|
|||
[StructLayout( LayoutKind.Explicit )]
|
||||
public struct DataIndirection
|
||||
{
|
||||
[FieldOffset( 0x00 )]
|
||||
public void** VTable;
|
||||
|
||||
[FieldOffset( 0x10 )]
|
||||
public byte* DataPtr;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue