1
0
mirror of https://github.com/oliverbooth/VpSharp synced 2024-11-09 22:55:42 +00:00

fix: delay vp_state_change until CurrentAvatar is updated

This commit is contained in:
Oliver Booth 2024-01-06 12:24:30 +00:00
parent cc2b7a8964
commit 25416ae6c1
Signed by: oliverbooth
GPG Key ID: E60B570D1B7557B5

View File

@ -390,11 +390,6 @@ public sealed partial class VirtualParadiseClient : IDisposable
CurrentAvatar.Location = new Location(world); CurrentAvatar.Location = new Location(world);
} }
lock (Lock)
{
_ = vp_state_change(NativeInstanceHandle);
}
world.Size = new Size(size, size); world.Size = new Size(size, size);
CurrentAvatar = new VirtualParadiseAvatar(this, -1) CurrentAvatar = new VirtualParadiseAvatar(this, -1)
@ -411,6 +406,11 @@ public sealed partial class VirtualParadiseClient : IDisposable
_worldSettings.Clear(); _worldSettings.Clear();
} }
lock (Lock)
{
_ = vp_state_change(NativeInstanceHandle);
}
if (_configuration.AutoQuery) if (_configuration.AutoQuery)
{ {
_ = Task.Run(async () => _ = Task.Run(async () =>