script.jsfile might read:
<script src=""></script>, with the source pointing to your file. For example, if you named your file
script2.jsand put it in the same folder with
script.js, then we would change this to:
index.htmlfile points to
scriptES.jsand you're on your way!
monogatari.script()method adds new labels, if any label names conflict with already existing ones, it replaces them. Normally this is fine, but when working with Multi-Language games, the "English" label would be replaced in the second file, overwriting all of the work you did at run time! Luckily, there's a way around this.
monogatari.label()looks at its arguments, first the name of the label you want to write to inside the monogatari._script object, and then if the next argument is a string, it processes that as a language. After that, it takes an array, and from there you just write the script to your game, the same way you do the script for a label, normally!