Содержание
This documentation is outdated.
The Observer system is a replication of UNET HLAPI's Observer system. It allows for large world objects to be cheaply synchronized. The observer system allows you to set "observers" on a per object basis. This means that you can highly optimize your code to only send messages to observers.
Each Send overload has an optional boolean called respectObservers
, it defaults to false. If it's set to true, the message will only be sent if the client(s) it's being sent to is an observer of the sender NetworkedObject. This can greatly optimize your game as long as you properly update the observer lists.
The MLAPI has a prototype component called NetworkedProximity which is a port of the HLAPI's NetworkedProximityChecker. It uses distance checking and is a great example and starting point for the topic.
Getting Started
The Basics
- Message System
- Object Spawning
- Object & Behaviour Relation
- Modularity
- NetworkedVar
- Scene Management
- Object Ownership
Components
Advanced Topics
- Encryption
- Networked Object Pooling
- Lag Compensation
- BitWriter & BitReader
- Custom Transports
- Optimization
- Network Profiler Window
- Dedicated Servers