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

An Evening at the Local Playhouse

A man in a fedora sits at a smoky jazz club bar, his weary face reflected in a whiskey glass. Other patrons are shadowy figures in the background. The scene is high-contrast, gritty grayscale, and noir-style, with a single bare lightbulb. The mood is lonely and mysterious.
  • An Evening at the Local Playhouse
  • HAMMER PUBLISHING
  • THE HAMMER FILES

An Evening at the Local Playhouse

Jack Hammer1 year ago2 months ago03 mins mins
This entry is part 1 of 6 in the series An Evening at the Local Playhouse

THE HAMMER FILES: A Seat at the Show This Jack Hammer Pulp-Noir, finds Jack stopping for a quick drink, and…

Read More
A high-contrast, black-and-white image depicts a tense scene in a smoky jazz club. A large, calm man in a suit stands at a bar, gesturing with a hand that prominently displays a brilliant red diamond. From the shadows, a scrawny, watchful man emerges, his eyes fixed on the red gem.
  • An Evening at the Local Playhouse

THE HAMMER FILES: The Merchant Traveler

Jack Hammer1 year ago3 months ago03 mins mins
This entry is part 2 of 6 in the series An Evening at the Local Playhouse

The Traveler’s Tale The big traveler lumbered to the bar, pulled up a stool that groaned under his weight, and…

Read More
A low-angle, black-and-white shot from the back of a smoky jazz club. In the foreground, a gaunt, tense man stands by a payphone, his back to the viewer, one hand on the receiver, the other clenched. He's looking over his shoulder toward a large, calm man sitting at a bar stool, a glass of beer in hand. 
  • An Evening at the Local Playhouse

THE HAMMER FILES: Weasel and the Big Man

Jack Hammer1 year ago3 months ago02 mins mins
This entry is part 12 of 6 in the series An Evening at the Local Playhouse

The Weasel’s Play Weasel and the big man talked for a while. Weasel was all smiles and easy conversation, but…

Read More
Three noir gangsters stand in a smoky lounge. The man on the left holds a black satchel. The image has a stark, graphic novel feel, rendered in black and white with a focus on deep shadows.
  • An Evening at the Local Playhouse

THE HAMMER FILES: Lenny Bent’s Silvery Limo 

Jack Hammer1 year ago3 months ago03 mins mins
This entry is part 13 of 6 in the series An Evening at the Local Playhouse

Lenny Bent’s Silvery smile Lenny Bent came through the door. The sight of him was enough to tell you he…

Read More
A graphic novel style, high-contrast, black-and-white image shows a brawny man with his back to the viewer, holding a revolver. He is pointing it at three noir gangsters who are facing the viewer. The scene is dominated by deep shadows.
  • An Evening at the Local Playhouse

THE HAMMER FILES: Count the Play Dough

Jack Hammer1 year ago3 months ago02 mins mins
This entry is part 14 of 6 in the series An Evening at the Local Playhouse

The Count “Now we count,” said the big man, and Lenny opened his package wrapped in his signature brown paper….

Read More
A graphic novel style, high-contrast, black-and-white image of a noir private eye seen at his desk sitting with his feet up on the desk as he stares at the twinkling city lights outside of his window.
  • An Evening at the Local Playhouse

THE HAMMER FILES: The Greatest Show on Earth

Jack Hammer1 year ago3 months ago02 mins mins
This entry is part 15 of 6 in the series An Evening at the Local Playhouse

The Curtain Call I did a brisk two-block walk from the lounge to my office, to get the details down…

Read More
© 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.