This is what I have now and it seems to actually teleport me, but then once again I spawn right back on top of the NPC with no instance attached.
Code:
sub EVENT_POPUPRESPONSE {
if($uguild_id > 0) {
if(($popupid == 50) && (defined($qglobals{"$uguild_id$space$instguild$space$zonesn"}))) {
my $guildinstanceglobal = "$uguild_id$space$instguild$space$zonesn";
my $instid = $qglobals->{$guildinstanceglobal};
quest::AssignToInstance($instid);
quest::MovePCInstance(qeynos, $instid, 0, 0, 0);
}
else {
plugin::SendToInstance("guild", "qeynos", 1, 0, 0, 0, "guild", 604800);
}
}
}