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

Image alignment not working?

$
0
0
I am wondering if the image alignment is still working properly...

for example: <img src= "thesiteyourimageisfrom.com/whatever.jpg" width="800" height="360" align="right">

For some reason, that isn't working in my new project that I am doing for my college work, is there a way to fix this?

In the meantime, ill try copying it over from my old project.

P.S: Can confirm that copying and pasting an image link from a previous project then changing it to the one you want works, not sure why it doesn't work when typing it normally

How to add klembot-snowman-2 (bitbucket) story format

$
0
0
I've downloaded the source code for snowman 2 and I'm trying to add it to Twine 2's list of formats, but I can't identify what .js file I'm supposed to "+Add" to make it work. The other question I found about Sugarcube 2.x had a "format.js" file, but nothing like that shows up in the snowman 2 source, and the bitbucket doesn't appear to describe anything about straight-up installation. Only building from source. Do you HAVE to build from source? Because, from the way it was described, it seemed like you could just clone and use it.

SugarCube releases

$
0
0
I figured that I might as well post a note that I've just published a new release of SugarCube for those of you using it.

Highlights:
  • Added dynamic updating to several of the page elements within the UI bar (sidebar) when passages are displayed, which is configured via the config.updatePageElements property (default: true). The affected elements are the story: banner, subtitle, author, caption, and menu. Note: Since SugarCube uses the story's title as the basis for the key used to store and load data used when playing the story and for saves, it is not included in updates and it is strongly recommended that you do not add any kind of dynamic code to it.
  • Added a seedable PRNG which integrates with the story history (incl. saves), which is configured via the History.initPRNG() static method.
  • Changed the saves menu so that the delete and purge buttons no longer close the menu. This should make it more convenient for players to reuse save slots, since they can now delete and then immediately save without having to reopen the menu.
  • Updated the <<if>> macro to emit an error if an expression is supplied to the <<else>> clause. This is primarily to flag improper <<else if>> usage for authors.
  • Updated the <<optionbar>> macro's output to reflect the changes to UISystem.
  • Updated UISystem:
    • Added the new static method UISystem.alert(), which opens a window.alert()-style message box.
    • Added the new static method UISystem.show(), which opens the UI dialog window and is now the basic method by which all dialogs are opened.
    • Made various improvements to UISystem.
    • Updated the UI CSS styles.
  • Updated the default CSS @media query for mobile devices.
  • Updated the feature detection logic a bit and the feature polyfills.
  • Updated the embedded jQuery library (to v2.1.0).
  • Embedded the seedrandom.js library.
  • Moved the history (un)marshaling code out of SaveSystem and into History. This was spurred on in large part by the integration of the seedable PRNG into History. This also necessitated save format changes.
  • Moved several internal utility functions into the Util object for namespacing.

Can I embed a Twine story in a linkedIn CV?

$
0
0
Hello,

I'm working on an interactive story CV and wanted to know if it was possible to place it directly into linkedIn.

I guess the real question is, then, once I've finished it, how do I then allow people to view it via my Linkedin Page ONLY?

Question for Devs (About grouping passages)

$
0
0
Hi!

I wanted yo ask if you are planning to include possibility to create groups for passages in the story map?

I found lack of possibility to group my passages disturbing when trying to create complex story with really LOTS of them (and also there could be non-readable for player technical passages). It would greatly help to have a possibility of grouping them together, probably using different colors and names for different groups. If you find it difficult to understand the idea, I can make a draft of what I mean :)

Multiple variable setter link?

$
0
0
Hi.

I'm using SugarCube 2 and Twine 2.

Is there a way to set multiple variables with a single setter link? So one click changes multiple variables.

I did work around it using <<click>>, but was curious if I was missing something in the syntax for setter links.

Thanks.

Can cards for trading card games be coded on harlowe?

$
0
0
I was thinking about starting a game on this style, and wondered if it can be done with what we have now.

[Harlowe] Link located in if-statement isn't working (error).

$
0
0
Does anyone know why this isn't working? I can't seem to figure it out. Any help is appreciated.
Halfway down the hall is an open doorway. Light spills out(if: $hallclear is false)[, casting a slender silhouette onto the wall. [[A woman walks out, holding a clipboard.->meetwoman]] ](else:)[. You are alone.]

