mirror of
https://github.com/Oreolek/ink-instead.git
synced 2024-06-30 22:04:58 +03:00
Update README.md
This commit is contained in:
parent
bbdbd087d4
commit
88e8994a0b
19
README.md
19
README.md
|
@ -5,9 +5,8 @@ An attempt to implement a subset of [ink](https://github.com/inkle/ink) in lua u
|
||||||
|
|
||||||
_Ink is inkle's scripting language for writing interactive narrative, both for text-centric games as well as more graphical games that contain highly branching stories._
|
_Ink is inkle's scripting language for writing interactive narrative, both for text-centric games as well as more graphical games that contain highly branching stories._
|
||||||
|
|
||||||
## Currently supported
|
## Parser
|
||||||
|
Supported:
|
||||||
### Parser
|
|
||||||
- Paragraphs
|
- Paragraphs
|
||||||
- Comments
|
- Comments
|
||||||
- Choices
|
- Choices
|
||||||
|
@ -19,10 +18,12 @@ _Ink is inkle's scripting language for writing interactive narrative, both for t
|
||||||
- Include
|
- Include
|
||||||
- Tags
|
- Tags
|
||||||
|
|
||||||
|
|
||||||
### Runtime API
|
### Runtime API
|
||||||
|
Supported:
|
||||||
```lua
|
```lua
|
||||||
boolean story.canContinue
|
boolean story.canContinue
|
||||||
nil story.continue()
|
string story.continue()
|
||||||
table story.currentChoices
|
table story.currentChoices
|
||||||
nil story.chooseChoiceIndex(index)
|
nil story.chooseChoiceIndex(index)
|
||||||
nil story.choosePathString(path)
|
nil story.choosePathString(path)
|
||||||
|
@ -31,7 +32,17 @@ table story.tagsForContentAtPath(path)
|
||||||
table story.currentTags
|
table story.currentTags
|
||||||
number story.state.visitCountAtPathString(path)
|
number story.state.visitCountAtPathString(path)
|
||||||
```
|
```
|
||||||
|
TODO:
|
||||||
|
```lua
|
||||||
|
string story.state.toJson()
|
||||||
|
nil story.state.loadJson(savedJson)
|
||||||
|
story.variablesState["variable_name"] = newValue
|
||||||
|
value = story.variablesState["variable_name"]
|
||||||
|
story.observeVariable ("variable_name", function(string varName, object newValue) )
|
||||||
|
story.bindExternalFunction ("function_name", function(...))
|
||||||
|
});
|
||||||
|
|
||||||
|
```
|
||||||
See [WritingWithInk](https://github.com/inkle/ink/blob/master/Documentation/WritingWithInk.md) and [RunningYourInk](https://github.com/inkle/ink/blob/master/Documentation/RunningYourInk.md) for the description of the reference ink implementation.
|
See [WritingWithInk](https://github.com/inkle/ink/blob/master/Documentation/WritingWithInk.md) and [RunningYourInk](https://github.com/inkle/ink/blob/master/Documentation/RunningYourInk.md) for the description of the reference ink implementation.
|
||||||
|
|
||||||
## Used by
|
## Used by
|
||||||
|
|
Loading…
Reference in a new issue