Coder Social home page Coder Social logo

protagonist's People

Contributors

evanwalsh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

protagonist's Issues

Better branding

The current branding is... boring. We need a new logo.

Ugh.

JavaScript ReferenceError in exported story .html

I've tested this out with a very vanilla Twine story, using protagonist. My story plays fine within the Twine editor, but when I publish to file and try to run it, it appears that $ is undefined:

Uncaught ReferenceError: $ is not defined1../story @ Test Protagonist.html:27s @ Test Protagonist.html:27e @ Test Protagonist.html:27(anonymous function) @ Test Protagonist.html:27

This is running the Twine 2 app locally, on a Mac. Exported story html is here: https://gist.github.com/hoverbird/c007fa5a2f6b1ae4df2d

Thanks for your work on Protagonist... this story format is exactly what I need for a project I'm working on!

Run Embedded JS in Execution-Time

I am having a problem with the following code of this type:

<%= random(['thing 1', 'thing 2', 'thing 3']) %>

[[This Passage]]

It will always give the same result.

I believe this is because the code is evaluated at compile-time.

I have been really liking this format, but this might make it unusable.

Thank You!

Add Syntax Highlighting

Adding (javascript) syntax highlighting in the editor would make the code a lot easier to read.

Harlowe has somehow managed it, I think the relevant code is here.

Story Javascript/Stylesheet Improvements

It would be nice if you could tag a passage with "storyjavascript" or "storystylesheet" and then have the contents of that passage appended to the Story Javascript/Stylesheet when compiled. And/or a "head" tag that adds the contents to the tag (for loading external JS files)

It would let you have a passage for each object, instead of one long Story Javascript that you have to search through.

Also is there a way to access the jQuery in the story javascript? I tried $ and Chrome said it was undefined.

Subpassages

Subpassages could be a way to further organize passages into sections. (enhancement)

[BEGIN PASSAGE]
This is the default passage display. If no subpassage is specified, this section will be parsed and displayed.
::subheader (on new line, by itself)
This is a subpassage, accessible through the link format [[passage-name::subheader]] or [[Click me->passage-name::subheader]]. When the link is clicked, only this section will be parsed and displayed.
[END PASSAGE]

"Add a New Format" Error

When trying to use the new link, got this error:
The story format at https://raw.githubusercontent.com/massivedanger/protagonist/master/dist/format.js could not be added (Story format source did not call window.storyFormat()).

goTo / goToPassage

(Edited to reflect further research): Not sure if this is a documentation or functional issue or both... story.goToPassage and goTo (which seem equivalent but one requires the object and one is just a helper?) both seem to return a blank passage instead of my specified passage. Tried it with %= and just plain old % and also tried referring to passage by name and by number and even by story.startPassageID!

Anyway, a bit of clarity on whether these functions are supposed to immediately jump the player to the named passage (with no link click required) or somehow incorporate the passage or do something else entirely would be a big help... not entirely sure if there is also a bug here, but I think I've tried about every possible syntactical combination without getting any expected results...

Audio support

We need the ability to play music and sound effects easily

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.