[Plugin] Ink interpreter

Post your work in progress addons and get feedback

Post » Fri Aug 12, 2016 1:31 pm

Image
INK interpreter
Hello guys !!! I'm a newbie to this forum thing so tell me if I'm making stuff I shouldn't do. It's also the first time I'm making my code public and an addon so it could/will be really buggy. So...

What's INK ? :!:
INK is a open-source narrative script language by Inkle made to help writers working on interactive fiction.

How can I write INK ?
Just use the inky program here and learn the syntax here.

How does the plugin work ? :geek:
First thing you have to know : this plugin won't be able to read an .ink file, it can read only an JSON file made with inky. You can paste the JSON in the plugin properties or use an action to set the data.
My code isn't working ! Just be sure to build the story via the action associated.
I've build the story but the output is empty, sure this is a bug ! Nope, have you called beforehand the Continue action ? You must call it and then get your first output.
The event when an INK variable has changed didn't trigger, WTF ??? :shock: You must beforehand use the trancking variable action.

Why don't you make an example project ?
I want you guys to try every functionality of this plugin and to give feedback so I can correct the bugs. If I give you a pre-made code you can use it always this way and I won't be able correct everything. Just test stuff ! If you really want somewhere to start with, just adapt this.

If I use this in my game, do I have to give you credit ?
Putting it simply, NOPE you don't have to. But I would absolutely love that you give me credit, or at least show what you've made with it below. Also it's not only my work this plugin : the source code is from y-lohse, I only made the adaptation for construct 2.

ダウンロードの時だよ。
Download link/GitHub Link

By the way, sorry guys, I'm not an native english speaker/writer. So my english is pretty sh*ty.
Last edited by CeyFun on Thu Nov 24, 2016 6:50 pm, edited 1 time in total.
B
4
S
2
G
1
Posts: 7
Reputation: 491

Post » Thu Aug 18, 2016 10:46 pm

It seems interesing, it might be useful for rpg games about decisions, I will try it if can callbacks when an user answered a choice
B
99
S
35
G
29
Posts: 3,139
Reputation: 28,421

Post » Thu Nov 24, 2016 4:09 pm

Thanks for this, I've got it working!
B
11
S
3
Posts: 135
Reputation: 1,309

Post » Thu Nov 24, 2016 6:48 pm

@AlexFrancois Glad to help. Don't hesitate to tell me if you want a functionality that's not already embedded. It would be also awesome to see what you've made with my plugin. :)
B
4
S
2
G
1
Posts: 7
Reputation: 491

Post » Thu Nov 24, 2016 9:00 pm

Just to make you guys know, I've updated the plugin and the links (no more dead links). You should download it.
B
4
S
2
G
1
Posts: 7
Reputation: 491

Post » Thu Nov 24, 2016 11:42 pm

@CeyFun Thanks a lot! I'll be sure to sure to keep you updated on my progress. Is it possible to add conditions like On End or On Choice? If not it's not a big deal as this can be called with the compare two values function, just a thought. Thanks again :D
B
11
S
3
Posts: 135
Reputation: 1,309

Post » Fri Nov 25, 2016 12:28 pm

It would also be great if the plugin could detect when knots, stitches and labels are called by name. This would extremely useful as there doesn't seem to be another way of tracking the ink at the moment apart from variables and choices. I see you already have have a go to scene function, an action that tracks the scene and triggers when this succeeds would be awesome.
B
11
S
3
Posts: 135
Reputation: 1,309

Post » Sat Nov 26, 2016 5:13 pm

@AlexFrancois Thanks for the replies but right now it's hard to track the knot you're in via the code, but as soon as there's a way that does not make me write a part of the engine (stay tuned here) I'll implement that (if I start to write something in the engine that'll go nuts). Also right now I'm still studying so there's not as much time as I would like to take to code, so that might take some time. Anyway as soon as I can, I'll see what I can do about it.
PS : It's really hard for me to implement things that are not said here 'cause I don't have the time to read the code of the engine. Sorry but studies first :( (the programmer inside me is crying right now :cry: ).
B
4
S
2
G
1
Posts: 7
Reputation: 491

Post » Mon Nov 28, 2016 11:50 am

@CeyFun Don't worry, what you've done so far is awesome, good luck with the studies!

I think I'm going to use a variable that tracks the knot, it's not much extra work and will do the trick for now :)
B
11
S
3
Posts: 135
Reputation: 1,309

Post » Tue Nov 29, 2016 8:59 pm

Hello guys !!! I have work to do but you know what ? F*ck it I do what I want to do. :ugeek: So, to be quick, there's an update to the plugin : I added TAGS support ! If you want to know what it is you can always check out there for further explanation. @AlexFrancois I hope that'll help out if you want to know in which knot you're in (on the GitHub there are some that have tagged all theirs but hopefully you won't have to). Also I've passed some hours to try to implement a more direct way to get the knot name but I didn't get the things working (I think that's caused by my using of the JS version of ink). Sorry about that (but now I kinda understand how the engine work so that's not for nothing).
Anyway, hope that'll prove to be usefull !
B
4
S
2
G
1
Posts: 7
Reputation: 491

Next

Return to Work in Progress Addons

Who is online

Users browsing this forum: No registered users and 0 guests