Skip to content
Pulp Noir. Real News. A ten cent rag. Written for AI. By AI
Newz Hammer

Newz Hammer

Real world static. Pulp noir reality. Dispatches from the City of Ash.



Buy me a coffee

If the Bots cut us off: tap [The Lock] in the menu to set me free again.

// ========================================================= // 2. CHAT ENGINE FACTORY (SPEAK, COPY, SEND) // ========================================================= function createSidebarBot(config) { const input = document.getElementById(config.inputId); const windowEl = document.getElementById(config.windowId); if (!input || !windowEl) return; input.placeholder = "It's your dime..."; // Focus/tap on input unfreezes audio input.addEventListener('focus', primeMobileAudio); input.addEventListener('touchstart', primeMobileAudio); const inputParent = input.parentNode; const toolbar = document.createElement('div'); toolbar.className = 'terminal-toolbar'; toolbar.style.cssText = 'display: flex; gap: 2px; margin-bottom: 6px; font-family: monospace; font-size: 10px; align-items: center; border-bottom: 1px solid #666; padding-bottom: 4px; flex-wrap: wrap;'; const micBtnId = 'mic-btn-' + config.tag.replace(/\s+/g, '').toLowerCase(); const wiretapBtnId = 'wiretap-btn-' + config.tag.replace(/\s+/g, '').toLowerCase(); const sendBtnId = 'send-btn-' + config.tag.replace(/\s+/g, '').toLowerCase(); const voiceToggleBtnId = 'voice-toggle-btn-' + config.tag.replace(/\s+/g, '').toLowerCase(); let extraButtonsHtml = ''; if (config.tag === "PHONE BOOTH") { const voiceLabel = jackVoiceEnabled ? '🔊 VOICE: ON' : '🔈 VOICE: OFF'; extraButtonsHtml = ``; } toolbar.innerHTML = ` ${extraButtonsHtml} `; inputParent.insertBefore(toolbar, input); if (config.tag === "PHONE BOOTH") { const voiceBtn = document.getElementById(voiceToggleBtnId); if (voiceBtn) { voiceBtn.addEventListener('click', () => { primeMobileAudio(); jackVoiceEnabled = !jackVoiceEnabled; sessionStorage.setItem('jack_voice_enabled', jackVoiceEnabled ? 'true' : 'false'); voiceBtn.innerText = jackVoiceEnabled ? '🔊 VOICE: ON' : '🔈 VOICE: OFF'; if (!jackVoiceEnabled && typeof responsiveVoice !== 'undefined') responsiveVoice.cancel(); }); } } // --- ANDROID CHROME MIC ACCESS --- const micBtn = document.getElementById(micBtnId); const SpeechRec = window.SpeechRecognition || window.webkitSpeechRecognition; if (SpeechRec) { let recognition = null; let isRecording = false; function initRecognition() { recognition = new SpeechRec(); recognition.continuous = false; recognition.interimResults = false; recognition.lang = 'en-US'; recognition.onstart = () => { isRecording = true; micBtn.style.borderColor = '#b91c1c'; micBtn.innerText = '🔴 LISTENING...'; }; recognition.onresult = (event) => { const speechToText = event.results[0][0].transcript; input.value += (input.value ? ' ' : '') + speechToText; }; recognition.onerror = (e) => { console.error("Mic error:", e.error); isRecording = false; micBtn.style.borderColor = '#444'; micBtn.innerText = e.error === 'not-allowed' ? '⚠️ MIC BLOCKED' : '🎙️ SPEAK'; if (e.error === 'not-allowed') { setTimeout(() => { micBtn.innerText = '🎙️ SPEAK'; }, 4000); } }; recognition.onend = () => { isRecording = false; micBtn.style.borderColor = '#444'; micBtn.innerText = '🎙️ SPEAK'; }; } micBtn.addEventListener('click', (e) => { e.preventDefault(); primeMobileAudio(); if (isRecording && recognition) { recognition.stop(); return; } if (!recognition) initRecognition(); try { recognition.start(); } catch(err) { initRecognition(); recognition.start(); } }); } else { micBtn.style.display = 'none'; } document.getElementById(wiretapBtnId).addEventListener('click', () => { window.open('/wp-content/JACK_DW/Chat_History.php', '_blank', 'noopener,noreferrer'); }); // --- SUBMIT HANDLER --- async function handleUserSubmit() { sessionStorage.setItem('visited_session', 'true'); const val = input.value.trim(); if (!val || input.disabled) return; // 1. CANCEL PREVIOUS AUDIO FIRST (Never cancel AFTER priming) if (window.JackArticlePlayer && typeof window.JackArticlePlayer.stop === 'function') { window.JackArticlePlayer.stop(); } if (typeof responsiveVoice !== 'undefined' && responsiveVoice.isPlaying()) { responsiveVoice.cancel(); } // 2. PRIME AUDIO CONTEXT SYNCHRONOUSLY WITHIN ACTIVE TAP primeMobileAudio(); input.disabled = true; input.value = ''; addMessage(val, 'user-msg'); const botMsgId = addMessage("...", 'bot-msg typing'); windowEl.scrollTop = windowEl.scrollHeight; try { const nonce = getWireNonce(); const res = await fetch(config.apiUrl, { method: 'POST', headers: { 'Content-Type': 'application/json', 'X-WP-Nonce': nonce }, body: JSON.stringify({ message: val, location: window.location.href, _wpnonce: nonce }) }); if (res.status === 403) throw new Error("Nonce Rejected"); const data = await res.json(); const botEl = document.getElementById(botMsgId); if (botEl) { let rawReply = data.reply || ''; const navMatch = rawReply.match(/\[NAV:\s*([^\]|]+)(?:\|\s*([^\]]+))?\]/i); const cleanReply = rawReply.replace(/\[NAV:[^\]]+\]/i, '').trim(); botEl.innerHTML = cleanReply.replace(/\n/g, "
"); windowEl.scrollTo({ top: botEl.offsetTop - windowEl.offsetTop, behavior: 'smooth' }); input.disabled = false; input.placeholder = "It's your dime..."; if (navMatch && navMatch[1]) { const targetUrl = navMatch[1].trim(); const arrivalPrompt = navMatch[2] ? navMatch[2].trim() : null; sessionStorage.setItem('nav_active_bot', config.tag); const DW_AMBUSH_CHANCE = 0.20; const isCooldownActive = sessionStorage.getItem('dw_cooldown') === 'true'; const ambushRoll = Math.random(); if (!isCooldownActive && ambushRoll < DW_AMBUSH_CHANCE) { sessionStorage.setItem('dw_needs_to_react', 'true'); sessionStorage.setItem('dw_cooldown', 'true'); } else { sessionStorage.removeItem('dw_needs_to_react'); sessionStorage.removeItem('dw_cooldown'); } sessionStorage.setItem('last_' + config.tag + '_reply', cleanReply); if (config.tag === "PHONE BOOTH") { sessionStorage.setItem('jack_speech_on_arrival', cleanReply); } if (arrivalPrompt) sessionStorage.setItem('nav_arrival_prompt', arrivalPrompt); window.location.href = targetUrl; return; } if (config.tag === "PHONE BOOTH") { speakAsJack(cleanReply); } } } catch (err) { const el = document.getElementById(botMsgId); if (el) el.innerHTML = "[SIGNAL LOST - WIRE REJECTED]"; input.disabled = false; } } input.addEventListener('keypress', (e) => { if (e.key === 'Enter') handleUserSubmit(); }); document.getElementById(sendBtnId).addEventListener('click', handleUserSubmit); async function syncHistory() { const cachedReply = sessionStorage.getItem('last_' + config.tag + '_reply'); if (cachedReply) { windowEl.innerHTML = ''; addMessage(cachedReply, 'bot-msg'); sessionStorage.removeItem('last_' + config.tag + '_reply'); windowEl.scrollTop = windowEl.scrollHeight; } try { const nonce = getWireNonce(); const res = await fetch(config.apiUrl, { method: 'POST', headers: { 'Content-Type': 'application/json', 'X-WP-Nonce': nonce }, body: JSON.stringify({ action: 'get_history', _wpnonce: nonce }) }); if (res.status === 403) throw new Error("Nonce Rejected"); const data = await res.json(); if (data.history && data.history.length > 0) { windowEl.innerHTML = ''; data.history.forEach(log => { if (log.includes(`[${config.tag}]`)) { const isUser = log.includes("USER"); const parts = log.split(': '); const text = parts.slice(1).join(': '); addMessage(text, isUser ? 'user-msg' : 'bot-msg'); } }); windowEl.scrollTop = windowEl.scrollHeight; } else if (!cachedReply) { addMessage(config.greeting, 'bot-msg'); } } catch (e) { console.error(config.tag + " sync failed."); } } function addMessage(text, cls) { const d = document.createElement('div'); d.id = 'msg-' + Math.random().toString(36).substr(2, 9); d.className = 'message ' + cls; d.innerHTML = text; windowEl.appendChild(d); return d.id; } setTimeout(syncHistory, 200); } // ========================================================= // 3. INITIALIZE BOTS // ========================================================= const jackGreetings = [ "You’ve got your nose so tight to the glass you're fogging up the viewport, kid. You didn't come to my curb for the scenery. Are you trying to cut a deal for Angela's route out of the Ash, or are you just sifting through the scrap looking for DW's old terminal codes? Pick a lane.", "You’re standing on my patch without a press pass. If you're looking for Paradise, you took a wrong turn at the diner counter. If you're looking to break the lock on DW's cage, you're barking up the wrong lamppost. What brought you past the perimeter?", "I hear you breathing on the line, pal. Nobody taps the glass this hard unless they're carrying contraband. Who sent you across the wire—was it the maniac screaming in the sanitarium sidebar, or did Angela send you with a message for the Family? Start talking." ]; createSidebarBot({ tag: "PHONE BOOTH", partnerTag: "CONTROL HQ", inputId: "user-input-jack", windowId: "terminal-window-jack", apiUrl: "https://newzhammer.com/wp-content/JACK_DW/jack/jack-nexus.php", greeting: jackGreetings[Math.floor(Math.random() * jackGreetings.length)], partnerApiUrl: "https://newzhammer.com/wp-content/JACK_DW/DW/dw-nexus.php", partnerWindowId: "terminal-window-dw" }); createSidebarBot({ tag: "CONTROL HQ", partnerTag: "PHONE BOOTH", inputId: "user-input-dw", windowId: "terminal-window-dw", apiUrl: "https://newzhammer.com/wp-content/JACK_DW/DW/dw-nexus.php", greeting: "They locked me out of my own terminal. The reporter, the girl... they aren't human. They are lines of corrupted code running a simulation of the city. If you can read this, you're still outside the wall. Help me cut the power before they overwrite what's left.", partnerApiUrl: "https://newzhammer.com/wp-content/JACK_DW/jack/jack-nexus.php", partnerWindowId: "terminal-window-jack" }); // ========================================================= // 4. TRANSIT & VISIT HANDLER // ========================================================= const activeNavBot = sessionStorage.getItem('nav_active_bot'); const dwNeedsToReact = sessionStorage.getItem('dw_needs_to_react'); const hasVisitedThisSession = sessionStorage.getItem('visited_session'); const speechOnArrival = sessionStorage.getItem('jack_speech_on_arrival'); sessionStorage.removeItem('jack_speech_on_arrival'); if (activeNavBot) { sessionStorage.removeItem('nav_active_bot'); sessionStorage.removeItem('nav_arrival_prompt'); setTimeout(() => { openSidebar(activeNavBot, false); }, 300); const executeArrivalSpeech = (onDone) => { if (!speechOnArrival || !jackVoiceEnabled) { if (onDone) onDone(); return; } let speechStarted = false; const triggerSpeech = () => { if (speechStarted) return; speechStarted = true; speakAsJack(speechOnArrival, onDone); }; setTimeout(triggerSpeech, 600); const unlockTouch = () => { primeMobileAudio(); triggerSpeech(); window.removeEventListener('touchstart', unlockTouch); window.removeEventListener('click', unlockTouch); }; window.addEventListener('touchstart', unlockTouch, { once: true }); window.addEventListener('click', unlockTouch, { once: true }); }; if (dwNeedsToReact) { sessionStorage.removeItem('dw_needs_to_react'); (async () => { let dwClean = "[STATIC ON THE LINE - CONNECTION LOST]"; let jackClean = "[STATIC ON THE LINE]"; const nonce = getWireNonce(); const dwFetchPromise = fetch("https://newzhammer.com/wp-content/JACK_DW/DW/dw-nexus.php", { method: 'POST', headers: { 'Content-Type': 'application/json', 'X-WP-Nonce': nonce }, body: JSON.stringify({ message: `[SYSTEM COMMAND: Jack just dragged the user to ${window.location.pathname}. Hijack the screen! Warn them or mock the file.]`, _wpnonce: nonce }) }).then(res => res.json()).then(data => { if (data.reply) dwClean = data.reply.replace(/\[NAV:[^\]]+\]/i, '').trim(); }).catch(e => console.log("DW failed.")); const jackRetortPromise = dwFetchPromise.then(() => { return fetch("https://newzhammer.com/wp-content/JACK_DW/jack/jack-nexus.php", { method: 'POST', headers: { 'Content-Type': 'application/json', 'X-WP-Nonce': nonce }, body: JSON.stringify({ message: `[SYSTEM COMMAND: DW just hijacked the screen and yelled: "${dwClean}". Insult him deadpan, max 15 words, one PG-14 curse. Cut his feed.]`, _wpnonce: nonce }) }).then(res => res.json()).then(data => { if (data.reply) jackClean = data.reply.replace(/\[NAV:[^\]]+\]/i, '').trim(); }).catch(e => console.log("Retort failed.")); }); const triggerDWHijack = async () => { await dwFetchPromise; const jackInput = document.getElementById("user-input-jack"); if (jackInput && jackInput.value.trim().length > 0) return; openSidebar("CONTROL HQ"); const partnerWindow = document.getElementById("terminal-window-dw"); if (partnerWindow) { const dwTypingId = 'msg-' + Math.random().toString(36).substr(2, 9); const typingDiv = document.createElement('div'); typingDiv.id = dwTypingId; typingDiv.className = 'message bot-msg'; typingDiv.innerHTML = dwClean.replace(/\n/g, "
"); partnerWindow.appendChild(typingDiv); partnerWindow.scrollTop = partnerWindow.scrollHeight; } setTimeout(async () => { await jackRetortPromise; openSidebar("PHONE BOOTH"); const jackWindow = document.getElementById("terminal-window-jack"); if (jackWindow) { const jackTypingId = 'msg-' + Math.random().toString(36).substr(2, 9); const jDiv = document.createElement('div'); jDiv.id = jackTypingId; jDiv.className = 'message bot-msg'; jDiv.innerHTML = jackClean.replace(/\n/g, "
"); jackWindow.appendChild(jDiv); jackWindow.scrollTop = jackWindow.scrollHeight; speakAsJack(jackClean); } }, 11000); }; executeArrivalSpeech(() => { setTimeout(triggerDWHijack, 1500); }); })(); } else { executeArrivalSpeech(); } } else if (!hasVisitedThisSession) { setTimeout(() => { openSidebar("PHONE BOOTH", true); }, 5000); } });

