Ejemplo n.º 1
0
function get_flavor()
{
    global $mysql, $npcid;
    $aid = get_adventure_id();
    $array = array();
    $array['aid'] = $aid;
    $query = "SELECT nt.adventure_template_id, atef.text\n            FROM adventure_template_entry_flavor as atef \n            INNER JOIN npc_types nt ON atef.id = nt.adventure_template_id\n            WHERE nt.adventure_template_id=\"{$aid}\"";
    $result = $mysql->query_assoc($query);
    return $result;
}
Ejemplo n.º 2
0
     break;
 case 28:
     // Copy npc
     check_authorization();
     copy_npc();
     $npcid = $_POST['id'];
     header("Location: index.php?editor=npc&z={$z}&zoneid={$zoneid}&npcid={$npcid}");
     exit;
 case 29:
     // Edit Adventure id
     check_authorization();
     $body = new Template("templates/npc/adventureid.edit.tmpl.php");
     $body->set('currzone', $z);
     $body->set('currzoneid', $zoneid);
     $body->set('npcid', $npcid);
     $body->set('adventure_id', get_adventure_id());
     $body->set('suggested_id', suggest_adventure_id());
     break;
 case 30:
     // Update adventure id
     check_authorization();
     update_adventure_id();
     header("Location: index.php?editor=npc&z={$z}&zoneid={$zoneid}&npcid={$npcid}");
     exit;
 case 31:
     // Edit Trap id
     check_authorization();
     $body = new Template("templates/npc/traptemplate.edit.tmpl.php");
     $body->set('currzone', $z);
     $body->set('currzoneid', $zoneid);
     $body->set('npcid', $npcid);