• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Bugs + Suggestion + Request

kito2

www.masteria.net
Joined
Mar 9, 2009
Messages
3,766
Solutions
1
Reaction score
225
Location
Chile, Santiago
1) Leaders and Vice-Leaders should invite players to a guild.
2) There are problems on leaving guild.
3) There should be a newstickers system.
4) Showing online members on guilds:

PHP:
 <?php
$ide = new IDE;
try { $ide->loadInjections('guild_view'); } catch(Exception $e) { error($e->getMessage()); }
$logo = (file_exists("public/guild_logos/".$guild->getId().".gif")) ? "<img src='".WEBSITE."/public/guild_logos/".$guild->getId().".gif' width='64' height='64'>" : "<img src='".WEBSITE."/public/guild_logos/default.gif'>";
?>

<style type="text/css">
    #logon { width: 97%; height: 100%; padding: 0.5em; }
    #logon h3 { text-align: center; margin: 0; height 10px;}
    </style>

<div id="logon" class="ui-widget-content">
    <h3 class="ui-widget-header"> <?PHP ECHO "".$guild->getName()."";?> </h3>
    <br>
<div id="characters" class="ui-helper-clearfix">
<?PHP 
ECHO "<div style=\"float:left;padding: 0px 5% 9px;\">";
ECHO "$logo"; 
ECHO "</div>";
ECHO "<div style=\"padding: 0px 23% 0px; width:75%;\">";
$mod = $guild->getCustomField("motd");
ECHO $mod;
ECHO "<br><BR>Guild Leader: <a href='".WEBSITE."/index.php/character/view/".$guild->getOwner()."'>".$guild->getOwner()."</a>";
ECHO "</div>";
?>
</div>
</div>
<br>
<?PHP

       
        $rank_list = $guild->getGuildRanksList();
        $rank_list->orderBy('level', POT::ORDER_DESC);
        $showed_players = 1;
                if($ide->isLogged()) {
                $ots = POT::getInstance();
                $ots->connect(POT::DB_MYSQL, connection());
                $account_logged = new OTS_Account();
                $account_logged->load($_SESSION['account_id']);
                $account_players = $account_logged->getPlayers();
                }
        echo "<div style=\"padding: 0.5em;\" class=\"ui-widget-content\">";
                foreach($rank_list as $rank)
                {
                        $players_with_rank = $rank->getPlayersList();
                        $players_with_rank->orderBy('name');
                        $players_with_rank_number = count($players_with_rank);
                        if($players_with_rank_number > 0)
                        {
                                echo "<div class=\"ui-widget-header\"><center><b>".$rank->getName()."</b></center></div>";
                                foreach($players_with_rank as $player)
                                {
                                        $guild_nick = $player->getGuildNick();
                                        if(!empty($guild_nick)) $guild_nick = "($guild_nick)"; else $guild_nick = "";
                                        
                                        if($ide->isLogged()) {$leave = (in_array($player->getName(), $account_players)) ? "<a href='#' onClick='if(confirm(\"Are you sure you want to leave ".$guild->getName()." with a ".$player->getName()." ?\")) window.location.href=\"".WEBSITE."/index.php/guilds/leave/".$guild->getId()."/".$player->getId()."\"'><img src='".WEBSITE."/public/images/false.gif'/></a>" : ""; }
                                        echo @"<li class=\"ui-state-default ui-corner-all\">$leave <a onmouseover=\"tooltip.show('$input', 225);\" onmouseout=\"tooltip.hide();\" href=\"".WEBSITE."/index.php/character/view/".$player->getName()."\">".$player->getName()."</a> $guild_nick </li>";
                                }
                        }
                }
        echo "</div><br>";
               
        if(!$ide->isLogged()) {
                alert("You need to be logged in to access any options.");
        }
        else {

                require_once('system/application/libraries/POT/InvitesDriver.php');
                new InvitesDriver($guild);
                $invited_list = $guild->listInvites();
                        echo "<div style=\"padding: 0.5em;\" class=\"ui-widget-content\">";
                if(count($invited_list) == 0)
                        echo "<center><b>This guild did not invite anyone.</b></center>";
                else {

                echo "<table width=\"100%\"><tr align=center><td width=50%><div class=\"ui-widget-header\"><b>Name<b></div></td><td width=50%><div class=\"ui-widget-header\"><b>Join</b></div></td></tr></table><table width=\"100%\">";
                $characters = array();
                if($ide->isLogged()) {
                        foreach($account_players as $player_from_acc) {
                                $characters[] = $player_from_acc->getName();
                        }
                }
                       
                foreach($invited_list as $invited_player)
                        {
if($ide->isLogged() && in_array($invited_player->getName(), $characters)) {
echo "<tr><td><li class=\"ui-state-default ui-corner-all\"><center><a href=\"".WEBSITE."/index.php/character/view/".$invited_player->getName()."\">".$invited_player->getName()."</a></center></li></td><td><center><a href='".WEBSITE."/index.php/guilds/join/".$guild->getId()."/".$invited_player->getId()."'><span class=\"ui-icon ui-icon-check\"></span></a></center></li>";    
             }
       else {
       echo "<tr><td width=50%><li class=\"ui-state-default ui-corner-all\"><center><a href=\"".WEBSITE."/index.php/character/view/".$invited_player->getName()."\">".$invited_player->getName()."</a></center></li></td><td width=50%><center><span class=\"ui-icon ui-icon-closethick\"></span></center></tr>";
                                               
                                                }
                               
                               
                        }
                echo "</table></div>";
                }
       
        }
        if(($ide->isLogged() && in_array($guild->getOwner(), $account_players)) or $viceleaders) {
                echo "<br/><div class='toolbar'>";
                echo "<a href='".WEBSITE."/index.php/guilds/management/".$guild->getId()."'>Guild Management</a>";     
                echo "</div>";
        }

?>

I use this one.
 
2)
Lua:
function onSay(cid, words, param, channel)
	local guid = getPlayerGUID(cid)
	local acc_id = getPlayerAccountId(cid)
	if (getCreatureCondition(cid, CONDITION_INFIGHT) == FALSE) then
		player = getPlayerGUID(cid)
		doRemoveCreature(cid)
		db.executeQuery("UPDATE `players` SET `rank_id` = 0 WHERE `id` = " .. player)
	else
        doPlayerSendCancel(cid, "You can't use this command after a fight.")
		doSendMagicEffect(getPlayerPosition(cid),2)	
	end
	
	return true
end
 
The guild system must be updated, there are a lot of minor bugs that must be fixed.
 
Till then, we should post the temporary solutions, like the script that I made there for leaving guilds.
 
@4

PHP:
<?php echo $status = ($player->isOnline()) ? "<font color='green'>Online</font>" : "<font color='red'>Offline</font>"; ?>
?
 
1) Leaders and Vice-Leaders should invite players to a guild.
2) There are problems on leaving guild.
 
GO and fuck you yourself, if you don't want to read the topic, just don't read it.

I will continue "BUMPING" this topic every 24 hours till I get a solution, if you read the rules, that isn't spamming.
 
GO and fuck you yourself, if you don't want to read the topic, just don't read it.

I will continue "BUMPING" this topic every 24 hours till I get a solution, if you read the rules, that isn't spamming.

So the rules are wrong, they didnt expected that idiots like you will make not double, but uber-multi triple post with bumps ;]
Anyway, go bumping your thread smart guy.
 
Back
Top