feat(vfx): port retail hidden and teleport presentation
Preserve canonical live-object ownership across Hidden transitions and remote teleport placement so effects, collision, streaming, and targeting remain synchronized.
This commit is contained in:
parent
a51ebc66e9
commit
1e98d81448
46 changed files with 4883 additions and 127 deletions
38
tests/AcDream.App.Tests/Physics/RemoteTeleportHookTests.cs
Normal file
38
tests/AcDream.App.Tests/Physics/RemoteTeleportHookTests.cs
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
using AcDream.App.Physics;
|
||||
using AcDream.Core.Physics;
|
||||
|
||||
namespace AcDream.App.Tests.Physics;
|
||||
|
||||
public sealed class RemoteTeleportHookTests
|
||||
{
|
||||
[Fact]
|
||||
public void Execute_UsesRetailOrderAndExactCancelContext()
|
||||
{
|
||||
var calls = new List<string>();
|
||||
WeenieError cancelContext = WeenieError.None;
|
||||
|
||||
RemoteTeleportHook.Execute(new RemoteTeleportHookActions(
|
||||
CancelMoveTo: error =>
|
||||
{
|
||||
cancelContext = error;
|
||||
calls.Add("cancel");
|
||||
},
|
||||
UnStick: () => calls.Add("unstick"),
|
||||
StopInterpolating: () => calls.Add("stop-interpolating"),
|
||||
UnConstrain: () => calls.Add("unconstrain"),
|
||||
NotifyTeleported: () => calls.Add("notify-teleported"),
|
||||
ReportCollisionEnd: () => calls.Add("collision-end")));
|
||||
|
||||
Assert.Equal(0x3Cu, (uint)cancelContext);
|
||||
Assert.Equal(
|
||||
[
|
||||
"cancel",
|
||||
"unstick",
|
||||
"stop-interpolating",
|
||||
"unconstrain",
|
||||
"notify-teleported",
|
||||
"collision-end",
|
||||
],
|
||||
calls);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue