Quantcast
Channel: Twine Forum
Viewing all 3830 articles
Browse latest View live

Feedback on alternate-history-magical-realist short story

$
0
0
sWf1QSa.jpg
Would love to get some feedback on the first beta version of Ms. Lojka: a kind of weird alternate-history-magical-realist short story that I'm working on. There's no save functionality, but it should be playable in just about 10 minutes.

Here's the link: http://jordanmagnuson.s3.amazonaws.com/mslojka/ms_lojka_beta01.html

Any and all feedback is welcome, from technical and readability issues, to feature improvements, to the actual writing.

Thanks in advance to anyone who takes the time!

displaying another link on click

$
0
0
I am new to Twine, have searched for this a couple times and haven't found a straightforward answer. What I am trying to do is make a new link appear after a link in a passage has already been clicked (rather than linking to a new passage) using Harlowe 1.1.1. what I mean:

LINK1 [link 1 is clicked]

passage now reads:

LINK1
LINK2 [link 2 is clicked]

passage now reads:

LINK 1
LINK2
[[LINK3->next passage]]

I thought that the link-reveal macro may be useful for this, but when I input it, Twine tells me that link-reveal does not exist.

Thanks in advance!

show delayed multiple lines of text in same passage

$
0
0
Good morning folks,

Details: Twine 2 | Sugarcube |

Question: I have 1 passage. What I am trying to achieve is a delayed show of multiple lines of text. Example: This is text line 1 (pause 3 seconds) This is text line 2 (shows under Text line 1) (pause 3 seconds) This is Text line 3 (under text line 2)...etc

Attempts: Ive tried using various Javascript codes, which work, but always throws an error of "unexpected token < ". I get this error message, click okay, then the script runs fine. This obviously wont work because of the error msg. it throws.

I then came across this CSS example:
/* make keyframes that tell the start state and the end state of our object */
 
@-webkit-keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
@-moz-keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
@keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
 
.fade-in {
	opacity:0;  /* make things invisible upon start */
	-webkit-animation:fadeIn ease-in 1;  /* call our keyframe named fadeIn, use animattion ease-in and repeat it only 1 time */
	-moz-animation:fadeIn ease-in 1;
	animation:fadeIn ease-in 1;
 
	-webkit-animation-fill-mode:forwards;  /* this makes sure that after animation is done we remain at the last keyframe value (opacity: 1)*/
	-moz-animation-fill-mode:forwards;
	animation-fill-mode:forwards;
 
	-webkit-animation-duration:1s;
	-moz-animation-duration:1s;
	animation-duration:1s;
}
 
.fade-in.one {
-webkit-animation-delay: 0.1s;
-moz-animation-delay: 0.7s;
animation-delay: 0.7s;
}
 
.fade-in.two {
-webkit-animation-delay: 10.2s;
-moz-animation-delay:1.2s;
animation-delay: 1.2s;
}
 
.fade-in.three {
-webkit-animation-delay: 20.6s;
-moz-animation-delay: 1.6s;
animation-delay: 1.6s;
}

.fade-in.four {
-webkit-animation-delay: 30.6s;
-moz-animation-delay: 1.6s;
animation-delay: 1.6s;
}
.dashdiv { background:grey; margin:5px; width:20px; height:20px; }


Where I give my DIV an ID in the passage. This works great in the Twine application, however, once it exports to HTML, the delays to not work. It simple fades in one after another within a second or so...

Solution? Anyone have any ideas how to accomplish this? Thanks guys and gals!

i have builded half of my story on internet explorer but it is not test playing

Is it possible to create an ongoing collaborative narrative in twine?

$
0
0
I have more than a few ideas that involve creating an initial network of storylines and allowing readers to add different possible continuations from each point written. Ideally the readers would be able to work off of each others work, with the exception being when a particular choice is already marked as "The End". Any idea how I could do this/ anyone interested in helping?

What's Possible in Twine 1.4 - Some Basic Javascript and CSS

$
0
0
Introduction:

