BeBot - An Anarchy Online and Age Of Conan chat automaton
Development => Module Requests => Topic started by: Huesos on January 20, 2011, 11:13:21 pm
-
I'm requesting in !raid check once ppl !raid join for a <invite to raid> link inside much like in the Alliance relay chat. I have tried but nada,because I am really novice on any php. Once you hit !raid check click each person to invite.
-
maybe this mod would be interesting for u
http://bebot.link/generic-custom-modules/eqdkp-ingame-query-module/
greetz drizz
-
maybe this mod would be interesting for u
http://bebot.link/generic-custom-modules/eqdkp-ingame-query-module/
greetz drizz
Nope has nothing to with dkp or points..
regular raid.php
!raid check
in the box like <kick> a <invite to raid> on the player
-
The module that was shown by drizz has just the button you are looking for, regardless of the points system it was built for ;). Now i am also not a PHP hero, but i am pretty sure you could steal the code from that module (by steal i mean ask the author to use the code and thanks in in the credits)..
-
true I probably could, as well as the one in Ally chat one.(already been trying, but nada), but to integrate it into the php is a whole other issue as to get it to work that is beyond me,(to put it next to the <kick> click). Hence why I made a post here for ppl who has way more php and bebot programming then I do.(very novice)
-
The dkp module is more complex and for me cannot readily incorporate the invite blob anyhow.. I don't have eqdkp access (on a site)anyhow.. It is beyond me if the code is there and to add it in the Raid.php.
lines 687-694:
{
$list = "Users Not with Raid Group: ";
foreach ($missing[1] as $player)
{
$inside .= $player . " [".$this -> bot -> core("tools") -> chatcmd(
"raid kick ".$player." Not with Group", "Kick")."]\n";
$list .= $player.", ";
$count++;
}
-
I have found in a Ally module this command:
$blob .= "<a href='chatcmd:///invite ".$player."'>$player</a> invite to group<br>";
$blob .= "<a href='chatcmd:///invitetoraid ".$player."'>$player</a> invite to raid";
but have no idea how to place it , when I !raid check
then have it list the players and right next to <kick> a <invite to raid> etc
the dkp one I'm not into using, plus don't have any eqdkp system
-
heres the !raid check part
/*
Checks memebers on a raid
*/
function check_raid($name, $names)
{
if ($this -> bot -> core("security") -> check_access($name, $this -> bot -> core("settings") -> get('Raid', 'Command')))
{
if(!empty($names))
{
if(preg_match_all("/Can\'t find target >([A-Za-z0-9]+)<\./", $names, $missing))
{
$list = "Users Not with Raid Group: ";
foreach ($missing[1] as $player)
{
$inside .= $player . " [".$this -> bot -> core("tools") -> chatcmd(
"raid kick ".$player." Not with Group", "Kick")."]\n";
$list .= $player.", ";
$count++;
}
$list = substr($list, 0, -2);
$this -> raid_command($name, $list);
Return("##highlight##".$count."##end## Players Missing :: ".$this -> bot -> core("tools") -> make_blob("click to view", $inside));
}
else
Return("##highlight##0##end## Players Missing");
}
else
{
$players = array_keys($this -> user);
sort($players);
$inside = "##blob_title##:::: People in the raid ::::##end##\n\n";
$inside .= "Send not-joined warnings: ".$this -> bot -> core("tools") -> chatcmd("raid notin", "raid notin")."\n";
$inside .= "Kick not-joined from bot: ".$this -> bot -> core("tools") -> chatcmd("raid notinkick", "raid notinkick")."\n\n";
if (!empty($players))
{
if($this -> bot -> game == "ao")
{
foreach ($players as $player)
{
if (!empty($assist))
$assist .= " \\n /assist $player";
else
$assist = "/assist $player";
}
$inside .= "<a href='chatcmd://$assist'>Check all raid members</a>\n\n";
}
$inside .= "Example use: <pre>raid check Can't assist yourself. Target is not in a fight. Can't find target >Chris05<.\n\n";
foreach ($players as $player)
{
$who = $this -> bot -> core("whois") -> lookup($player, TRUE); //All info about raiders are expected to be correct as already beeing member and all.
if ($who['faction']=="Omni")
$info = " [##omni##Omni</font>/";
elseif ($who['faction']=="Clan")
$info = " [##clan##Clan</font>/";
elseif ($who['faction']=="Neutral")
$info = " [##neut##Neut</font>/";
else //Should never happend but who knows shit happens.
$info = " [<font color=#D7FFBC>".$who['faction']."</font>/";
$info .= "<font color=#A2FF4C>" . $who['level']."</font>/";
$info .= "<font color=#FFFB9E>" . $who['profession']."</font>]";
$inside .= $player . $info . " [".$this -> bot -> core("tools") -> chatcmd(
"raid kick ".$player, "Kick")."]\n";
}
}
else
$inside .= "There are no members of this raid.";
return "Players in raid :: " .
$this -> bot -> core("tools") -> make_blob("click to view", $inside);
}
}
else
return "You must be a " . $this -> bot -> core("settings") -> get('Raid', 'Command') . " to do Raid Commands";
}
/*
-
making progress think I just got it .. at least in the name who !raid join 's
a invite to raid link on them with it
/*
Checks memebers on a raid
*/
function check_raid($name, $names)
{
if ($this -> bot -> core("security") -> check_access($name, $this -> bot -> core("settings") -> get('Raid', 'Command')))
{
if(!empty($names))
{
if(preg_match_all("/Can\'t find target >([A-Za-z0-9]+)<\./", $names, $missing))
{
$list = "Users Not with Raid Group: ";
foreach ($missing[1] as $player)
{
$inside .= $player . " [".$this -> bot -> core("tools") -> chatcmd(
"raid kick ".$player." Not with Group", "Kick")."]\n";
$list .= $player.", ";
$count++;
}
$list = substr($list, 0, -2);
$this -> raid_command($name, $list);
Return("##highlight##".$count."##end## Players Missing :: ".$this -> bot -> core("tools") -> make_blob("click to view", $inside));
}
else
Return("##highlight##0##end## Players Missing");
}
else
{
$players = array_keys($this -> user);
sort($players);
$inside = "##blob_title##:::: People in the raid ::::##end##\n\n";
$inside .= "Send not-joined warnings: ".$this -> bot -> core("tools") -> chatcmd("raid notin", "raid notin")."\n";
$inside .= "Kick not-joined from bot: ".$this -> bot -> core("tools") -> chatcmd("raid notinkick", "raid notinkick")."\n\n";
if (!empty($players))
{
if($this -> bot -> game == "ao")
{
foreach ($players as $player)
{
if (!empty($assist))
$assist .= " \\n /assist $player";
else
$assist = "/assist $player";
}
$inside .= "<a href='chatcmd://$assist'>Check all raid members</a>\n\n";
}
$inside .= "Example use: <pre>raid check Can't assist yourself. Target is not in a fight. Can't find target >Chris05<.\n\n";
foreach ($players as $player)
{
$who = $this -> bot -> core("whois") -> lookup($player, TRUE); //All info about raiders are expected to be correct as already beeing member and all.
if ($who['faction']=="Omni")
$info = " [##omni##Omni</font>/";
elseif ($who['faction']=="Clan")
$info = " [##clan##Clan</font>/";
elseif ($who['faction']=="Neutral")
$info = " [##neut##Neut</font>/";
else //Should never happend but who knows shit happens.
$info = " [<font color=#D7FFBC>".$who['faction']."</font>/";
$info .= "<font color=#A2FF4C>" . $who['level']."</font>/";
$info .= "<font color=#FFFB9E>" . $who['profession']."</font>]";
$inside .= "<a href='chatcmd:///invitetoraid ".$player."'>$player</a> invite to raid" . $info . " [".$this -> bot -> core("tools") -> chatcmd(
"raid kick ".$player, "Kick")."]\n";
}
}
else
$inside .= "There are no members of this raid.";
return "Players in raid :: " .
$this -> bot -> core("tools") -> make_blob("click to view", $inside);
}
}
else
return "You must be a " . $this -> bot -> core("settings") -> get('Raid', 'Command') . " to do Raid Commands";
}