campaignTrail_temp.global_parameter_json = JSON.parse("[{\"model\": \"campaign_trail.global_parameter\", \"pk\": 1, \"fields\": {\"vote_variable\": 1.125, \"max_swing\": 0.0, \"start_point\": 1.00, \"candidate_issue_weight\": 10.0, \"running_mate_issue_weight\": 3.0, \"issue_stance_1_max\": -0.71, \"issue_stance_2_max\": -0.3, \"issue_stance_3_max\": -0.125, \"issue_stance_4_max\": 0.125, \"issue_stance_5_max\": 0.3, \"issue_stance_6_max\": 0.71, \"global_variance\": 0.001, \"state_variance\": 0.001, \"question_count\": 25, \"default_map_color_hex\": \"#fffcf5\", \"no_state_map_color_hex\": \"#999999\"}}]"); campaignTrail_temp.election_json = JSON.parse("[{\"model\": \"campaign_trail.election\", \"pk\": 4, \"fields\": {\"year\": 1968, \"summary\": \"Going into the chaos of the 1968 Presidential Election, America is on the brink of total calamity.

It is embroiled in a vicious battle in Indochina. It is lead by a disgraced President, one who the people no longer believe. It is mired in racial strife it has not seen ever before. America's bloody wounds are coming to the forefront of the public consciousness, and the American people's worst impulses may yet win them over.

George Romney, emerging out of a Michigan wracked by riots, of a tenure with few accomplishments, of a record blemished by scandal and petty politicking, must prove he is the best man fit to lead America. \", \"image_url\": \"https://i.imgur.com/2P33buo.png\", \"winning_electoral_vote_number\": 270, \"advisor_url\": \"https://i.imgur.com/nhB5z21.png\", \"recommended_reading\": \"

General Resources

Final 1968 Results
Theodore White - The Making of the President 1968 (Landmark Political)
Rick Perlstein - Nixonland: The Rise of a President and the Fracturing of America

By the Candidates

Richard Nixon - The Memoirs of Richard Nixon
Hubert Humphrey - 1948 Civil Rights speech
George Wallace - 1967 speech on dissent and intellectualism

The Vietnam War

Stanley Karnow - Vietnam: A History

Misceallany

Secret of '68
Living Apart: How the Government Betrayed a Landmark Civil Rights Law
The G.O.P.'s Journey From the Liberal Days of Nixon
George Wallace and the 1968 Election\", \"has_visits\": 1, \"no_electoral_majority_image\": \"../static/images/1968-no-majority.jpg\"}}]"); campaignTrail_temp.candidate_json = JSON.parse("[{\"model\": \"campaign_trail.candidate\", \"pk\": 23, \"fields\": {\"first_name\": \"George\", \"last_name\": \"Romney\", \"election\": 4, \"party\": \"Republican\", \"state\": \"Michigan\", \"priority\": 1, \"description\": \"

Who is this man? What right does he have, to think he can run for President?

Ask him yourself, and he'll smile. Gush a little, talk about how he see's it as God guiding him through, how His actions have nudged him little by little to this very moment. Gotta give a little credit to the Old Man upstairs, he says. But then he checks himself, backtracks -- before he checks himself again. He's satisfied with his original answer.

Ask his opponents across the aisle? He has none. He's a lobbyist serving the business interests of the Big Three, don't you listen to any of his platitudes about 'trust-busting', or his damned act in front of Kefauver's committee a few years back. He's not genuine, they'll confess. They believe it -- how else could this little man, plucked from Northern Mexico as a child, have gotten as far as he has? From small-town lobbyist, then turning around an impotent company just a few years later, and only then finding a political interest?

His 'reform' in Michigan? By this point, their hands are shaking. Their faces are red. They hate him. He's a corporatist, he's a vehicle of Big Business, he's a...

He's a godly man, adherent to a distrusted and mocked faith. A family man, wanting only the best for his wife and kids. A man who has principles, however flawed they may be.

\", \"color_hex\": \"#992F39\", \"secondary_color_hex\": \"#CE404E\", \"is_active\": 1, \"image_url\": \"https://i.imgur.com/KGObw1M.png\", \"electoral_victory_message\": \"

Congratulations! You have won the 1968 election!

George, you’ve done it! Lenore rushes to your side as the results roll in, and your victory is confirmed. Your children, smiles arrayed across their faces, congratulate you.

With your victory, you’re now poised to deliver peace in Vietnam, reform the Great Society, and chart America’s path through the waning years of the 60’s.

\", \"electoral_loss_message\": \"

Sorry, you have lost the 1968 election.

Folks were hoping for a sharp reversal from the landslide of ‘64, but you just weren’t up for it. Republican pols are despondent that you lost such a favorable election, especially after Humphrey’s polling in the wake of the Chicago fiasco..

While you still have your remaining term as Governor to fill out, you promised your Lieutenant Governor that you would resign if you lost, and he seems keen to keep you to that promise. So long, George.

\", \"no_electoral_majority_message\": \"

Interestingly, no candidate was able to receive a majority of votes.

This is a calamity, though not of epic proportions.

You and Humphrey are sure to come to an accommodation based on whoever won the popular vote, and you both are committed to denying Wallace any leverage whatsoever. Unfortunately, whoever comes out on top is likely to have their political influence castrated by the whole affair. Let’s hope it’s you, George.

\", \"description_as_running_mate\": null, \"candidate_score\": 0.666}}, {\"model\": \"campaign_trail.candidate\", \"pk\": 24, \"fields\": {\"first_name\": \"Hubert\", \"last_name\": \"Humphrey\", \"election\": 4, \"party\": \"Democrat\", \"state\": \"Minnesota\", \"priority\": 2, \"description\": \"

.

\", \"color_hex\": \"#2F547C\", \"secondary_color_hex\": \"#3F6389\", \"is_active\": 0, \"image_url\": \"/static/images/hubert-humphrey-1968.jpg\", \"electoral_victory_message\": \"

Wow! You have won the 1968 election in a shocker!

Dixie forever! Even with the Long Hot Summer of 1967, nobody guessed that you could do well enough in the Northern states to win the election outright. You have instantly become most polarizing President-elect since Abraham Lincoln.

\", \"electoral_loss_message\": \"

As expected, you have lost the 1968 election.

You put in a good effort, but your dream of becoming president will not come to fruition in 1968

The best you can do for now is continue to sound the call for a return to sanity in American politics and reclaim your seat as governor of Alabama. Perhaps if the riots and discord continue, you will have a better chance of making your voice heard in 1972.

\", \"no_electoral_majority_message\": \"

Interestingly, no candidate was able to receive a majority of votes.

While it’s very impressive that you got this far, this is only half the battle. With a Democratically controlled House and Senate, it’s either going to be you or McCarthy.

Of course, you still have to deal with the possibility that McCarthy and Nixon dislike you so much that they will simply strike a deal with each other. Whatever happens, it's sure to be interesting.

\", \"description_as_running_mate\": null, \"candidate_score\": 1.0}}, {\"model\": \"campaign_trail.candidate\", \"pk\": 25, \"fields\": {\"first_name\": \"George\", \"last_name\": \"Wallace\", \"election\": 4, \"party\": \"American Independent\", \"state\": \"Alabama\", \"priority\": 3, \"description\": \"

.

\", \"color_hex\": \"#A56B3B\", \"secondary_color_hex\": \"#CE854A\", \"is_active\": 0, \"image_url\": \"/static/images/george-wallace-1968.jpg\", \"electoral_victory_message\": \"

How? You somehow managed to win the 1968 election!

Everyone was expecting Nixon to win and while a Wallace victory was itself a longshot, a McCarthy victory was something absolutely no one was expecting. Good luck on your progressive agenda.

\", \"electoral_loss_message\": \"

As expected, you have lost the 1968 election.

But what did you expect, you’re a 3rd party candidate after all

The best you can do for now is continue to sound the call for civil rights in America and retain your seat in the senate. Perhaps you will have a better chance of making your voice heard in 1972.

\", \"no_electoral_majority_message\": \"

Wow! You somehow managed to deadlock the electoral college.

With a Democratically controlled House and senate, it’s either going to be you or Wallace.

Of course, you could also strike a deal with Nixon, making him president and you VP. Whatever happens, it's sure to be interesting.

\", \"description_as_running_mate\": \"null\", \"candidate_score\": 0.7}}, {\"model\": \"campaign_trail.candidate\", \"pk\": 57, \"fields\": {\"first_name\": \"Claude\", \"last_name\": \"Kirk\", \"election\": 4, \"party\": \"Republican\", \"state\": \"Florida\", \"priority\": 5, \"description\": \"\", \"color_hex\": \"#FF0000\", \"secondary_color_hex\": \"#FFA0A0\", \"is_active\": 0, \"image_url\": \"https://i.imgur.com/2AU1GiL.png\", \"electoral_victory_message\": \"

Congratulations! You have won the 1968 election!

George, you’ve done it! Lenore rushes to your side as the results roll in, and your victory is confirmed. Your children, smiles arrayed across their faces, congratulate you.

With your victory, you’re now poised to deliver peace in Vietnam, reform the Great Society, and chart America’s path through the waning years of the 60’s.\", \"electoral_loss_message\": \"

Sorry, you have lost the 1968 election.

Folks were hoping for a sharp reversal from the landslide of ‘64, but you just weren’t up for it. Republican pols are despondent that you lost such a favorable election, especially after Humphrey’s polling in the wake of the Chicago fiasco..

While you still have your remaining term as Governor to fill out, you promised your Lieutenant Governor that you would resign if you lost, and he seems keen to keep you to that promise. So long, George.

\", \"no_electoral_majority_message\": \"

Interestingly, no candidate was able to receive a majority of votes.

This is a calamity, though not of epic proportions.

You and Humphrey are sure to come to an accommodation based on whoever won the popular vote, and you both are committed to denying Wallace any leverage whatsoever. Unfortunately, whoever comes out on top is likely to have their political influence castrated by the whole affair. Let’s hope it’s you, George.

\", \"description_as_running_mate\": \"You're slumped in a chair, Hall in front of you. There's just one thing the two of you need to discuss.

'If we're going to win', Hall leans forward, 'we need to get serious. We need to be smart, George. Smart.'

You look him in the eye, and nod. Smart. Humphrey, or Johnson, or McCarthy -- whoever the hell the Democrats nominate... they'll be thinking smart too. They'll be ruthless, their pragmatism will lead them to do whatever they have to.

'Kirk? Kirk is smart. He was for you. He has ties, connections to conservatives. He looks good. Northerner, with a southerner. That looks good. His record? I've talked to him. Trust me, George, don't let the record speak for the man. He's smart. He's tactical. He's a good man.'

\", \"candidate_score\": 0.7}}, {\"model\": \"campaign_trail.candidate\", \"pk\": 65, \"fields\": {\"first_name\": \"Edward\", \"last_name\": \"Brooke\", \"election\": 4, \"party\": \"Republican\", \"state\": \"Massachusetts\", \"priority\": 8, \"description\": \"\", \"color_hex\": \"#FF0000\", \"secondary_color_hex\": \"#FFA0A0\", \"is_active\": 0, \"image_url\": \"https://i.imgur.com/Goo0wRp.png\", \"electoral_victory_message\": \"n/a\", \"electoral_loss_message\": \"n/a\", \"no_electoral_majority_message\": \"n/a\", \"description_as_running_mate\": \"Unavailable in first release. Loads previous version.

Leonard Hall cradles his head in his arms, distraught.

Romney has made up his mind on who he wants to join his ticket - perhaps the worst man electorally, second only to maybe John Ashbrook. Ed Brooke, that arrogant sonofabitch has decided. Hall liked Brooke - hell, he agreed with the guy on most things - but this move was a loser. They were going to lose, big. Humphrey - shit, even McCarthy, or the Kennedy stalking horse, McGovern, or the actual damned Kennedy, Ted - they could all beat Romney with Brooke thrusted on the ticket.

That wasn't even talking about the herculean feat of getting Brooke even on the ticket, and the rapture that'd cause in the party - but Romney has already made his mind, Hall has already tried convincing him otherwise, so the work must be done.\", \"candidate_score\": 0.0}}, {\"model\": \"campaign_trail.candidate\", \"pk\": 66, \"fields\": {\"first_name\": \"James\", \"last_name\": \"Gavin\", \"election\": 4, \"party\": \"Republican\", \"state\": \"New York\", \"priority\": 6, \"description\": \"ee\", \"color_hex\": \"#FF0000\", \"secondary_color_hex\": \"#FFA0A0\", \"is_active\": 0, \"image_url\": \"https://i.imgur.com/t5ZhTGw.png\", \"electoral_victory_message\": \"

Congratulations! You have won the 1968 election!

George, you’ve done it! Lenore rushes to your side as the results roll in, and your victory is confirmed. Your children, smiles arrayed across their faces, congratulate you.

With your victory, you’re now poised to deliver peace in Vietnam, reform the Great Society, and chart America’s path through the waning years of the 60’s.\", \"electoral_loss_message\": \"

Sorry, you have lost the 1968 election.

Folks were hoping for a sharp reversal from the landslide of ‘64, but you just weren’t up for it. Republican pols are despondent that you lost such a favorable election, especially after Humphrey’s polling in the wake of the Chicago fiasco..

While you still have your remaining term as Governor to fill out, you promised your Lieutenant Governor that you would resign if you lost, and he seems keen to keep you to that promise. So long, George.

\", \"no_electoral_majority_message\": \"

Interestingly, no candidate was able to receive a majority of votes.

This is a calamity, though not of epic proportions.

You and Humphrey are sure to come to an accommodation based on whoever won the popular vote, and you both are committed to denying Wallace any leverage whatsoever. Unfortunately, whoever comes out on top is likely to have their political influence castrated by the whole affair. Let’s hope it’s you, George.

\", \"description_as_running_mate\": \"Hall say's Kirk is a good man. Hall has been right many times this campaign, but Kirk's record... you remember him from the Governor's Conference. He seemed like a snake, a man who would ruthlessly try to climb to the top of the trash heap.

No, you said, he just wouldn't do. You needed someone respectable, with a strong record. Bipartisan, but not too out of the loop with the party. Someone you wanted to trust. Hall nodded. He knew you meant Gavin.

A general. Served in the War, while you were in Detroit. Helped racially integrate the military. Found a stint as the Ambassador to France under Kennedy, before he dropped that. Recently, he's been more consumed with opposition to the Vietnam War. Lowenstein tried to get him to run against Johnson in the primary, too, but Gavin said oh, well, no. Best look at the Republicans if you want to beat the President. Best look at you.

\", \"candidate_score\": 0.0}},{\"model\": \"campaign_trail.candidate\", \"pk\": 62, \"fields\": {\"first_name\": \"John\", \"last_name\": \"Connally\", \"election\": 4, \"party\": \"Democrat\", \"state\": \"Texas\", \"priority\": 37, \"description\": \"n/a\", \"color_hex\": \"#0000FF\", \"secondary_color_hex\": \"#90C0FF\", \"is_active\": 0, \"image_url\": \"../static/images/john-connally-1968.jpg\", \"electoral_victory_message\": \"n/a\", \"electoral_loss_message\": \"n/a\", \"no_electoral_majority_message\": \"n/a\", \"description_as_running_mate\": \"

Connally was and is the Governor of Texas who was infamously wounded in the Kennedy Assassination. He would reinforce a moderate image, help deliver Texas to the ticket, and dampen the appeal of Nixon elsewhere to all but the most hard-line Republicans.

However the anti-war, liberal wing of the party will surely recoil at this selection.

\", \"candidate_score\": 0.0}}, {\"model\": \"campaign_trail.candidate\", \"pk\": 58, \"fields\": {\"first_name\": \"George\", \"last_name\": \"McGovern\", \"election\": 4, \"party\": \"Progressive\", \"state\": \"South Dakota\", \"priority\": 33, \"description\": \"n/a\", \"color_hex\": \"#00C100\", \"secondary_color_hex\": \"#A1FFA1\", \"is_active\": 0, \"image_url\": \"https://upload.wikimedia.org/wikipedia/commons/thumb/a/a6/GeorgeStanleyMcGovern.jpg/220px-GeorgeStanleyMcGovern.jpg\", \"electoral_victory_message\": \"n/a\", \"electoral_loss_message\": \"n/a\", \"no_electoral_majority_message\": \"n/a\", \"description_as_running_mate\": \"

McGovern is a senator from South Dakota. He would reinforce a progressive image, which will help you win over disaffected progressives.

However, he won’t help you much with moderates.

\", \"candidate_score\": 0.0}}]"); campaignTrail_temp.running_mate_json = JSON.parse("[{\"model\": \"campaign_trail.running_mate\", \"pk\": 32, \"fields\": {\"candidate\": 23, \"running_mate\": 57}}, {\"model\": \"campaign_trail.running_mate\", \"pk\": 32, \"fields\": {\"candidate\": 23, \"running_mate\": 66}}, {\"model\": \"campaign_trail.running_mate\", \"pk\": 32, \"fields\": {\"candidate\": 23, \"running_mate\": 65}}, {\"model\": \"campaign_trail.running_mate\", \"pk\": 37, \"fields\": {\"candidate\": 25, \"running_mate\": 62}}, {\"model\": \"campaign_trail.running_mate\", \"pk\": 33, \"fields\": {\"candidate\": 24, \"running_mate\": 58}}]"); campaignTrail_temp.opponents_default_json = JSON.parse("[{\"election\": 4, \"candidates\": [ 24, 25]}]"); campaignTrail_temp.opponents_weighted_json = JSON.parse("[{\"election\": 4, \"candidates\": [23, 24, 25]}]"); campaignTrail_temp.temp_election_list = [{"id": 4, "year": 1968, "is_premium": 0, "display_year": "1968Romney"}]; nextBrooke = () => { $("#brooke_cont").html(`This is a bit of an experiment on my part - I wanted to go hog-wild with CYOA, and so I did. In this mod, you are able to play as an entirely different candidate - that was cool, and so I decided to use CYOA to also decide the second-to-last CYOA question, determined by a series of answers you might've chosen throughout for Brooke. The code for that was gracefully lifted from 1972TNOHall, which is currently not yet out, made by Aero, a good friend of mine who's been great w/ playtesting. There are 3 different variants of the second-to-final question, and one I feel I ought to address is the drop-out one. It's a bit silly, yes, but I don't particularly care. Hope you had fun! (And I do plan to use the candidate swap/fakeout again in the future. It'll be big in 1972R!)

One last thing - chalk IN and OH being so Romney-unfriendly with Brooke to Wallace siphoning votes, to Republican turnout being decreased, etc. It's a bit silly, but this is a ticket with a Black man in the 60s.

`) } backBrooke = () => { $("#brooke_cont").html(`

Leonard Hall cradles his head in his arms, distraught.

Romney has made up his mind on who he wants to join his ticket - perhaps the worst man electorally, second only to maybe John Ashbrook. Ed Brooke, that arrogant sonofabitch has decided. Hall liked Brooke - hell, he agreed with the guy on most things - but this move was a loser. They were going to lose, big. Humphrey - shit, even McCarthy, or the Kennedy stalking horse, McGovern, or the actual damned Kennedy, Ted - they could all beat Romney with Brooke thrusted on the ticket.

That wasn't even talking about the herculean feat of getting Brooke even on the ticket, and the rapture that'd cause in the party - but Romney has already made his mind, Hall has already tried convincing him otherwise, so the work must be done.

`) } quotes = ["Too Right, Too Soon"] customquote = quotes[Math.floor((Math.random() * quotes.length))] corrr=`\n

NEW CAMPAIGN TRAIL

`+customquote+`` nct_stuff.themes[nct_stuff.selectedTheme].coloring_window = "#6975B2" nct_stuff.themes[nct_stuff.selectedTheme].coloring_title = "#6975B2" $(".container")[0].style.backgroundColor = "#6975B2" $("#game_window")[0].style.backgroundImage = "url(https://i.imgur.com/YwpX3sE.png)" $("#game_window")[0].style.borderColor = "#803720" $("#game_window")[0].style.coloring_window = "#803720" document.body.background = "https://i.imgur.com/aaz6AaW.jpg" document.getElementById("header").src = "https://i.imgur.com/VsvT7k2.jpg" document.getElementById("wittyquote").color = "white" nct_stuff.themes[nct_stuff.selectedTheme].text_col = "black" campaignTrail_temp.credits = ""; RecReading=true // MUSIC MODE musicMode = () => { // Initialise custom music $("#music_player")[0].children[0].style.display = "none" $("#music_player")[0].children[1].style.display = "none" document.getElementById("modLoadReveal").style.display = "none" document.getElementById("modloaddiv").style.display = "none" musicBox = document.getElementById("music_player") musicBox.style.display = "" var trackSel; e = campaignTrail_temp e.selectedSoundtrack = 0 toTime = (seconds) => { var date = new Date(null); date.setSeconds(seconds); return date.toISOString().substr(11, 8); } generateTime = () => { // Get the audio element var audio = document.getElementById("campaigntrailmusic"); timeTracker = document.createElement("div"); timeTracker.style = ` text-align:left; border-style:solid; border-width:3px; height:150px; width:200px; background-color:#999999; float:right; padding: 10px; ` $("#trackSelParent")[0].prepend(timeTracker); $("#trackSelParent")[0].prepend(document.createElement("br")); // Create a new element to display the current position of the audio var positionDisplay = document.createElement("gg"); positionDisplay.id = "position-display"; // Create a new slider element to change the time var timeSlider = document.createElement("input"); timeSlider.type = "range"; timeSlider.min = 0; timeSlider.max = 1; timeSlider.step = 0.001; timeSlider.value = 0; timeSlider.style.width = "200px"; timeSlider.id = "time-slider"; var pausePlay = document.createElement("button"); pausePlay.id = "position-display"; pausePlay.innerHTML = "Pause" pausePlay.style.width = "100%"; pausePlay.addEventListener("click", event => { event.preventDefault(); updatePositionDisplay(); let audio = document.getElementById("campaigntrailmusic"); if (audio.paused) { audio.play(); event.target.innerHTML = "Pause"; return; } audio.pause(); event.target.innerHTML = "Play"; return; }) var volumeLabel = document.createElement("gg"); volumeLabel.id = "volume-label"; volumeLabel.innerHTML = "
Volume: " var volumeSlider = document.createElement("input"); volumeSlider.type = "range"; volumeSlider.min = 0; volumeSlider.max = 1; volumeSlider.step = 0.001; volumeSlider.value = 0; volumeSlider.style.width = "200px"; volumeSlider.id = "volume-slider"; volumeSlider.value = audio.volume; timeTracker.appendChild(pausePlay); timeTracker.appendChild(document.createElement("br")); timeTracker.appendChild(document.createElement("br")); timeTracker.appendChild(positionDisplay); timeTracker.appendChild(timeSlider); timeTracker.appendChild(volumeLabel); timeTracker.appendChild(volumeSlider); updatePositionDisplay(); //for (let i = 0; i < 10; i++) //timeTracker.append(document.createElement("br")); // Function to update the position display function updatePositionDisplay() { positionDisplay.innerHTML = "Time: " + toTime(audio.currentTime) + "
"; timeSlider.value = audio.duration ? audio.currentTime / audio.duration : 0; } // Function to change the time of the audio function changeTime() { positionDisplay.innerHTML = "Time: " + toTime(audio.currentTime) + "
"; audio.currentTime = timeSlider.value * audio.duration; } updateVolume = event => { audio.volume = event.target.value; } // Update the position display and slider every second setInterval(updatePositionDisplay, 1000); // Listen for changes to the time slider and change the time of the audio timeSlider.addEventListener("input", changeTime); volumeSlider.addEventListener("input", updateVolume) } function newMusicPlayer() { trackSel = document.createElement("div"); trackSel.id = "trackSelParent" let z = `









