Booya
collapse collapse

* User Info

 
 
Welcome, Guest. Please login or register.
Did you miss your activation email?

* Search


* Board Stats

  • stats Total Members: 987
  • stats Total Posts: 18309
  • stats Total Topics: 2490
  • stats Total Categories: 7
  • stats Total Boards: 33
  • stats Most Online: 500

Author Topic: BeBot v0.6.8 released - Rise of the Godslayer edition  (Read 81118 times)

0 Members and 1 Guest are viewing this topic.

Offline Kyr

  • BeBot Apprentice
  • ***
  • Posts: 177
  • Karma: +0/-0
Re: BeBot v0.6.8 released - Rise of the Godslayer edition
« Reply #15 on: June 06, 2010, 08:19:37 pm »
The mains list does provide a link to !whois which does have the alts details.

Offline Justine

  • BeBot Rookie
  • *
  • Posts: 16
  • Karma: +0/-0
Re: BeBot v0.6.8 released - Rise of the Godslayer edition
« Reply #16 on: June 07, 2010, 02:16:45 am »
Ok that is exactly what I would want - however in the version before this one and obviously the version now it does not do that. I will have to see what version I had before and compare it.  I get a list of member breakdowns by classes and it seems to include the alts in the counts.

Offline Yite

  • BeBot Apprentice
  • ***
  • Posts: 152
  • Karma: +0/-0
    • Niflheim - Crom
Re: BeBot v0.6.8 released - Rise of the Godslayer edition
« Reply #17 on: June 07, 2010, 11:08:26 am »
Pretty sure it's not in the standard code.

You can modify the modules/Roster.php and add the following:
Code: [Select]
        function memberslistmain()
        {
                $blob = "";
                $count = 0;
                $result = $this -> bot -> db -> select("SELECT nickname, last_seen FROM #___users LEFT JOIN alts ON #___users.nickname = alts.alt WHERE user_level = " . MEMBER . " AND alts.alt IS NULL ORDER BY nickname ASC");
                if (!empty($result))
                {
                        $inside = "##blob_title##:::: <botname>'s Mains List ::::##end##\n\n";
                        foreach ($result as $val)
                        {
                                $count++;
                                $inside .= "##blob_text##&#8226; " . $val[0];
                                if ($val[1] > 0)
                                {
                                        $inside .= ", last seen at " . gmdate($this -> bot -> core("settings") -> get("Time", "FormatString"), $val[1]);
                                }
                                else
                                {
                                        $inside .= ", never seen online";
                                }
                                $inside .= "##end## ".$this -> bot -> core("tools") -> chatcmd("whois " . $val[0], "[Whois]")."\n";
                        }
                        $blob = " :: " . $this -> bot -> core("tools") -> make_blob("click to view", $inside);
                }
                return $count . " mains in <botname>" . $blob;
        }
You'd also have to change the command_handler code to allow for a !member main command.
-Yite [Crom]

 

* Recent Posts

0.7.x updates for AO by bitnykk
[September 16, 2020, 04:40:04 pm]


0.7.x updates for AoC by bitnykk
[September 16, 2020, 04:39:47 pm]


Bebot 0.7.x still Alive ?! by bitnykk
[August 28, 2020, 07:09:23 pm]


Stats module by bitnykk
[April 16, 2020, 04:45:43 pm]


OnlineOrg by Hell
[February 28, 2020, 11:21:55 pm]

* Who's Online

  • Dot Guests: 91
  • 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-2020, SimplePortal