A class in Root.Township, the global namespace.
Fires a player event on the server when a given achievement is completed by a player.
Constructors
| Member | What it is |
|---|
ServerAchievementEvent() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
2 private and internal fields
| Member | What it is |
|---|
private PlayerEvent onComplete | Event invoked with the player who completed it. |
private GameAchievement targetAchievement | The achievement to watch. |
Methods
3 private and internal methods
| Member | What it is |
|---|
private void CompletedAchievement(IPlayer player, GameAchievement achievement) | Server: invokes onComplete with the player. |
private void OnDestroy() | Unhooks from the achievement. |
private void Start() | Hooks the achievement's CompletedByPlayer event. |