Some of you have seen me around, but allow me to introduce myself. I'm Cora. I'm 26 years old. And before Christmas, I had never heard of Twine, I hadn't typed raw HTML since 2001, and I'd never even touched Javascript or CSS. If you're already having a case of TL;DR or you don't care to find out how I did what I did, you can simply scroll down and download the build at the bottom of the post. Otherwise, I want to show you what can be done when an amateur pushes Twine and only the most basic macros and stylesheets.

Why? I'm also a graphic artist. I don't have the literary talent of the best Twine authors, but that doesn't mean I can't contribute in my own way. I hope this inspires you, or at least lifts any imagined limitations you may have put on Twine. So with that, let's list the features I've used.

Note: Much of this code only operates in modern browsers because it uses HTML5. Chrome or Firefox are recommended.

Basic CSS:

If you use Twine a lot and think learning CSS isn't worth your time, think again. Understanding layout is the simplest and most important thing you can do to improve the look and feel of your game. That doesn't even count all the actual gameplay it can add if you're even mildly clever. Go learn it. Write your own stylesheets. Center elements. Make windows scale to the text that's inside them.

I used it to create dialog boxes and event windows in JRPG style. A macro isn't even neccesary if you want to stay simple. All this can be done with nothing but CSS and some HTML tags.

undefined

Animation:

CSS animation is a handy tool no matter what kind of game you're putting together. Even in it's most basic form, you can see the power it holds in screen transitions. Even a simple fade to black. But it can go much further. CSS is even capable of rotating 2D graphics and applying perspective warp. You could move a passage link across a screen, making it difficult to click. You could create a compass that rotates in the direction of the correct passage. Or you could go completely insane. Still, there's no need to be complicated. Simple effects can work wonders. Learn it if you like or check out Dan Eden's open-source CSS code.

I used it for splash screens and transitions. It makes the community stronger, and it expresses gratitude to the authors of a great piece of open-source software. This is the kind of idea that's a win-win for you and the community. Twine gets more users, which means more people play your game. Besides, it looks great and ups the perceived production value of your game. And if you're going to make one splash screen, why not also use the opportunity to advertise yourself and the people who made the game possible?

undefined  undefined

Sound:

