Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

How to modify the HTML, CSS and add JavaScript?

I want to create an interactive story, but one that has more than choices.
1) I want this story to have modals that pop up and display additional information after clicking on text, surveys, multiple choice questions, Internet links, and polls.
2) I want to be able to modify the HMTL/CSS enough to add style to any page, and create a uniquely looking story templates.

Is this possible? If so, how do I go about doing that?
If not, do I have any other options?

Thanks!
FJ Contreras

Comments

  • I believe all of what you mentioned is possible. It will require some technical know-how, but it is possible. How you go about implementing the CSS and Javascript depends on the story format and version of Twine you're using.
  • starvingindie,

    Thanks for your reply. I know enough CSS and Javascript to make it happen (I think,) and I could use whichever Twine version is easiest to manipulate. But I wonder how to get it done. Where do I go? Is there a way of doing it through the Twine interface, or do I have to download some files?

    Thanks again.
    Fernando
  • Within Twine 2 open up your story and there should be an "Edit Javascript" and "Edit Stylesheet" button in the options. This is where you would write your CSS and Javascript. In Twine 1, you would mark a passage with the tag "stylesheet" or "script" I believe.

    If you checkout the Twine2 Guide it should answer most of your questions on how to get started.
  • I'll give it a go. Thanks for your help!
  • You need to state which Story Format you are using when you ask a question, as answers can be different for each one.

    Both of the behaviours you wish to implement are possible but the CSS and Javascript required to do so will be different for each story format.

    SugarCube 1 has a UISystem API which would help you implement the dialog functionality you want, as would SugarCube 2's UI API.
Sign In or Register to comment.