mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-02 14:25:38 +08:00
推了第一个single-ws分支
This commit is contained in:
@@ -10,13 +10,13 @@ class Group
|
||||
{
|
||||
private $group_id;
|
||||
private $group_name;
|
||||
private $prefix;
|
||||
//private $prefix;
|
||||
private $members = [];
|
||||
|
||||
public function __construct($group_id, $info) {
|
||||
$this->group_id = $group_id;
|
||||
$this->group_name = $info["group_name"];
|
||||
$this->prefix = $info["prefix"];
|
||||
//$this->prefix = $info["prefix"];
|
||||
$member_list = $info["member"];
|
||||
$this->members = [];
|
||||
foreach ($member_list as $k => $v) {
|
||||
@@ -38,13 +38,6 @@ class Group
|
||||
return $this->group_name;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return mixed
|
||||
*/
|
||||
public function getPrefix() {
|
||||
return $this->prefix;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
*/
|
||||
@@ -67,14 +60,6 @@ class Group
|
||||
$this->group_name = $group_name;
|
||||
}
|
||||
|
||||
/**
|
||||
* set自定义群称号的方法
|
||||
* @param mixed $prefix
|
||||
*/
|
||||
public function setPrefix($prefix) {
|
||||
$this->prefix = $prefix;
|
||||
}
|
||||
|
||||
/**
|
||||
* set群成员的类
|
||||
* @param array $members
|
||||
|
||||
@@ -47,9 +47,6 @@ class Admin extends ModBase
|
||||
if(Buffer::in_array("su", $user)) Buffer::unsetByValue("su", $user);
|
||||
$this->reply("removed operator $user");
|
||||
return true;
|
||||
case "test":
|
||||
$this->reply("Hello world");
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -19,6 +19,9 @@ class Example extends ModBase
|
||||
case "ping":
|
||||
$this->reply("pong");
|
||||
return true;
|
||||
case "test":
|
||||
$this->reply("Hello world");
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user