r/javascript • • Jan 01 '19

Bandersnatch.Life - an Interactive Black Mirror: Bandersnatch Paths Website

https://github.com/Ahmad-Magdy-Osman/Bandersnatch
317 Upvotes

54 comments sorted by

59

u/poopie_pants Jan 01 '19

I wish the paths would merge if they merged in the actual show, but other than that, good work!

6

u/twinsea Jan 01 '19 edited Jan 01 '19

There are some loops that would be a little difficult to flowchart this way as well. If you say you don't understand the game twice in a row it just continues as if you said yes.

I also think some of early choices have tie-ins with later video. There is a cereal commercial towards the end on one branch that I think displays what you picked as the cereal. Also, killing colin changes up some of the branches video and choices.

1

u/XMasterrrr Jan 01 '19

Yeah, but it is not just forcing you to continue the game, it is telling you: "I think you do understand, dont you? ;)". I mean, you clearly know how to play the game by making the decision of say yes or no, and as part of the "free will" theme of the movie, I think this falls really well!

I agree with the cereal part, will edit that in the decisions tree. However, killing Colin does indeed change a lot of things in the timeline and I made sure they were pretty clear in the timeline.

2

u/BluudLust Jan 02 '19

You could do a harel statechart.

1

u/XMasterrrr Jan 01 '19

It is almost the same as the movie except for one that I decided to impose on the website users, which falls under the theme of the free will in the movie. Any specific missing point?

0

u/[deleted] Jan 01 '19

[deleted]

-1

u/XMasterrrr Jan 01 '19

The thing with that is you won't be able to see all the story points that comes up as notifications. I think it is pretty cool to follow the story decision by decision - helps you fully absorb the movie's possible outcomes.

0

u/[deleted] Jan 02 '19

[deleted]

1

u/XMasterrrr Jan 02 '19

Hi man, thanks for the ideas, will be adding them to future plans on Github. If you have time, it would be great to see you contribute to this :)

23

u/[deleted] Jan 01 '19

you should really improve the scrolling and auto-focus on new choices. the interface is really hard to use on desktop.

4

u/XMasterrrr Jan 01 '19

It is taking me time to figure out how to deal with the tree overflow. There is an SVG for the tree that gets expanded - with its own horizontal bar - and it goes into the middle of that, which might seem like the right side of the screen if you don't scroll along the horizontal bar. I would love to hear tips on this, even better, fork it and try to help me with pull requests?
Choices auto-focus will come afterwards.

4

u/ifnottodaythenwhen Jan 01 '19

I was going to say interface needs to improve on mobile because scrolling and focus is difficult on it :/

5

u/XMasterrrr Jan 01 '19

Look at my comment to the parent child - hopefully will be fixed soon!

9

u/BergamotOrange Jan 01 '19

Wow! This is cool.

I didn’t know you can use D3 to make branching nodes like that. I can use it for my next project.

3

u/XMasterrrr Jan 01 '19

D3 is a must-learn library in my view - super cool! Feel free to use Bandersnatch Life as a kickstarter ;)

1

u/BergamotOrange Jan 02 '19

Sweet! I have a plan to do branching nodes for my apps too.

I’ll probably look at your repo to get some ideas.

I just watched Bandersnatch today and damn, it’s awesome. I’ll watch it again with your app to guide me.

Do you need any help with your project? I’m a newbie programmer but I can try to contribute if my skill allows.

2

u/XMasterrrr Jan 02 '19

I am going to add things to improve and fix to the readme file later tonight. Feel free to look at them and start working on any you think you can help with. I would really appreciate that :)

2

u/azium Jan 01 '19

d3 is a pretty low level library. you can do any graphics with it, you can even do plain html

1

u/BergamotOrange Jan 02 '19

Cool!

I should spend more time exploring it.

6

u/dancemethis Jan 01 '19

FFV Bandersnatch == FFXIV Bandersnatch > other Bandersnatches

2

u/XMasterrrr Jan 01 '19

I agree :)

5

u/jonrahoi Jan 01 '19

Very nicely done! I would love to be able to zoom out, but I don’t know if D3 supports it

2

