Stores the list of replicated actors for a given UNetDriver. 更多...
#include <NetworkObjectList.h>
Public 成员函数 | |
| void | AddInitialObjects (UWorld *const World, const FName NetDriverName) |
| Adds replicated actors in World to the internal set of replicated actors. 更多... | |
| void | AddInitialObjects (UWorld *const World, UNetDriver *NetDriver) |
| Adds replicated actors in World to the internal set of replicated actors. 更多... | |
| void | ClearRecentlyDormantConnection (AActor *const Actor, UNetConnection *const Connection, const FName NetDriverName) |
| Removes the recently dormant status from the passed in connection | |
| void | ClearRecentlyDormantConnection (AActor *const Actor, UNetConnection *const Connection, UNetDriver *NetDriver) |
| Removes the recently dormant status from the passed in connection | |
| TSharedPtr< FNetworkObjectInfo > | Find (AActor *const Actor) |
| Attempts to find the Actor's FNetworkObjectInfo. 更多... | |
| TSharedPtr< FNetworkObjectInfo > * | FindOrAdd (AActor *const Actor, const FName NetDriverName, bool *OutWasAdded=nullptr) |
| Attempts to find the Actor's FNetworkObjectInfo. 更多... | |
| TSharedPtr< FNetworkObjectInfo > * | FindOrAdd (AActor *const Actor, UNetDriver *NetDriver, bool *OutWasAdded=nullptr) |
| Attempts to find the Actor's FNetworkObjectInfo. 更多... | |
| void | ForceActorRelevantNextUpdate (AActor *const Actor, const FName NetDriverName) |
| Force this actor to be relevant for at least one update | |
| void | ForceActorRelevantNextUpdate (AActor *const Actor, UNetDriver *NetDriver) |
| Force this actor to be relevant for at least one update | |
| const FNetworkObjectSet & | GetActiveObjects () const |
| Returns a const reference to the active set of tracked actors. | |
| const FNetworkObjectSet & | GetAllObjects () const |
| Returns a const reference to the entire set of tracked actors. | |
| const FNetworkObjectSet & | GetDormantObjectsOnAllConnections () const |
| Returns a const reference to the entire set of dormant actors. | |
| void | HandleConnectionAdded () |
| Does the necessary house keeping when a new connection is added When a new connection is added, we must add all objects back to the active list so the new connection will process it Once the objects is dormant on that connection, it will then be removed from the active list again | |
| bool | MarkActive (AActor *const Actor, UNetConnection *const Connection, const FName NetDriverName) |
| Marks this object as active for the passed in connection | |
| bool | MarkActive (AActor *const Actor, UNetConnection *const Connection, UNetDriver *NetDriver) |
| Marks this object as active for the passed in connection | |
| void | MarkDormant (AActor *const Actor, UNetConnection *const Connection, const int32 NumConnections, const FName NetDriverName) |
| Marks this object as dormant for the passed in connection | |
| void | MarkDormant (AActor *const Actor, UNetConnection *const Connection, const int32 NumConnections, UNetDriver *NetDriver) |
| Marks this object as dormant for the passed in connection | |
| void | Remove (AActor *const Actor) |
| Removes actor from the internal list, and any cleanup that is necessary (i.e. 更多... | |
| void | ResetDormancyState () |
| Clears all state related to dormancy | |
Stores the list of replicated actors for a given UNetDriver.
Adds replicated actors in World to the internal set of replicated actors.
Used when a net driver is initialized after some actors may have already been added to the world.
| World | The world from which actors are added. |
| NetDriverName | The name of the net driver to which this object list belongs. |
| void FNetworkObjectList::AddInitialObjects | ( | UWorld *const | World, |
| UNetDriver * | NetDriver | ||
| ) |
Adds replicated actors in World to the internal set of replicated actors.
Used when a net driver is initialized after some actors may have already been added to the world.
| World | The world from which actors are added. |
| NetDriver | The net driver to which this object list belongs. |
| TSharedPtr< FNetworkObjectInfo > FNetworkObjectList::Find | ( | AActor *const | Actor | ) |
Attempts to find the Actor's FNetworkObjectInfo.
If info is not found (or the Actor is in an invalid state) an invalid TSharedPtr is returned.
| TSharedPtr< FNetworkObjectInfo > * FNetworkObjectList::FindOrAdd | ( | AActor *const | Actor, |
| const FName | NetDriverName, | ||
| bool * | OutWasAdded = nullptr |
||
| ) |
Attempts to find the Actor's FNetworkObjectInfo.
If no info is found, then the Actor will be added to the list, and will assumed to be active.
If the Actor is dormant when this is called, it is the responsibility of the caller to call MarkDormant immediately.
If info cannot be found or created, nullptr will be returned.
| TSharedPtr< FNetworkObjectInfo > * FNetworkObjectList::FindOrAdd | ( | AActor *const | Actor, |
| UNetDriver * | NetDriver, | ||
| bool * | OutWasAdded = nullptr |
||
| ) |
Attempts to find the Actor's FNetworkObjectInfo.
If no info is found, then the Actor will be added to the list, and will assumed to be active.
If the Actor is dormant when this is called, it is the responsibility of the caller to call MarkDormant immediately.
If info cannot be found or created, nullptr will be returned.
| void FNetworkObjectList::Remove | ( | AActor *const | Actor | ) |
Removes actor from the internal list, and any cleanup that is necessary (i.e.
resetting dormancy state)