Ejemplo n.º 1
0
 /// <summary>
 /// Fires the BotJoin event.
 /// </summary>
 /// <param name="sid">The server on which the bot has joined a channel.</param>
 /// <param name="channel">The channel which the bot has joined.</param>
 /// <returns>The raw data to be sent to the server.</returns>
 public string[] OnBotJoin(int sid, Channel c)
 {
     if ( BotJoin == null )
         return null;
     JoinPartEvent je = new JoinPartEvent();
     je.sid = sid;
     je.channel = c;
     je.user = null;
     return InvocationTunnel( BotJoin.GetInvocationList(), je, "onJoinData" );
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Fires the OnPart event.
 /// </summary>
 /// <param name="sid">The server id.</param>
 /// <param name="cu">The channel user that parted.</param>
 /// <param name="c">The channel parted.</param>
 /// <param name="message">The message sent to the server.</param>
 /// <returns>The raw data to be sent to the server.</returns>
 public string[] OnPart(int sid, ChannelUser cu, Channel c, string message)
 {
     if ( Part == null )
         return null;
     JoinPartEvent je = new JoinPartEvent();
     je.sid = sid;
     je.channel = c;
     je.user = cu;
     je.message = message;
     return InvocationTunnel( Part.GetInvocationList(), je, "onPartData",
         ( cu.InternalUser.UserAttributes == null ) ? null : cu.InternalUser.UserAttributes.Privegeles );
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Fires the OnJoin event.
 /// </summary>
 /// <param name="sid">The server on which the user has joined a channel.</param>
 /// <param name="channel">The channel which the user has joined.</param>
 /// <param name="cu">The user which joined the channel.</param>
 /// <returns>The raw data to be sent to the server.</returns>
 public string[] OnJoin(int sid, Channel c, ChannelUser cu)
 {
     if ( Join == null )
         return null;
     JoinPartEvent je = new JoinPartEvent();
     je.sid = sid;
     je.channel = c;
     je.user = cu;
     return InvocationTunnel( Join.GetInvocationList(), je, "onJoinData",
         ( cu.InternalUser.UserAttributes == null ) ? null : cu.InternalUser.UserAttributes.Privegeles );
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Fires the OnNames event.
 /// </summary>
 /// <param name="sid">The Server the names are coming from.</param>
 /// <param name="channel">The channel the names were filled into.</param>
 /// <returns>The raw data to be sent to the server.</returns>
 public string[] OnNames(int sid, Channel c)
 {
     //TODO: Give this it's own injector? PROBABLY NOT LOL
     if ( Names == null )
         return null;
     JoinPartEvent je = new JoinPartEvent();
     je.sid = sid;
     je.channel = c;
     je.user = null;
     return InvocationTunnel( Names.GetInvocationList(), je, "onNamesData" );
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Fires the OnBartPart event.
 /// </summary>
 /// <param name="sid">The server id.</param>
 /// <param name="c">The channel parted.</param>
 /// <param name="message">The message sent to the server.</param>
 /// <returns>The raw data to be sent to the server.</returns>
 public string[] OnBotPart(int sid, Channel c, string message)
 {
     if ( BotJoin == null )
         return null;
     JoinPartEvent je = new JoinPartEvent();
     je.sid = sid;
     je.channel = c;
     je.user = null;
     je.message = message;
     return InvocationTunnel( BotPart.GetInvocationList(), je, "onPartData" );
 }