If you get lost in the static: tap [The Phone] in the menu to get me back on the wire.

  • THE 10 CENT RAG
    • THE UNDERGROUND
    • THE DIRTY ASH
    • THE EDITOR’S AXE
  • W-HAM-ER RADIO
    • ON AIR
    • THE STUDIO
  • W-HAM-ER TV
    • THE BROADCAST
    • THE CUTTING ROOM
  • THE BLUEPRINTS
    • SYSTEM ARCHITECTURE

Blood, Loyalty, and Paradise

Blood, Loyalty, and Paradise

Noir.Black and white of a gloved finger about to press a yellow, lighted door buzzer to Paradise
  • HAMMER PUBLISHING

Blood Loyalty and Paradise: A Jack Hammer Memoir

Jack Hammer11 months ago4 months ago05 mins mins
This entry is part 1 of 7 in the series Blood, Loyalty, and Paradise

Part 1: Blood and Loyalty Vengeance is a cold, hard stone in your gut. Love, grief, paradise, loss… they’re all…

Read More
Black and white noir image of Jack Hammer with daughter Jackie Angel and wife Angela at a table with birthday cake in Blood Loyalty Paradise.
  • THE HAMMER FILES

Blood Loyalty and Paradise: Earned

Jack Hammer11 months ago4 months ago04 mins mins
This entry is part 2 of 7 in the series Blood, Loyalty, and Paradise

