IArchetypeController - jimdroberts/FishMMO GitHub Wiki
Interface for a character's archetype controller, providing access to the current archetype template. Defines the contract for exposing a character's archetype in the FishMMO system.
-
ArchetypeTemplate Template { get; }
The archetype template currently assigned to this character.
- Implement the IArchetypeController interface in your character controller class.
- Ensure the Template property returns the correct archetype for the character.
// Example 1: Implementing IArchetypeController
public class MyArchetypeController : IArchetypeController {
public ArchetypeTemplate Template { get; private set; }
// ...implementation...
}
// Example 2: Accessing the archetype template
var template = archetypeController.Template;
- Always implement the Template property to accurately reflect the character's current archetype.
- Use the interface to decouple archetype logic from other character systems.
- Extend the interface as needed for additional archetype-related functionality.