protected void Init(string host, ushort port, EInteractionType interactionType, EAuthenticationType authenticationType, int sendTimeOut, int receiveTimeOut)
 {
     if (host == null)
     {
         throw new ArgumentNullException("host");
     }
     if (sendTimeOut < 0)
     {
         throw new ArgumentOutOfRangeException("sendTimeOut");
     }
     if (receiveTimeOut < 0)
     {
         throw new ArgumentOutOfRangeException("receiveTimeOut");
     }
     this.Host = host;
     this.Port = port;
     this.SSLInteractionType  = interactionType;
     this.AuthenticationType  = authenticationType;
     this.SendTimeOut         = sendTimeOut;
     this.ReceiveTimeOut      = receiveTimeOut;
     this.ProxyHost           = "";
     this.ProxyPort           = 0;
     this.ProxyType           = EProxyType.No;
     this.AttachmentDirectory = ApplicationData.Current.LocalFolder.Path;
 }
    public void Activate(EInteractionType interactionType)
    {
        currentInteraction = interactionType;
        _cursor.SetActive(true);

        // Enable script
        this.enabled = true;
    }
    /**
     * Deactivate EnvironmentInteraction. This only happens if interactionType and
     * the state that the EnvironmentInteraction is currently in, are the same.
     */
    public void Deactivate(EInteractionType interactionType)
    {
        if (interactionType == currentInteraction)
        {
            currentInteraction = EInteractionType.EEI_NONE;
            _cursor.SetActive(false);

            // Disable script
            this.enabled = false;
        }
    }
示例#4
0
 public void RemoveFromInventory(PickableObject _object)
 {
     m_inventoryItems.Remove(_object);
     if (m_currentInventoryItem == _object)
     {
         EInteractionType tmp = m_CurrentInteractionType;
         m_CurrentInteractionType = EInteractionType.USE;
         UIManager.Get.SelectItem(-1);
         m_CurrentInteractionType = tmp;
     }
     InventoryRow = InventoryRow;
 }
示例#5
0
 private void Update()
 {
     if (Input.GetKeyDown(KeyCode.Q))
     {
         UIManager.Get.ToggleDisplayCurrentQuest(CurrentQuest);
     }
     if (Input.GetKeyDown(KeyCode.Mouse1))
     {
         EInteractionType type = m_CurrentInteractionType;
         m_CurrentInteractionType = EInteractionType.USE;
         UIManager.Get.SelectItem(-1);
         m_CurrentInteractionType = type;
     }
 }
 public CodeConfigurationProvider(string host, ushort port, EInteractionType interactionType, EAuthenticationType authenticationType)
 {
     this._proxyUser     = "";
     this._proxyPassword = "";
     this.Init(host, port, interactionType, authenticationType, 0x2710, 0x2710);
 }
示例#7
0
 public SmtpClient(string host, ushort port, string smtpUser, string smtpPassword, EInteractionType interactionType, EAuthenticationType authenticationType)
 {
     this.Init(host, port, smtpUser, smtpPassword, interactionType, authenticationType);
 }
示例#8
0
 public SmtpClient(string host, ushort port, EInteractionType interactionType, EAuthenticationType authenticationType)
 {
     this.Init(host, port, "", "", interactionType, authenticationType);
 }
示例#9
0
 protected void Init(string host, ushort port, string smtpUser, string smtpPassword, EInteractionType interactionType, EAuthenticationType authenticationType)
 {
     if (host == null)
     {
         throw new ArgumentNullException("host");
     }
     if (smtpUser == null)
     {
         throw new ArgumentNullException("smtpUser");
     }
     if (smtpPassword == null)
     {
         throw new ArgumentNullException("smtpPassword");
     }
     this._configurationProvider = new CodeConfigurationProvider(host, port, interactionType, authenticationType);
     this._connectionFactory     = new ConnectionFactory();
     this.Username  = smtpUser;
     this.Password  = smtpPassword;
     this.ProxyUser = "";
     this.State     = ESmtpClientState.Awaiting;
 }
