Thread: Guild Hall
View Single Post
  #4  
Old 01-15-2015, 05:56 PM
provocating's Avatar
provocating
Demi-God
 
Join Date: Nov 2007
Posts: 2,175
Default

One thing to check are the quest globals, see if an entry is being created there and check the time of when it expires, you may have to use the FROM_UNIXTIME function to get the real expire date. The Guild Hall instancing is controlled a lot from the player quest script in the Guild Lobby, look at this section.

Code:
sub EVENT_CLICKDOOR 
{
	if($doorid == 2 || $doorid == 4 || $doorid == 40 || $doorid == 42) 
	{
    		if($uguild_id > 0) 
    		{
      			if (defined($qglobals{"ginstance$uguild_id"})) 
      			{
        			$guildinstance = $qglobals{"ginstance$uguild_id"};
        			quest::AssignToInstance($guildinstance);
        			quest::MovePCInstance(345, $guildinstance, -1.00, -1.00, 3.34);
      			}
      			else 
      			{
        			$guildinstance = quest::CreateInstance("guildhall", 1, 86400);
        			quest::AssignToInstance($guildinstance); 
        			quest::setglobal("ginstance$uguild_id",$guildinstance,7,"H24");
        			quest::MovePCInstance(345, $guildinstance, -1.00, -1.00, 3.34)
      			}
    		}
  	}
  	if((($doorid >= 5) && ($doorid <= 38)) ||  (($doorid >= 43) && ($doorid <= 76)))
  	{
		$client->OpenLFGuildWindow();
  	}
}
Reply With Quote