Пример #1
0
    public Chat(IMessagesBox messageBox, ChatIcon icon, ChatAudio audio, string name)
    {
        m_history   = DataManager.LoadHistory(name);
        m_chatState = m_history.GetState();

        m_name    = name;
        m_replics = new ReplicaController(m_name);

        m_messageBox = messageBox;
        m_messageBox.LoadFromHistory(m_history);
        m_messageBox.AddPlayerTurnEvent(SetState);

        m_icon = icon;
        m_icon.onClickEvent += Activate;
        m_icon.InitChat(m_name);
        m_icon.SetVisible(true);

        m_audio = audio;

        InitUsers();
    }
Пример #2
0
 public Player(IMessagesBox messageBox, string name)
     : base(messageBox, name)
 {
     messageBox.AddPlayerTurnEvent(SetPlayerTurn);
     m_isImitate = true;
 }