Audio is a powerful element in general. It is capable of evoking emotion in many of the same ways stories do. It can be what separates a good Twine game from a great Twine game. Even the most minimal sound effects add a level of immersion to an otherwise purely visual sensory engagement. There are some caveats. HTML5 is still new. Browser support is scatter-shot. Be aware that you'll need to either use established methods of playing sound or you'll need to research what browsers support what formats. Be prepared to host multiple versions of the same sound in some cases. Fixes will come with time. This week I even saw an open-source 8-bit sound creator that runs on Javascript and loads saved sounds with a string (so it's possible to embed them in HTML like images and fonts).

I used it for menu items and minimal effects. Since this is a demo, music is only going to distract. In addition, because the aim of Twine is to deliver a single small file, my sounds needed to be hosted online and I simply don't have a place for that.

Keyboards:

This is something that most people don't think about short of the <<textinput>> command, but keyboards can do anything you want them to. You can bind entire macros to keys. You could even use this in conjunction with a canvas element to make an HTML5 game from scratch, but that's not what we're here to discuss. The point is the power of the keyboard when you want to go above and beyond a simple point and click game.

undefined

I used the keyboard for an almost-complete cursor macro. Check it out in the game proper. In Twine, all you need to do is supply an array (<<cursor "Go upstairs" "Go downstairs" "Go outside" "Go to bed">>) and it works. Once its finished, I may release it on it's own, but it's only the tip of the iceberg of what's possible.

Variables and Arrays:

If CSS is the simple thing that makes your game look nice, this is the simple thing that will make your actual gameplay shine. Twine is a tool to tell stories about choice. Variables are by their very definition that choice. The more you can do with them, the more interactive of an experience you can leave a user with. I highly recommend experimenting with basic Twine commands like <<if>> and <<set>> until you know them backwards and forwards. I would also highly recommend memorizing these Twine methods. Once you have them memorized, you can take them into Javascript when you're ready and then you'll be well on your way.

I made an inventory screen with it that displays user stats, the current player location, the players money, and their traits.

undefined

I also implemented a paperdoll system with nothing but variables and the CSS mentioned earlier.

undefined  undefined

Expertly written Twine games come in two varieties. The literary and the technical. Let's strive to be both. If someone like me can do this, then I really want to spread the word and see what those established coders and developers can come up with. Let me know as well if there are any other learning resources you found helpful. I'll link them if they're relevant.

Version 1.1:
  • The cursor no longer resets to position 1 after every selection
  • Imported fonts issue has been solved but it still not implemented
  • Implemented x and y movement with the cursor as new 'cursortable' macro
  • Implemented SNES/PSX style name entry grid
  • If keys are held down, the cursor may not update correctly
  • The trait selection screen may 'flash' before animating in
  • Temporarily not working in Firefox. Use Chrome for a moment...
Download:
Here

can a link do one thing on hover and another thing on click

$
0
0
I am using Sugarcube 1 in Twine 1.4

The following code, defined by CSS, displays a tooltip when hovering over the link text:

<a data-passage="#" class="tooltip"><span style="text-align: left; font-family: arial;">This is the text of the tooltip when it pops up</span>clickMe</a>

When the user clicks (not hovers) on the link "clickMe," I want the click to take the user to an external web page. Is it possible to construct a link so that hover does one thing and click does another?

How can I open the developer tools in downloaded Twine 2.0?

$
0
0
I've been trying to figure out a way to open the developer tools (like in Chrome/FF) in the offline version of Twine 2.0. Has anyone else had any luck?

Setter Links for 2.0.11

$
0
0
I have seen this mentioned a lot and have bumped into it myself. However I find it necessary to bring it up again since I am having issues resolving the matter. Why is it setter links do not function properly. I used the auto generated passage like many have suggested but the link is opening a blank window titled node webkit. Anyone know whats going on with this bug.

Twine 2.0 Localization?

$
0
0
Hey there,

I've already searched through the forum/google but I still wonder whether twine 2.0 provides an easy system to localize the story into different languages? Something like an ID system which can be cross referenced with a spreadsheet or anything similar?

Thanks for your time,

Hellfish

Turn off Twine Error Messages

$
0
0
Is there a way to suppress Twine error messages? Using certain code, triggers an error, however after clicking OK on the error message, the story works fine, as the code im using is intended to.

Any chance this is an option?

Any way to have a rule running at all times?

$
0
0
I want to have a rule running at all times, sort of a random encounter that could happen whenever you go to another passage. Is this possible to do without having it stated as a rule in each and every passage?
Edit: Also any way to do the same thing but with a button/link? like at any time you can look at player info/variables without having to put the link/button in every passage?

Can I link two stories? (SugarCube)

$
0
0
I asked the same thing for Harlowe, but I ended up switching to SugarCube because it allows me to do more of what I want... So I'm sorry for being a pain in the butt, but now I'd like to know if there's a Sugarcube version of the Harlowe answer I got from greyelf. If it's the same exact thing, just say so, I guess... Heh.

Here's the link to my old question:
http://twinery.org/forum/discussion/5802/can-i-link-two-stories-harlowe#latest

Now all I need to know is the SugarCube version of it.

Can a (live:) macro update its own cycle time?

$
0
0
Tl;dr: Can I make a (live: $variable) macro which changes its own variable each cycle? If so, how?

Largely out of curiosity I want to do something like this on Harlowe:
(set: $whatever to 100)
(set: $cycleTime to 1000)
(live: $cycleTime)
[
$whatever
(set: $whatever -= 1)
(set: $cycleTime -=5)
(if: $cycleTime is 0)[(stop:)]
]  

This would create a countdown that gradually sped up if it worked. Sadly, it doesn't. The (live:) macro seemingly only checks the value it is given once (which is fair enough for most applications) so updating $cycleTime has no effect. I tried nesting one (live:) macro within another but the results were.... weird (try:
(set: $whatever to 100)
(set: $cycleTime to 1000)
(live: $cycleTime)[
(live: $cycleTime)[
$whatever
(set: $whatever -= 1)
(set: $cycleTime -=50)
(if: $cycleTime is 0)[(stop:)]
]
]

if you would like to see the weird. I have played around with various times for the top level/first macro, but the weird is persistent. I think I understand what is happening here, but it's not the behaviour I want).

So, is there a solution? It's not style-crucial, but it would be fun for some of the stuff I am working on.

Thanks for reading and for any and all responses :)

