having problem with documented if statement

I can't get this to work. It returns null 1 1 1 1 when I run it in squiffy. The if statement is straight off the documentation. Thanks.

@set a = 1
@set b = 1
@set c = 1
@set d = 1
{if a=1:{@b+=1,c-=1,d=2,not e}}{else:{@b+=2,c+=2,d=3,e}}


I copied your code and pasted it in directly, and it seems to work for me:



I'm running Squiffy build 5 on a mac and it definitely does not work there. I just cut and pasted again from your post and it returns
nul 1 1 1 1

It must be a bug then ?



I tested it everywhere but in my desktop version (which is Build 5.0.0 on Windows 10), and...


It looks like it's buggy in Windows, too.

What happens if you build the game and play it in Firefox?

Ok, if I run the code on a browser, Chrome, under windows it works for me too. So then it is a software bug in the compiler under Mac on build 5.

In that case then I can say that on mac build 5 the squiffy.game.go ("section") also does not work !


Try squiffy.story.go("section")

Same {if} bug is in the desktop Windows version, build 5.0.0.

Hello, it is not a bug per se. The functionality being tested in this thread was first proposed in an earlier forum post. The maintainer of the site and software added that functionality to Squiffy 5.1.2 and to web Squiffy and updated the online documentation. Unfortunately, the most recent desktop build for Mac is 5.0. Also, the download page for Squiffy on textadventures.co.uk is inaccurate. It is platform-dependent what it says, but on a PC it says that version 5.1.2 is available for OS X, which is not the case.

However, a workaround (not a fix) is to write in 5.0 and then compile using the command line version of Squiffy (which is up to date with the new functionality, even on a Mac).

Sorry I don't have the names and links handy for the people/threads mentioned above. I'm on my phone.

Found the earlier thread!


Heck yeah, loopernow! Great info!!!

That made me download this:

Then, I followed these steps (took 15 minutes, roundabout):

And now...



Thanks, loopernow!!!

Well, that's cool! You're welcome!

This topic is now closed. Topics are closed after 60 days of inactivity.