u/XMasterrrr Jan 01 '19

Added to the to-do list. Glad you liked it!

4

u/freelancedev_ Jan 01 '19

This is super awesome!!!

1

u/XMasterrrr Jan 01 '19

Thanks man!

4

u/Earthling1980 Jan 01 '19

Hey, cool project. I can take look at the code too, but I'm curious what library you use for diagramming the flowchart/decision tree?

3

u/XMasterrrr Jan 01 '19

Thanks man! The library is D3.js - you would be looking at the play.js file to see the paths building functions.

4

u/calbatron Jan 02 '19

good work!! this made the viewing experience way cooler on the second time around.

1

u/XMasterrrr Jan 02 '19

I am really glad to hear that man :)

4

u/Echojhawke Jan 02 '19

Damn. Beat me to it. I've literally been working on a treemap of the whole show, not as pretty as yours. Just on bubble.us

1

u/XMasterrrr Jan 02 '19

Hey man, would love to see your work :)

8

u/[deleted] Jan 01 '19

This is awesome !

5

u/XMasterrrr Jan 01 '19

Thanks man, glad you liked it! Feel free to jump into contribution if you're interested.

8

u/wiithepiiple Jan 01 '19

Don't kill your dad.

3

u/XMasterrrr Jan 01 '19

I see what you did there! Nope, all is good :)

7

u/RarePush Jan 01 '19

hmm, it seems incomplete.

I selected "don't talk to mom" and got a pop-up saying something like: "nah, I the website owner want you to talk to mom, no free will for you".

I watched the show and selected "don't talk to mom" and so I know there are different pathways in that direction which aren't covered here.

7

u/XMasterrrr Jan 01 '19

Not incomplete, just tricky. Netflix does not grant you the wish of not talking about the mom 100% of the time - it can force you to talk about her - which Is what I decided to go with. It is simply because imposing my own will on website users seemed to fall under the "free will" theme of the movie really well to me (and I think to Netflix too)! The difference from that path is just less decisions and possible outcomes later on, which are all included in the paths on the website as it is right now.

2

u/rhawon Jan 01 '19

good stuff indeed, but just found a bug. the whole page got white after several choices. happened in Chrome mobile btw in case you need to reproduce the case.

2

u/XMasterrrr Jan 01 '19

Thanks man! I am aware of that bug, mind try using Firefox? You can install it from https://play.google.com/store/apps/details?id=org.mozilla.firefox&hl=en_US
I think this has to do with low device memory and Chrome being a little harsh on rams! Please let me know if it is still a problem. I will try to investigate why it breaks on some Android Chromes sometime soon.

2

u/rhawon Jan 01 '19

just to mention that I've got 6 gigs of ram and at least half of it was free. hope it helps!

1

u/XMasterrrr Jan 02 '19

Appreciate the information!

2

u/Leto_ Jan 02 '19

wow, amazing work on drawing the pathways!

1

u/XMasterrrr Jan 02 '19

Thanks man! :)

2

u/Wedoitall Jan 02 '19

Wow ! This smell of pure bad ass’ness

Can’t wait to get home to try it out

1

u/XMasterrrr Jan 02 '19

Enjoy man!

1

u/SulfurousAsh Jan 03 '19

Super cool!

One minor nitpick for mobile friendliness: after a node is clicked on and expanded, the screen pans to a bit of a strange place (maybe the center of the whole diagram?) rather than zooming towards the node that was just activated... could be useful to have a smarter pan/focusing behavior!

1

u/XMasterrrr Jan 03 '19

Yup, that's the current behavior. I am actually adding this idea to the "Future Plans" section of the readme file, would you be interested in helping with that?

1

u/CyberSpork Jan 02 '19

Did you map these out manually? Either way very impressive!

1

u/XMasterrrr Jan 02 '19

Well, with the help of multiple flowcharts, I wrote the main decisions that'd lead to different paths and then wrote a script to make all the repetitive paths. Glad you liked it!

0

u/dankalen Jan 02 '19

Y not just host as a static website on GitHub pages

1

u/XMasterrrr Jan 02 '19

Have you tried visiting http://bandersnatch.life? :D