Different text sizes and fading?

$
0
0
Hello all,

I've created some nice dreamy effects for my dream sequence (using Harlowe), but there are a few things I'd still like to achieve. In order of priority:

1.)
I would like to increase the size of a single piece of text and realign it, making it central to the screen. It would move from the bottom right, increasing in size (as well as having other effects applied) until it became the focal point of the screen and also a link. Is there any way of doing this, for example via the CSS: macro or other workarounds?

2.) (This might be kind of a pre-requisite for 1)
I would like some way of fading out text - the text-style "delete" gives me an error message at present (though I've only tried it in a test run so far, not even sure if it would provide the effect I'm after as it didn't work). Is there anything "built-in" that does this? If not I am considering maybe a gradual change in text colour till it is the same colour as the screen, though I don't know if this would allow me to centralise and enlarge my remaining text? Perhaps it is best just to move to a different passage?

3.)
I am currently using a recursive (live:) command to fill empty, named hooks from an array, which works pretty nicely though A.) certain text effects don't seem to work at all e.g. blurrier, whilst others - for example fade-in-out - are either removing the spaces I have included in my strings or at least making them less visible. I am using Papyrus as my font if that helps. Is it the case that not all text-styles work with all fonts?


Thanks all in advance - I'm beginning to really like the effects I can produce and a lot of that is down to you fine folk. I hope one day I'll have a story to share with you all :)

Problem with passing/processing macro parameters (Sugarcane, Javascript)

$
0
0
I want my playsound macro to work both with constant names and expressions, like
<<set $wav=".wav";i=2>>
<<playsound "fall"+$i+$wav>>

In the handler
handler: function (a, b, c, d) {
      var s = (d.fullArgs());
      this.domacro(b,s);
    }
domacro is the function that does the main job:
domacro: function(b, s) {
      if (s) {
alert(s);//for debugging
        s=eval(Wikifier.parse(s));
//...et cetera...
Trying:
<<playsound "fall2.wav">>
s becomes "fall2.wav", all works.
<<playsound "fall"+$i+$wav>>
s becomes state.history[0].variables.wav == null && (state.history[0].variables.wav = 0);state.history[0].variables.i == null && (state.history[0].variables.i = 0);"fall"+state.history[0].variables.i+state.history[0].variables.wav
(yes,I copy-pasted this string exactly as it was displayed by the alert box)
So far so good, unless I need a second parameter:
<<loopsound "fall"+$i+$wav $times>>
s becomes state.history[0].variables.times == null && (state.history[0].variables.times = 0);state.history[0].variables.wav == null && (state.history[0].variables.wav = 0);state.history[0].variables.i == null && (state.history[0].variables.i = 0);"fall"+state.history[0].variables.i+state.history[0].variables.wav state.history[0].variables.times

So, the problem is: I need to split s to send each parameter to eval(Wikifier.parse()), but the parameters codes are separated by spaces, and the same spaces are used inside their codes. There is no way to understand where one parameter ends and the next begins!
I can replace " == " with "==" and " = " with "=" and " && " with "&&", but I'm not sure if any more complex expressions can produce more kinds of spaces. Any ideas?

I receive error when CD is put in computer:

$
0
0
CD not to be read properly
Anyone else having this issue?

[Snowman 2] Can't compile Snowman 2

$
0
0
When I try to compile Snowman 2 via Grunt (grunt build), I get the following error:
Running "html:test" task
Warning: Unable to read "src/index.html" file (Error code: ENOENT). Use --force to continue.

What's going on here?

Really will make sense

Likely have to think about replacing

Viewing all 3830 articles
Browse latest View live