Init(args)
Scripting Reference
Loading...
Searching...
No Matches

◆ ForEquals< TService >()

static bool Sisus.Init.Service.ForEquals< TService > ( [DisallowNull] GameObject client,
TService @ object )
static

Determines whether the given object is a service accessible by the client .

Services are components that have the ServiceTag attached to them, have been defined as a service in a Services component, have the ServiceAttribute on their class, or have been manually registered as a service in code.

This method can only be called from the main thread.

Template Parameters
TServiceThe defining type of the service.
Parameters
clientThe client that has to be able to access the service.
objectThe object to test.
Returns
true if the object is a service accessible by the client ; otherwise, false.