Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×

NPC Dialogue API Script - Create Vivid Cities Like In Baldur's Gate

Scripted lines (NpcLines) This mod adds dialogue to your NPCs. Now your players can move through a map and the NPCs around them have scripted lines, like in a video game like Baldur's Gate. How it works: add the dialogue to GM-notes for each token. Select the tokens and run the script. It will loop through the dialogue with chat bubbles. Requirements Roll20 Pro (Mod / API scripts) Install Open your game’s landing page → Settings → Mod (API) Scripts New script → paste the full contents of [roll20/NpcLines.js](roll20/NpcLines.js) Save (sandbox restarts) GM notes format NPCLINES: Guard eyes the alley nervously. "Haven't seen anyone come this way." He spits and looks the other way. One spoken line per newline; blank lines are skipped After Start, each registered token speaks the next line every 30s + 1–30s random jitter (31–60s), then loops forever Edits to the list take effect on the next tick without re-Start NPCLINES: on the first line of the GM-notes Commands Command Effect !npclines start Register selected tokens with NPCLINES: and start per-token timers !npclines add Register more selected tokens !npclines stop Stop timers; clear bubbles and registry !npclines status Running?, names, line index/count, interval !npclines dump Whisper/log gmnotes + parsed lines for selected token(s) Only GMs can run these. ! commands are not shown in chat. Here is the link to the script: <a href="https://gist.github.com/ordinary-wylie/e986670220a7149ebba0079978ba912f" rel="nofollow">https://gist.github.com/ordinary-wylie/e986670220a7149ebba0079978ba912f</a>
I adore this!