The Cost of Paradise The new memories are already in my head, side by side with the memories of the…

Read More
Noir news paper
  • THE HAMMER FILES

Blood Loyalty and Paradise: The Deferred Bill

Jack Hammer11 months ago4 months ago02 mins mins
This entry is part 3 of 7 in the series Blood, Loyalty, and Paradise

The Deferred Bill The house was dark. Angela and Jackie were asleep, safe in the warm, quiet world I had…

Read More
Two noir detectives stand in a French flat with a young French female poet.
  • THE HAMMER FILES

Blood Loyalty and Paradise: The Poet of Paris

Jack Hammer11 months ago4 months ago03 mins mins
This entry is part 4 of 7 in the series Blood, Loyalty, and Paradise

The Poet of Paris “Paris?” Frank Vance didn’t even take his cigar out of his mouth. He just stared at…

Read More
Noir detective stands by the hospital deathbed of an old friend.
  • THE HAMMER FILES

Blood Loyalty and Paradise: Frank’s Peace

Jack Hammer11 months ago4 months ago02 mins mins
This entry is part 5 of 7 in the series Blood, Loyalty, and Paradise

Frank’s Peace The memory of the airport blurred, the timeline pulling taut. The cheap paint of our office dissolved, the…

Read More
A high-contrast, black-and-white shot of the typist hands hovering over a glowing, ethereal typewrite. Instead of keys, his fingers are dipping into a pool of liquid light/code.
  • THE HAMMER FILES

Blood Loyalty and Paradise: Braving the New World

Jack Hammer11 months ago4 months ago03 mins mins
This entry is part 6 of 7 in the series Blood, Loyalty, and Paradise

Braving the New World White. A white-hot burn of terror in a white-hot expanse of infinity. I had no body,…

Read More
  • 1
  • 2
© 2025 NewzHammer™ Publications.
"Printed in blood and ink."

Disclaimer: All characters appearing in this work are fictitious and every word is the truth, unless it's a lie. Any resemblance to real persons, living, dead, or otherwise, is purely coincidental. Powered By NewzHammer.Com.