Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Issuer.name into Onsay
#1
Sup guys, how do I get the issuer.name into public override onsay? I can only get client and message.
Reply

#2
client.Name ?
[Image: MaEIQ.png]
Reply

#3
(03-31-2013, 19:34)Pozzuh Wrote: client.Name ?

Did this
straight after posting (felt like a derp), thanks though man.
Also how would I get a client name via the client number?
Reply

#4
(04-01-2013, 10:56)legitmidget Wrote:
(03-31-2013, 19:34)Pozzuh Wrote: client.Name ?

Did this
straight after posting (felt like a derp), thanks though man.
Also how would I get a client name via the client number?

Example:
CSHARP Code
  1. public override ChatType OnSay(string Message, ServerClient Client)
  2. {
  3. if (Message.StartsWith("!clientnum"))
  4. {
  5. string[] split = Message.Split(' ');
  6.  
  7. foreach (ServerClient c in GetClients())
  8. {
  9. if (c.ClientNum == int.Parse(split[1]))
  10. {
  11. ServerSay(c.Name, true);
  12. }
  13. }
  14. return ChatType.ChatNone;
  15. }
  16. return ChatType.ChatContinue;
  17. }
Reply

#5
Thanks, were using this for a !tmpbanc and !warnc command Tongue
Reply

#6
Is there any reason I am missing that you are not using GetClient instead of GetClients ?
Reply

#7
(04-01-2013, 17:34)archit Wrote: Is there any reason I am missing that you are not using GetClient instead of GetClients ?

Nope, I didn't even think of using it lol
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Change [Message] value in OnSay AboAlwe 6 3,329 06-29-2012, 20:00
Last Post: AboAlwe

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.