Client rework for API change and paradigm shift (#39)
* most of the groups refactoring on client * register OnMethods for group stuff * start implementing client (still pretty broken) * finish implementing new api first iteration * idk rework everything for pair shit (still WIP); goal is to remove PairedClients and GroupPairClients from ApiController * move everything to PairManager, remove dictionaries from APiController * remove admin stuff from client, cleanup * adjust reconnection handling, add new settings, todo still to remove access from old stuff that's marked obsolete from config * add back adding servers, fix intro ui * fix obsolete calls * adjust config namespace * add UI for setting animation/sound permissions to syncshells * add ConfigurationService to hot reload config on change from external * move transient data cache to configuration * add deleting service to ui * fix saving of transient resources * fix group pair user assignments * halt scanner when penumbra inactive, add visible/online/offline split to individual pairs and tags * add presence to syncshell ui * move fullpause from config to server config * fixes in code style * more codestyle * show info icon on player in shells, don't show icon when no changes from default state are made, add online notifs * fixes to intro UI --------- Co-authored-by: rootdarkarchon <root.darkarchon@outlook.com>
This commit is contained in:
11
MareSynchronos/Interop/CharaExt.cs
Normal file
11
MareSynchronos/Interop/CharaExt.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
using System.Runtime.InteropServices;
|
||||
using FFXIVClientStructs.FFXIV.Client.Game.Character;
|
||||
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct CharaExt
|
||||
{
|
||||
[FieldOffset(0x0)] public Character Character;
|
||||
[FieldOffset(0x650)] public Character* Mount;
|
||||
}
|
||||
12
MareSynchronos/Interop/HumanExt.cs
Normal file
12
MareSynchronos/Interop/HumanExt.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
using System.Runtime.InteropServices;
|
||||
using FFXIVClientStructs.FFXIV.Client.Graphics.Scene;
|
||||
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct HumanExt
|
||||
{
|
||||
[FieldOffset(0x0)] public Human Human;
|
||||
[FieldOffset(0x9E8)] public ResourceHandle* Decal;
|
||||
[FieldOffset(0x9F0)] public ResourceHandle* LegacyBodyDecal;
|
||||
}
|
||||
@@ -1,18 +1,10 @@
|
||||
using System.Runtime.InteropServices;
|
||||
using FFXIVClientStructs.FFXIV.Client.Graphics.Render;
|
||||
|
||||
namespace Penumbra.Interop.Structs;
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout( LayoutKind.Explicit )]
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct Material
|
||||
{
|
||||
[FieldOffset( 0x10 )]
|
||||
[FieldOffset(0x10)]
|
||||
public ResourceHandle* ResourceHandle;
|
||||
}
|
||||
|
||||
[StructLayout( LayoutKind.Explicit )]
|
||||
public unsafe struct MaterialData
|
||||
{
|
||||
[FieldOffset( 0x0 )]
|
||||
public byte* Data;
|
||||
}
|
||||
10
MareSynchronos/Interop/MaterialData.cs
Normal file
10
MareSynchronos/Interop/MaterialData.cs
Normal file
@@ -0,0 +1,10 @@
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct MaterialData
|
||||
{
|
||||
[FieldOffset(0x0)]
|
||||
public byte* Data;
|
||||
}
|
||||
@@ -1,29 +1,28 @@
|
||||
using FFXIVClientStructs.FFXIV.Client.System.Resource.Handle;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Penumbra.Interop.Structs;
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout( LayoutKind.Explicit )]
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct MtrlResource
|
||||
{
|
||||
[FieldOffset( 0x00 )]
|
||||
[FieldOffset(0x00)]
|
||||
public ResourceHandle Handle;
|
||||
|
||||
[FieldOffset( 0xD0 )]
|
||||
[FieldOffset(0xD0)]
|
||||
public ushort* TexSpace; // Contains the offsets for the tex files inside the string list.
|
||||
|
||||
[FieldOffset( 0xE0 )]
|
||||
[FieldOffset(0xE0)]
|
||||
public byte* StringList;
|
||||
|
||||
[FieldOffset( 0xF8 )]
|
||||
[FieldOffset(0xF8)]
|
||||
public ushort ShpkOffset;
|
||||
|
||||
[FieldOffset( 0xFA )]
|
||||
[FieldOffset(0xFA)]
|
||||
public byte NumTex;
|
||||
|
||||
public byte* ShpkString
|
||||
=> StringList + ShpkOffset;
|
||||
|
||||
public byte* TexString( int idx )
|
||||
=> StringList + *( TexSpace + 4 + idx * 8 );
|
||||
public byte* TexString(int idx)
|
||||
=> StringList + *(TexSpace + 4 + idx * 8);
|
||||
}
|
||||
@@ -1,42 +1,41 @@
|
||||
using System.Runtime.InteropServices;
|
||||
using FFXIVClientStructs.FFXIV.Client.Graphics.Render;
|
||||
using FFXIVClientStructs.FFXIV.Client.System.Resource.Handle;
|
||||
|
||||
namespace Penumbra.Interop.Structs;
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout( LayoutKind.Explicit )]
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct RenderModel
|
||||
{
|
||||
[FieldOffset( 0x18 )]
|
||||
[FieldOffset(0x18)]
|
||||
public RenderModel* PreviousModel;
|
||||
|
||||
[FieldOffset( 0x20 )]
|
||||
[FieldOffset(0x20)]
|
||||
public RenderModel* NextModel;
|
||||
|
||||
[FieldOffset( 0x30 )]
|
||||
[FieldOffset(0x30)]
|
||||
public ResourceHandle* ResourceHandle;
|
||||
|
||||
[FieldOffset( 0x40 )]
|
||||
[FieldOffset(0x40)]
|
||||
public Skeleton* Skeleton;
|
||||
|
||||
[FieldOffset( 0x58 )]
|
||||
[FieldOffset(0x58)]
|
||||
public void** BoneList;
|
||||
|
||||
[FieldOffset( 0x60 )]
|
||||
[FieldOffset(0x60)]
|
||||
public int BoneListCount;
|
||||
|
||||
[FieldOffset( 0x70 )]
|
||||
[FieldOffset(0x70)]
|
||||
private void* UnkDXBuffer1;
|
||||
|
||||
[FieldOffset( 0x78 )]
|
||||
[FieldOffset(0x78)]
|
||||
private void* UnkDXBuffer2;
|
||||
|
||||
[FieldOffset( 0x80 )]
|
||||
[FieldOffset(0x80)]
|
||||
private void* UnkDXBuffer3;
|
||||
|
||||
[FieldOffset( 0x98 )]
|
||||
[FieldOffset(0x98)]
|
||||
public void** Materials;
|
||||
|
||||
[FieldOffset( 0xA0 )]
|
||||
[FieldOffset(0xA0)]
|
||||
public int MaterialCount;
|
||||
}
|
||||
@@ -1,33 +1,32 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using FFXIVClientStructs.FFXIV.Client.System.Resource;
|
||||
|
||||
namespace Penumbra.Interop.Structs;
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout( LayoutKind.Explicit )]
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct ResourceHandle
|
||||
{
|
||||
public const int SsoSize = 15;
|
||||
|
||||
public byte* FileName()
|
||||
{
|
||||
if( FileNameLength > SsoSize )
|
||||
if (FileNameLength > SsoSize)
|
||||
{
|
||||
return FileNameData;
|
||||
}
|
||||
|
||||
fixed( byte** name = &FileNameData )
|
||||
fixed (byte** name = &FileNameData)
|
||||
{
|
||||
return ( byte* )name;
|
||||
return (byte*)name;
|
||||
}
|
||||
}
|
||||
|
||||
[FieldOffset( 0x08 )]
|
||||
[FieldOffset(0x08)]
|
||||
public ResourceCategory Category;
|
||||
|
||||
[FieldOffset( 0x48 )]
|
||||
[FieldOffset(0x48)]
|
||||
public byte* FileNameData;
|
||||
|
||||
[FieldOffset( 0x58 )]
|
||||
[FieldOffset(0x58)]
|
||||
public int FileNameLength;
|
||||
}
|
||||
@@ -1,9 +1,4 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using FFXIVClientStructs.FFXIV.Client.Game.Character;
|
||||
using FFXIVClientStructs.FFXIV.Client.Graphics.Scene;
|
||||
using FFXIVClientStructs.FFXIV.Client.System.Resource.Handle;
|
||||
using Penumbra.Interop.Structs;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
@@ -15,24 +10,3 @@ public unsafe struct Weapon
|
||||
[FieldOffset(0x28)] public IntPtr PreviousSibling;
|
||||
[FieldOffset(0xA8)] public WeaponDrawObject* WeaponRenderModel;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct WeaponDrawObject
|
||||
{
|
||||
[FieldOffset(0x00)] public RenderModel* RenderModel;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct HumanExt
|
||||
{
|
||||
[FieldOffset(0x0)] public Human Human;
|
||||
[FieldOffset(0x9E8)] public Penumbra.Interop.Structs.ResourceHandle* Decal;
|
||||
[FieldOffset(0x9F0)] public Penumbra.Interop.Structs.ResourceHandle* LegacyBodyDecal;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct CharaExt
|
||||
{
|
||||
[FieldOffset(0x0)] public Character Character;
|
||||
[FieldOffset(0x650)] public Character* Mount;
|
||||
}
|
||||
|
||||
9
MareSynchronos/Interop/WeaponDrawObject.cs
Normal file
9
MareSynchronos/Interop/WeaponDrawObject.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace MareSynchronos.Interop;
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
public unsafe struct WeaponDrawObject
|
||||
{
|
||||
[FieldOffset(0x00)] public RenderModel* RenderModel;
|
||||
}
|
||||
Reference in New Issue
Block a user