示例#1
0
    public Character(CharacterTemplateSlot templateSlot, Team team,
                     CharacterActor actor, CharacterMover mover, CharacterFloatingTextHandler floatingTextHandler)
    {
        Template    = templateSlot.Template;
        actor.Owner = this;
        mover.Owner = this;
        floatingTextHandler.Owner = this;

        Team = team;

        Actor = actor;
        Mover = mover;
        FloatingTextHandler = floatingTextHandler;

        ActionPointHandler = new CharacterActionPointHandler(this);
        PositionHandler    = new CharacterPositionHandler(this, templateSlot.Position);
        AbilityHandler     = new CharacterAbilityHandler(this);
        EventHandler       = new CharacterEventHandler(this);
        StatusHandler      = new CharacterStatusHandler(this);
        HealthHandler      = new CharacterHealthHandler(this);
        AIHandler          = new CharacterAIHandler(this);

        RegisterAvailabilityListeners();
    }
示例#2
0
 void Start()
 {
     action = characterPanel.Actor.Owner.ActionPointHandler;
     action.ListenToPoints(UpdateInfo);
     UpdateInfo();
 }