Trying to make a new Adventure


#1

So, I’ve been trying to create some custom adventures for the last few hours. I thought I’d followed the instructions, but any edits seem to cause phantombot to run into errors and not be able to load.

[02-08-2018 @ 11:22:04.961 GMT] [ERROR] [loadScript()@ScriptManager.java:46] Failed to load module: lang/english/games/games-adventureSystem.js: JavaScript Error: missing ) after argument list (games-adventureSystem.js#46)
[02-08-2018 @ 11:22:04.962 GMT] [ERROR] [loadScript()@ScriptManager.java:49] Terminating PhantomBot due to Bad JavaScript File

I’d love some help on this, as I want to replace the stock ones with some custom adventures for my twitch.

Kristy


#2

Can you upload your file here so I can have a look at it? Thanks!


#3

Here’s the edited original. I thought I filled it out properly.

games-adventureSystem.js (8.6 KB)


#4

Most of our scripts use a single quote (') to specify a string and the lang files are the same way. When using an apostrophe you will have to add a backslash in front of it or things will break. This is what we call an escape character.

Here’s an example. You\'re going to have to use a backslash to use apostrophes in the lang files.

Here’s the copy of your file with the fix.

games-adventureSystem.js (8.6 KB)


#5

^^ OMG!!! Thank you so much. I went in and deleted the original ones and changed the adventuresystem.stories.5. to 1,2,3,4 [like I know you’re supposed too.] Now, it works!

You were super helpful, thank you so very much.