Greetings
I'm wondering on what to avoid in order to not make a Twine game 'slow' in terms of time needed to change a passage, etc. Therefore, I present my questions here, for I didn't find them elsewhere or in satisfying manner.
1. Size file. Is there a noticeable difference between 1 mb .html Twine game and a 50 mb?
2. Array functions. Is indexOf() noticeably slower than accessing a static index in an array? Does making changes to an array of, say, 300 objects take up time depending on whether we push, pluck, or simply change a variable of some property of an object?
3. Passage size. If one passage is extremely long (say 50k words, both macro/function and displayed text), does it take noticeably longer to load than a comparably smaller one (say 1k words)?
Other than that, what else is there? Since I'm slowly building up, the only 'noticeable' as in 300ms difference at most was at creating 5 loops each iterating 500 times and pushing a value onto an array.
Best Regards
Comments
Also, you're asking vague questions to which there are no easy answers.
In general, however:
Twine 2.0, SugarCube 1. Sorry for not mentioning that.
Insane or pathological, what defines as such?
Currently, besides the worry of having to do a game in parts because of file size limit, the problem is choosing either an extremely large passage size or a looped for more than 300 iterations array of objects manipulation, which involves indexOf every time.
Choice being to use a loop of indexOf based manipulation or just manual checks but with more text contributing to greater passage size.
Thanks.