Error Message 1155

$
0
0
Hi everyone! I am having to use Twine 1.4.2 for a class project. Every time that I go to BUILD - "Test Play" I get the error message 1155. Can anyone help me figure out what is going on?

im not sure how to add sound effects into my twine stroy

$
0
0
I don't know how add sounds effects into my twine story can you help?

Displaying part of a random passage on click

$
0
0
Twine 1.4 and SugarCube 2.

Let's say I have a simple passage like this:
Some text and <<click "button">><</click>>.

When the button is clicked I want to: get a random passage from a list, then get a random sentence from that passage, and display it below the original text and button--with any links removed/deactivated (so only showing plain text sentence). So the player can keep clicking the button, and new random sentences will keep appearing below it.

I know I can display a random passage with:
<<set $passage to either("Passage 1", "Passage 2", "Passage 3")>>
<<display $passage>>

And I thought I could display a random passage on button click with something like this:
<<click "Show Random">><<set $passage to either("Passage 1", "Passage 2", "Passage 3")>><<display $passage>><</click>>

But that's not working.

As for grabbing a random sentence from the passage (rather than displaying the whole passage), and deactivating the links... I assume this is something I should try to do in prerender, via some kind of black magic vaguely like this?

html tags with timedcontinue macro (Sugarcane)

$
0
0
<i>...text1
<<timedcontinue 2>>
</i>text2

The closing tag is ignored if it goes after <<timedcontinue>>, so all text till the end of the passage remains italic. Any way to fix it?

How do I Close Inventory and return to previous Passage?

$
0
0
I've been following this tutorial on how to make an inventory system: http://gersande.com/designing-inventories-in-twine-2-with-the-built-in-harlowe-macros/#1

It's been really helpful so far, until I ran into their comment about using (history:)'s last. I don't want to use it because this is going to be a long game that may or may not have an option to view the inventory from a lot of different passages.

I want to have later passages that only happen if you have a certain item in your inventory.

How would I go about doing this in Harlowe?

How to make a link activated by hooks?

$
0
0
I'm a beginner, I started using Twine today.
I want to make a link that works only after you click both of 2 hooks.
I'm not a native speaker of English, so I write in my own language. Also, I don't understand all things that are in Twine.
Here's what I have:
[Kurtka]<getKurtka|
[Buty]<getButy|
[[Ubieram się i wychodzę z domu->Droga do szkoły]]
(set:$kurtkaCheck to false)
(click: ?getKurtka)[
Założyłaś kurtkę.
(set:$kurtkaCheck to true)
]
(set:$butyCheck to false)
(click: ?getButy)[
Założyłaś buty.
(set:$butyCheck to true)
]

I want to make "[[Ubieram się i wychodzę z domu->Droga do szkoły]]" link activate when you click both Kurtka(jacket) and Buty(shoes). "Ubieram się i wychodzę z domu" means "I put on my outerwear and leave the house".
I want to make it so, if you don't get a jacket and shoes you can't go to school.
For example, this link can be hidden until you click the jacket and shoes or just un-clickable.
Thanks in advance.

Putting PHP in Harlowe?

$
0
0
I know you can insert normal HTML codes right into a passage in... pretty much any Twine 2 formats, yes? Is it possible to insert PHP code as well? I gave it a test go and the ?php part of the code got parsed out as something(?) so it didn't process right; I'm wondering if that's because it doesn't support the syntax or if I'm missing some sort of escape code.

