var hmph = '';

function tire() {
    hmph = $(".prefs textarea").text();
    $("body, header, nav, footer").css('background', 'url(images/tired-1.jpg) center top no-repeat fixed, url(images/tired-2.jpg) center 364px no-repeat fixed');
    $("body, header, nav, footer").css('backgroundColor', '#666666');
    $(".tired").css('font-weight', 'bold');
    $(".colors").css('font-weight', 'normal');
    hmph = hmph.replace("colors", "tired");
    
    $(".prefs textarea").text(hmph);
    }

function colorize() {
    hmph = $(".prefs textarea").text();
    $("body, header, nav, footer").css('background', 'url(images/colors-1.jpg) center top no-repeat fixed, url(images/colors-2.jpg) center 364px no-repeat fixed');
    $("body, header, nav, footer").css('backgroundColor', '#666666');
    $(".tired").css('font-weight', 'normal');
    $(".colors").css('font-weight', 'bold');
    hmph = hmph.replace("tired", "colors");
    $(".prefs textarea").text(hmph);
    }

function lod() {
    hmph = $(".prefs textarea").text();
    $("body #main, body #main #text").css('background-color', '#222');
    $("body #main, body #main #text").css('color', '#eaeaea');
    $("a, a:visited").css('color', '#9cd1f4');
    $("nav a, nav a:visited").css('color', '#000');
    $(".dol").css('font-weight', 'normal');
    $(".lod").css('font-weight', 'bold');
    $("hr").css('border-color', '#fafafa');
    hmph = hmph.replace("dol", "lod");
    $(".prefs textarea").text(hmph);
    }
    
function dol() {
    hmph = $(".prefs textarea").text();
    $("body #main, body #main #text").css('background-color', '#fafafa');
    $("body #main, body #main #text").css('color', '#222');
    $("a, a:visited").css('color', '#276987');
    $("nav a, nav a:visited").css('color', '#000');
    $(".lod").css('font-weight', 'normal');
    $(".dol").css('font-weight', 'bold');
    $("hr").css('border-color', '#111');
    hmph = hmph.replace("lod", "dol");
    $(".prefs textarea").text(hmph);
    }
    
function nomovie() {
    hmph = $(".prefs textarea").text();
    $(".yesmovie").css('font-weight', 'normal');
    $(".nomovie").css('font-weight', 'bold');
    hmph = hmph.replace("show", "hide");
    $(".prefs textarea").text(hmph);
    }
    
function yesmovie() {
    hmph = $(".prefs textarea").text();
    $(".nomovie").css('font-weight', 'normal');
    $(".yesmovie").css('font-weight', 'bold');
    hmph = hmph.replace("hide", "show");
    $(".prefs textarea").text(hmph);
    }
    
function both() {
    hmph = $(".prefs textarea").text();
    $(".links").css('font-weight', 'normal');
    $(".buttons").css('font-weight', 'normal');
    $(".both").css('font-weight', 'bold');
    hmph = hmph.replace("nobuttons", "yesbuttons");
    hmph = hmph.replace("nolinks", "yeslinks");
    $(".prefs textarea").text(hmph);
    }
    
function buttons() {
    hmph = $(".prefs textarea").text();
    $(".links").css('font-weight', 'normal');
    $(".buttons").css('font-weight', 'bold');
    $(".both").css('font-weight', 'normal');
    hmph = hmph.replace("nobuttons", "yesbuttons");
    hmph = hmph.replace("yeslinks", "nolinks");
    $(".prefs textarea").text(hmph);
    }    
    
function links() {
    hmph = $(".prefs textarea").text();
    $(".links").css('font-weight', 'bold');
    $(".buttons").css('font-weight', 'normal');
    $(".both").css('font-weight', 'normal');
    hmph = hmph.replace("yesbuttons", "nobuttons");
    hmph = hmph.replace("nolinks", "yeslinks");
    $(".prefs textarea").text(hmph);
    }        
   
function charPartSwitch(x) {
    $('#char-nav a').css('font-weight', 'normal'); $('.b'+x).css('font-weight', 'bold');
    $('.portrait').css('border-color', '#111');
    $('.portrait').hide(); $('.part'+x).show();
    $('#charinfo').html('');
    }
    
function charInfo(x) {
    $('.portrait').css('border-color', '#111');
    $('.portrait.'+x).css('border-color', '#f00');
    $('#main').css('background', '#fafafa url(images/'+x+'-full.png) center 100px no-repeat');
    switch(x) 
        {
        case 'jeuni':
        $('#charinfo').html('Jeuni Huros');
        break;
        
        case 'giant':
        $('#charinfo').html('Aranji Herald');
        break;
        
        case 'kihara':
        $('#charinfo').html('<p><b>Kihara Watsuji</b></p><p>The thirty-third Holder of the Covenant, ...</p>');
        break;
        
        case 'ynthon2':
        $('#charinfo').html('Captain Tomora Ynthon');
        break;
        
        case 'ynthon1':
        $('#charinfo').html('Commander Tomora Ynthon');
        break;
        
        case 'jung':
        $('#charinfo').html('Private Jung');
        break;
        
        case 'gayne':
        $('#charinfo').html('Gayne Huros');
        break;
        
        case 'jyunor':
        $('#charinfo').html('Jyunor');
        break;
        
        case 'first':
        $('#charinfo').html('The man with the golden wolf mask');
        break;
        
        case 'intra':
        $('#charinfo').html('Intra Noi');
        break;
        
        case 'jeld':
        $('#charinfo').html('Jeld');
        break;
        
        case 'tyff1':
        $('#charinfo').html('Tyff Noi');
        break;
        
        case 'huun':
        $('#charinfo').html('Professor Huun Koul');
        break;
        }
    }




















