Content update for NetEntities (#18935)

This commit is contained in:
metalgearsloth
2023-09-11 09:42:41 +10:00
committed by GitHub
parent 389c8d1a2c
commit 5a0fc68be2
526 changed files with 3058 additions and 2215 deletions

View File

@@ -32,7 +32,7 @@ public sealed class AdminFaxEui : BaseEui
var entries = new List<AdminFaxEntry>();
while (faxes.MoveNext(out var uid, out var fax, out var device))
{
entries.Add(new AdminFaxEntry(uid, fax.FaxName, device.Address));
entries.Add(new AdminFaxEntry(_entityManager.GetNetEntity(uid), fax.FaxName, device.Address));
}
return new AdminFaxEuiState(entries);
}
@@ -49,14 +49,14 @@ public sealed class AdminFaxEui : BaseEui
!_entityManager.HasComponent<GhostComponent>(Player.AttachedEntity.Value))
return;
_followerSystem.StartFollowingEntity(Player.AttachedEntity.Value, followData.TargetFax);
_followerSystem.StartFollowingEntity(Player.AttachedEntity.Value, _entityManager.GetEntity(followData.TargetFax));
break;
}
case AdminFaxEuiMsg.Send sendData:
{
var printout = new FaxPrintout(sendData.Content, sendData.Title, null, sendData.StampState,
new() { new StampDisplayInfo { StampedName = sendData.From, StampedColor = sendData.StampColor } });
_faxSystem.Receive(sendData.Target, printout);
_faxSystem.Receive(_entityManager.GetEntity(sendData.Target), printout);
break;
}
}