小说与文学2019inklestudios.com
用 Ink 编写基于网络的互动小说
Writing web-based interactive fiction with Ink
导读
这篇是 Inkle 工作室的 Ink 网页教程:Ink 是一种纯文本的标记语言,用来写《80 Days》那类分支互动小说,写完后可以导出到网页或游戏引擎里运行。对写作者来说,它把“讲故事”变成可以像代码一样版本管理和迭代的文本,也逼你显式设计选择与状态。下面的讨论既有工具对比,也有一个关于分支变量会让文本成倍膨胀的真实教训。
可以直接用的写作要点
- 01
用纯文本标记而不是富文本编辑器写分支故事,改一个变量名或一段台词可以全局生效,也方便用 Git 做版本管理和多人协作。
- 02
慎用“发色”这类只影响措辞的外观变量:每多一个取值,所有引用它的段落都要重复生成一遍,篇幅会按组合数成倍膨胀。
- 03
先在 Twine 这类图形化工具里把分支画成地图、理清骨架,再迁移到 Ink 这类文本工具里打磨句子,比一上来就写标记更省力。
- 04
动笔前先列出故事里的状态变量(读者选了什么、知道了什么),并明确每个选择改变哪个变量;这是交互叙事结构设计的核心工作。
HN 评论精选
变量替换会让文本按取值组合膨胀成数倍页数:设计分支时要意识到这种组合增长(这条评论也顺带讲了有人借此套利平台按页计费)。
我认识一个人靠给 Kindle 商店写情色小说为生,试过用 inklewriter 做 CYOA(自选冒险)式互动故事。给慈善机构小额捐款后,inklewriter 的开发者会帮他把故事编译成静态 .epub 上架 Kindle。他发现编译过程实际上会生成每一个可能的文本页:比如让读者选主角发色(金发、褐发、红发),再用 $hairColor 变量在全文引用,那么凡是用到这个变量的页面都要生成三份。即便是很短的故事,也会变成几百上千页。当时 Kindle 按“阅读页数”付费,读者每选一个分支就往前跳几百页,每页都算已读,读到最后被记成读了几千页,于是他每次阅读的收入从 2-3 美元变成几百美元。当然平台后来改了付费政策、也加强了审核。
simulacrumparty查看英文原文
I know someone who used to make a living writing erotica for the Kindle store and experimented with using inklewriter to create interactive, CYOA-style stories. For a small donation to a charity, the inklewriter devs would compile a story to a static .epub which could then be published on the Kindle store. He discovered that the compilation process essentially generated every possible page of text. For example, he would allow the reader to choose the color of the protagonist's hair (blonde, brunette, redhead) and then refer to a $hairColor variable throughout the text. Every page that used that variable would have to be generated three times, one for each possible value. This resulted in a text that was many hundreds or thousands of pages long, even for quite a short story. At the time, Kindle used a very simple payment model based on the number of pages read. When a reader selected a path, they would jump forward hundreds of pages at a time, each one counting as a read page, and by the end Kindle tracked them as having read thousands of pages. Using this system, he went from earning 2 or 3 dollars for a cover-to-cover reading to literally hundreds of dollars per reading. Of course, they caught on to this and modified the payment policy as well as the thoroughness of moderation and the gravy train ended.
文本标记式工具(ink)灵活、易用,图形化工具(StoryHarp、Twine)在结构复杂时更好梳理;可以先用后者打草稿,再转成前者。
Ink 和编辑器 Inkle 看起来是很棒的系统,让我想起 Inform 7,不过 ink 更偏标记语言,Inform 7 更像结构化的自然语言。StoryHarp 是我 20 年前用 Delphi 写、2018 年初移植到 JavaScript 的互动小说工具,可以生成独立的 HTML 文件。ink 和 Inform 7 一样基于文本,StoryHarp 更偏图形化,有点像 Twine 但不完全一样。ink 在条件逻辑上大概比 StoryHarp 更灵活,但底层概念有重叠:都是给出一个依赖当前上下文和此前状态改变的选项列表。把 StoryHarp 的故事转成 ink 应该很直接,反方向则要看用了 ink 的哪些特性。真正的问题是故事变复杂后会怎样——那正是 StoryHarp 那套受 Smalltalk 启发的浏览器、地图和表格工具该发光的地方。
pdfernhout查看英文原文
Ink and Inkle (the editor) look like a great system. They remind me a bit of Inform 7 (except ink is more markup and Inform 7 is more structured natural language). StoryHarp is an Interactive Fiction tool I wrote 20 years ago in Delphi and ported to JavaScript in early 2018: https://storyharp.com/ The JavaScript version can generate stand-alone HTML files. ink is text-based like Inform 7. StoryHarp is more graphically-oriented -- somewhat more like Twine (but different). http://twinery.org/ While Ink is probably more flexible than StoryHarp in its conditionals, there seems to be some overlap in the underlying concepts (as with much IF tools) in providing a list of choices that depend on a current context and some previous state changes. I'd expect it would be straightforward to convert a StoryHarp story to ink. The other way might not work so well though depending on what features of ink were used. Not sure if people would find value in roughing out a story in StoryHarp and then converting it to ink given ink seems fairly easy to use? I guess the question is how complicated things get (where StoryHarp's Smalltalk-inspired tools like a browser, map, and table hopefully start to shine when stories get complex...)
互动小说工具能同时训练写作能力和编程思维,很适合教学场景。
这套工具是教孩子编程的好玩方式,同时能锻炼写作和讲故事的能力,甚至可以作为通往游戏编程的入口。
flocial查看英文原文
This suite of tools looks like a fun way to teach kids programming while boosting their writing/storytelling skills and even a gateway into game programming.
同类还值得读
乔治·奥威尔1940年对《我的奋斗》的书评
George Orwell’s 1940 Review of Mein Kampf
这是奥威尔 1940 年对《我的奋斗》的书评,他没有简单谴责,而是认真分析希特勒的宣传手法为何奏效、又暴露了哪些思维特征。
小说与文学2022 · 499 分 · 545 评4 条写作要点编辑精选我们都是极客:尼尔·斯蒂芬森的文学作品
We are all nerds: The literary works of Neal Stephenson
这是一篇讨论 Neal Stephenson 科幻小说的文章,评论区读者围绕《Anathem》《钻石年代》《Snow Crash》等作品,聊世界构建、结尾处理和写作风格的变化。
小说与文学2022 · 307 分 · 220 评4 条写作要点编辑精选又一部我不会再去写的小说
Yet another novel I will no longer write
科幻作家 Charles Stross 讲述自己为何放弃一部已经构思好的小说:COVID-19 疫情让他的病毒灾难设定显得多余,现实给所有人上了一堂生动的疫情应对课。
小说与文学2020 · 304 分 · 169 评4 条写作要点编辑精选用图画写作:理查德·斯卡里与儿童文学的艺术
Writing in Pictures: Richard Scarry and the art of children's literature
这是《耶鲁评论》上漫画家 Chris Ware 写的文章,分析童书作家 Richard Scarry 如何用图画而不是文字来讲故事。
小说与文学2024 · 297 分 · 131 评4 条写作要点编辑精选如何写一部小说
How to Write a Novel
这篇来自 The Millions 的文章讨论写小说的两种路径——“计划派”(planners)与“即兴派”(pantsers,即“跟着感觉走、边写边编”)。
小说与文学2016 · 238 分 · 112 评4 条写作要点编辑精选