[IDEA] Add a predicate for admin toys that determines which clients should receive it.
Goal Description
It would be nice if we could set a predicate on admin toys to determine which clients should receive it.
It should be able to pass it into AdminToy.Create<T>(), so that it gets checked before even spawning the toy.
This would potentially require SL to write a custom interest management component if it doesn't have one (which seems to be the case). Otherwise maybe manually send spawn messages to select clients instead.
Notes
- A simple
Func<Player, bool>would work pretty well in my opinion. - Should default to
null.
Example
var toy = AdminToy.Create<SpeakerToy>(position, rotation, scale, parent, (ply) =>
{
return ply.Team == Team.SCPs;
});
I think it would be nice to add predicate to all methods like Door.Get/Player.Get and etc too. Maybe there are more this kind of methods.
Could you add this to your IDEA pls :)
Thank you for your suggestion! We've logged this issue in our internal git system for further review and tracking. Please note that this doesn't guarantee acceptance or implementation at this stage. If we need any additional information or clarification, we'll be sure to reach out to you.
We've reopened this suggestion to prevent confusion and duplicate posts. As stated before, the issue has been added to our internal tracker, but that does not guarantee acceptance nor implementation.