collapse collapse
* User Info
 
 
Welcome, Guest. Please login or register.
* Search

* Board Stats
  • stats Total Members: 989
  • stats Total Posts: 18365
  • stats Total Topics: 2500
  • stats Total Categories: 7
  • stats Total Boards: 35
  • stats Most Online: 1144

Author Topic: How to check request channel?  (Read 2440 times)

0 Members and 1 Guest are viewing this topic.

Offline Organizer

  • BeBot Apprentice
  • ***
  • Posts: 135
  • Karma: +0/-0
How to check request channel?
« on: August 13, 2008, 12:46:48 am »
I'm been trolling around the wiki and other post, but I can't seem to figure out how to do a check on where the command is issued from...

I am aking a module that displays different content based on your security level... the issues is that if a person with high security level writes the command it in guild chat, it picks up the private info and posts it right back there... I would simply like to do something like a -> IF CHANNEL (or what it is called)  = GUILD THEN XXX ELSE XXX.

Would this be possible somehow, if I've made myself clear enough for anyone to understand me. I'd like the output in Guild but the non private version of it, so I would have to do a check if its triggered via Tell or Guild before doing the > return > this > bot > xx to make this happen... any ideas from the experts?

Offline Alreadythere

  • BeBot Maintainer
  • BeBot Hero
  • ******
  • Posts: 1288
  • Karma: +0/-0
Re: How to check request channel?
« Reply #1 on: August 13, 2008, 06:27:49 am »
The command_handler() function has an $origin (sometimes called $channel too) parameter, this can be used to differentiate between the input channels.

Offline Organizer

  • BeBot Apprentice
  • ***
  • Posts: 135
  • Karma: +0/-0
Re: How to check request channel?
« Reply #2 on: August 13, 2008, 11:48:15 am »
Thanks for the tip, that should do the trick, can't believe I did not notice that variable before :)

 

* Recent Posts
0.8.x updates for AO by bitnykk
[June 23, 2024, 03:19:47 pm ]


0.8.x updates for AoC by bitnykk
[June 23, 2024, 03:19:44 pm ]


[AoC] special char for items module by bitnykk
[February 09, 2024, 09:41:18 pm ]


BeBot still alive & kicking ! by bitnykk
[December 17, 2023, 12:58:44 am ]


Bebot and Rasberry by bitnykk
[November 29, 2023, 11:04:14 pm ]

* Who's Online
  • Dot Guests: 261
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.
* Forum Staff
bitnykk admin bitnykk
Administrator
Khalem admin Khalem
Administrator
WeZoN gmod WeZoN
Global Moderator
SimplePortal 2.3.7 © 2008-2024, SimplePortal