示例#10
0
 private void OnWandClick(GameObject go)
 {
     Globals.Instance.EffectSoundMgr.Play("ui/ui_001");
     if (this.mSelectedPlayer == null)
     {
         return;
     }
     if (Globals.Instance.Player.CostumePartySystem.GetCD(EInteractionType.EInteraction_Wand) > Globals.Instance.Player.GetTimeStamp())
     {
         GameUIManager.mInstance.ShowMessageTipByKey("costumePartyWandInCD", 0f, 0f);
         return;
     }
     this.mCurInteractionType = EInteractionType.EInteraction_Wand;
     this.SendInteractionMsg(this.mCurInteractionType);
 }
示例#11
0
 private void OnTurtleClick(GameObject go)
 {
     Globals.Instance.EffectSoundMgr.Play("ui/ui_001");
     if (this.mSelectedPlayer == null)
     {
         return;
     }
     if (Globals.Instance.Player.CostumePartySystem.GetCD(EInteractionType.EInteraction_Turtle) > Globals.Instance.Player.GetTimeStamp())
     {
         GameUIManager.mInstance.ShowMessageTipByKey("costumePartyTurtleInCD", 0f, 0f);
         return;
     }
     if (!Tools.MoneyNotEnough(ECurrencyType.ECurrencyT_Diamond, this.danceInteractionCost, 0))
     {
         this.mCurInteractionType = EInteractionType.EInteraction_Turtle;
         this.SendInteractionMsg(this.mCurInteractionType);
     }
 }
示例#12
0
 public Pop3Client(string accountName, string host, ushort port, string login, string password, EInteractionType interactionType, EAuthenticationType authenticationType)
 {
     this.Init(accountName, host, port, login, password, interactionType, authenticationType);
 }
示例#13
0
 public Pop3Client(string accountName, string host, ushort port, EInteractionType interactionType, EAuthenticationType authenticationType)
 {
     this.Init(accountName, host, port, "", "", interactionType, authenticationType);
 }
示例#14
0
 protected virtual void Init(string accountName, string host, ushort port, string login, string password, EInteractionType interactionType, EAuthenticationType authenticationType)
 {
     if (string.IsNullOrEmpty(accountName))
     {
         throw new ArgumentNullException("accountName");
     }
     if (host == null)
     {
         throw new ArgumentNullException("host");
     }
     if (login == null)
     {
         throw new ArgumentNullException("login");
     }
     if (password == null)
     {
         throw new ArgumentNullException("password");
     }
     this._connectionFactory     = new ConnectionFactory();
     this._configurationProvider = new CodeConfigurationProvider(host, port, interactionType, authenticationType);
     this.AuthenticationType     = authenticationType;
     this.AccountName            = accountName;
     this.Username        = login;
     this.Password        = password;
     this.ConnectionState = EPop3ConnectionState.Disconnected;
     this.State           = EPop3ClientState.Awaiting;
 }
 public CodeConfigurationProvider(string host, ushort port, EInteractionType interactionType, EAuthenticationType authenticationType, int sendTimeOut, int recieveTimeOut)
 {
     this._proxyUser     = "";
     this._proxyPassword = "";
     this.Init(host, port, interactionType, authenticationType, sendTimeOut, recieveTimeOut);
 }
示例#16
0
 private void SendInteractionMsg(EInteractionType type)
 {
     MC2S_Interaction mC2S_Interaction = new MC2S_Interaction();
     mC2S_Interaction.Type = (int)type;
     mC2S_Interaction.PlayerID = this.mSelectedPlayer.mGuest.PlayerID;
     Globals.Instance.CliSession.Send(276, mC2S_Interaction);
 }
示例#17
0
 public int GetCD(EInteractionType type)
 {
     return this.CD[type - EInteractionType.EInteraction_Rose];
 }