` z += `

` //
for (i in soundtracks[e.selectedSoundtrack].tracklist) { let a = soundtracks[e.selectedSoundtrack].tracklist[i] let b = `
` z += b } z += "


" trackSel.innerHTML = z // select correct song musicBox.appendChild(trackSel); Array.from(document.getElementById("trackSel").children).filter(f => { return f.tagName == "LABEL" }).map(f => f.children[0])[0].checked = true // set soundtrack changer soundtrackSelector = document.getElementById("selectSoundtrack") soundtrackSelector.onchange = function() { for (i in soundtracks) { if (soundtracks[i].name == soundtrackSelector.value) { e.selectedSoundtrack = i break } } document.getElementById("trackSelParent").remove() newMusicPlayer() } var matches = document.querySelectorAll('.trackSelector'); for (match in matches) { matches[match].onchange = function() { audio = $("#campaigntrailmusic")[0]; audio.src = soundtracks[e.selectedSoundtrack].tracklist[this.value].url audio.currentTime = 0 } } musicBox.children[2].loop = false musicBox.children[2].src = soundtracks[e.selectedSoundtrack].tracklist[0].url musicBox.children[2].onended = function() { console.log("next track") let selected = Number(document.querySelector('input[name="trackSelector"]:checked').value); let newSel = clamp(selected + 1, soundtracks[e.selectedSoundtrack].tracklist.length - 1, 0) let buttons = Array.from(document.getElementById("trackSel").children).filter(f => { return f.tagName == "LABEL" }).map(f => f.children[0]) //let selectedIndex = buttons.map(f=>f.children[0]).map(f=>f.checked) buttons[newSel].click() } for (w = 0; w < 7; w++) { document.getElementById("trackSelParent").appendChild(document.createElement("br")) } generateTime(); } clamp = function(a, max, min, overflow = true) { if (overflow) { return a > max ? min : a < min ? max : a; } return a > max ? max : a < min ? min : a; } // Track list var soundtracks = { 0: { name: "Opening Song", tracklist: [ { "name": "Generique - Alain Goraguer", "url": "https://audio.jukehost.co.uk/XMljnGRb1NZ1PWjP7isdZWsrkaSlPsVM" } ] }, 1: { name: "Republican Orthodoxy", tracklist: [ { "name": "Happy Times - Burt Weedon", "url": "https://audio.jukehost.co.uk/N5hzUUZTS8X4gqNua3ItKz02aM6qEA2o" }, { "name": "Blue Moon - Frank Sinatra", "url": "https://audio.jukehost.co.uk/kbIFjMHML0WpxRRFXLjV0SiCPqsx9K9g" }, { "name": "Ring of Fire - Johnny Cash", "url": "https://audio.jukehost.co.uk/cTokgu4Ss3I8HL7p3aXflp4Vxa951ndr" }, { "name": "My Way - Frank Sinatra", "url": "https://audio.jukehost.co.uk/08FT2QT4he0k3dRah8wrtG1dul2HDrKX" } ] }, 2: { name: "Romney’s Way", tracklist: [ { "name": "Le Bracelet - Alain Goraguer", "url": "https://audio.jukehost.co.uk/IZyuCz7g8jj40ntO12kPrvPwKx2xXA6b" }, { "name": "Peaches En Regalia - Frank Zappa", "url": "https://audio.jukehost.co.uk/afx89wv30KIBfXFHXptEFNTNniXDzX7a" }, { "name": "Lonesome Traveler - Ray Bryant", "url": "https://audio.jukehost.co.uk/jp7sCZw1irRWh09NDr0SauziyeWAKL9u" }, { "name": "Love, Peace, and Happiness - The Chambers Brothers", "url": "https://audio.jukehost.co.uk/cMHFCK0EFmjSYAptORXRKqERpeugEBmJ" }, { "name": "The Ballad of the Green Berets - SSgt. Bary Sadler", "url": "https://audio.jukehost.co.uk/kCIDrpkiqqqtgQimLvaMOVa57KPSf9MK" } ] } } // Set up new music player newMusicPlayer() } $("#game_start").click((event) => { event.preventDefault(); $("#election_id_button").click((event) => { musicMode() setInterval(changeFontColour, 200) }) }) $("#game_start").click((event) => { event.preventDefault(); $("#election_id_button").click((event) => { musicMode() setInterval(changeFontColour, 200) }) }) campaignTrail_temp.credits = "Obummer, with help from QuoProQuid, ettingermentum, mango, rmngaming, River, and Neo" campaignTrail_temp.achievements = { "Brainwashed
⠀" : { "image" : "", "description" : "Take a Trip to Vietnam", "cannotBeCheated" : true }, "Saint George
⠀" : { "image" : "", "description" : "Stay True.", "cannotBeCheated" : true }, "... of Lydda" : { "image" : "", "description" : "Align Yourself with the Warmongers, and Win", "cannotBeCheated" : true }, "Laman
⠀" : { "image" : "", "description" : "Betray it All, and Win", "cannotBeCheated" : true }, "Yes, Mr. Vice President
⠀" : { "image" : "", "description" : "What Happened to your Independence?", "cannotBeCheated" : true }, "In Control" : { "image" : "", "description" : "Win the Reallignment", "cannotBeCheated" : true }, "Pitch Perfect
⠀" : { "image" : "", "description" : "Made in a Lab", "cannotBeCheated" : true }, "His Republican Party" : { "image" : "https://www.thirteen.org/wnet/historyofus/web15/features/see_it_now/images/1960.0558.jpg", "description" : "What Letters?", "cannotBeCheated" : true }, "Proselytize
⠀" : { "image" : "", "description" : "Convert the Masses on National Television", "cannotBeCheated" : true }, "Wash Away the Credibility Gap" : { "image" : "", "description" : "Take a Trip, and win", "cannotBeCheated" : true } }