(I did a bunch of searches and didn't find anyone asking about this, apologies if I missed it.)

Very strange bug! (Sugarcane, Javascript)

$
0
0
I'm trying to write a function which simulates dialing:
<<set $nmbrs=["dial0.wav","dial1.wav","dial2.wav","dial3.wav","dial4.wav","dial5.wav","dial6.wav","dial7.wav","dial8.wav","dial9.wav"]>>

<<set $dial=
function(number)
{function delay(i)
 {var d=eval(number[i]);if (!d) d=10;return 666+d*160;}
 var code='<<timedcontinue 0.5>>';dur=500;
 for (var i=0;i<number.length;++i)
 {t=$nmbrs[eval(number[i])];
   code=code+'<<playsound "'+t+'">><<timedcontinue '+delay(i)/1000+'>>\n';
  dur+=delay(i);
 }
//alert(code);
new Wikifier(document.createElement('div'), code);
 return dur/1000;
}
>>

<<timedcontinue $dial("99876543201")>>\
(My modification of timedcontinue macro accepts the time in seconds only, the rest is the same as in the standard one)
If I uncomment the alert, everything works great, and this is what the alert shows:
<<timedcontinue 0.5>><<playsound "dial9.wav">><<timedcontinue 2.106>>
<<playsound "dial9.wav">><<timedcontinue 2.106>>
<<playsound "dial8.wav">><<timedcontinue 1.946>>
<<playsound "dial7.wav">><<timedcontinue 1.786>>
<<playsound "dial6.wav">><<timedcontinue 1.626>>
<<playsound "dial5.wav">><<timedcontinue 1.466>>
<<playsound "dial4.wav">><<timedcontinue 1.306>>
<<playsound "dial3.wav">><<timedcontinue 1.146>>
<<playsound "dial2.wav">><<timedcontinue 0.986>>
<<playsound "dial0.wav">><<timedcontinue 2.266>>
<<playsound "dial1.wav">><<timedcontinue 0.826>>
These delays are correct for every digit and works OK.
But if I remove the alert, the first delay becomes about 10 times shorter it should be! Not 0, however (I found it out by increasing all delays 10 times - then the 1st one becomes normal, while all the rest becomes huge). So the second digit sound starts playing way before the first one ends. That's true for any first digit - 0,9,1, etc.
What's the reason and how to fix it?

Music and sound effects

$
0
0
Sorry to ask another question so quickly.

I need sound effects in my Twine in places. I've found some formats that I can't seem to get to work.

How do I embed youtube audio into my Twine?

Hidden Link

$
0
0
Is there a way to make a link hidden, only accessible through the editor. Example, if I want to make a chance of choosing x or y
[[(either:"x","y")]]
and make the links for x and y, how do you hide the actual links, so that only the 'either' link appears?

I don't want to be responsive

$
0
0
I'm using sugarcube latest ver, I want to stick some images in place in my twine, but the responsive layout changes their positioning. My images slide all around the background: url(); when the window resizes.

I've tried using @media to get rid of the margin-left and right which happen, but I have no idea rn how to stop this from happening.

Getting more than one link to work with an if/else statement

$
0
0
Looked around a fair deal, and I haven't noticed that anyone else has talked about this yet.

In my current story, I have a lot of interconnecting passages that the player may or may not have explored, and I want the links to each area to reflect that. For example, from passage 1, there are links to 2, 3, and 4, where 2 and 3 don't necessarily progress the story, but also give you two new options to go forward, 5 and 6, respectively. Going through either 4, 5, or 6 would have the player move forward into new experiences. So

> 2 -> 5
/ ^ \
/ | v
1-> 4
\ | ^
\ v /
> 3 -> 6

The problem I'm having is with coding the links between 2 and 3, so that if you've visited 3 already, instead of displaying the link to 3 again, 2 will instead direct you to 6, and vice versa with 2 and 5.

I've tried using

(if: (history:) contains "3")[(link: [6])]
(elseif: not (history:) contains "3")[(link: [3])]

and alternately

(if: (history:) contains "3")[(link: [6])]
(else:)[(link: [3])]

as well as using $variables instead of (history:)

(if: $3 is true)[(link: [6])]
(else:/elseif:)[(link: [3])]

or combination (if:) statements

(if: $3 is true)[(link: [6])]
(if: $3 is false)[(link: [3])]

No matter what I've tried, however, when I go to test the passages, I see errors like "Unexpected Identifier (link: [3])", or no links display at all. I know I could do this in SugarCube with the simple code

<<if visited ("3")>>
[[6]]
<<else>>
[[3]]
<<endif>>

so it it's frustrating that it's so much harder in Harlowe. I'm still new to using Twine in general, but it seems like Harlowe has a lot more functions that would be useful for game making, and I'd really like to learn more of it instead of just using SugarCube because it happens to be more convenient at the moment.

Any help or insights would be appreciated. Thanks.
Viewing all 3830 articles
Browse latest View live