Code Monkey home page Code Monkey logo

yarnmachine's Issues

Error: Command <command name> unknown

Hello :-)

So far everything works just fine, but I ran into a single problem, which I'm not yet sure the cause of.
It's related to commands and manifests into the YarnTest (demo.cpp) console app like this:

[error]: Command fade_up unknown
[error]: Command 1.0 unknown

which happens when the script gets to this line

<<fade_up 1.0>>

As I'm just learning about YS it's by no means affecting me in any way, but I still thought I'd post it here.

How to reproduce

I compiled the test dialog at https://try.yarnspinner.dev/ using both the ysc.exe in this repo (version 2.3.0), as well as the compiler built from the source (version 2.4.0), but the problem persists.

I'm attaching the compiler output + the source script here YarnScript.zip

To reproduce the problem I copied the compiler output to the YarnTest.exe directory and ran it:

.....\build\Debug>YarnTest.exe
Type name of module to run :
YarnScript
Loading lines from : YarnScript-Lines.csv
Line database total lines : 37
Line database size (bytes) : 14104
Time spent in parsing (ms) : 2
Yarn Spinner is a language for writing conversations in games!
You can use it to write branching dialogue, and use that in a game engine!
For example, here's a choice between some options!
        1) Wow, some options!
        2) Can I put text inside options?
1
You got it, pal!
You can also write 'commands', which represent things that happen in the game!
In this editor, they'll appear as text:
> fade_up 1.0
[error]: Command fade_up unknown

[error]: Command 1.0 unknown

        1) Nice!
        2) But it didn't actually fade!

It's the only problem I ran into so far, and it doesn't affect me, but I will be poking around a bit more.

Thanks again,
Jan

By default, include ProtoBuf header/source with the rest of the source code.

Thanks for creating this. I just read over the YarnSpinner docs, and it seems like exactly the thing I was looking for, in order to create branching dialog for my toy game engine.

If I can make a suggestion: I think it would be a good idea to store the generated ProtoBuf files, along with the code. That way, people interested in this project can just download the code and build it, without having to download extra dependencies. Those ProtoBuf header/source files only need overwriting when the .proto file changes.

yarnc / csv -> .json script

The additional large dependencies for protobuf and csv are kind of silly / offensive to me for simple dialogue trees - I'd like to have a script pipeline that compiles .yarn files, then opens them up and serializes the output into a json file using nlohmann, since my engine runtime already uses that.

I might put a bounty on this.

Missing step while building the project (minor thing)

Hello :-)

Not really an issue, but I had to do one tiny extra step and thought I'd write it here, in case anyone else runs into the problem in the future.

In order to successfully generate the project, I had to first manually fetch the protobuf submodule:

git submodule update --init --recursive

Otherwise the folder "./depends/protobuf" is empty and CMake fails with:

CMake Error at CMakeLists.txt:30 (add_subdirectory):
The source directory
....../YarnMachine/depends/protobuf
does not contain a CMakeLists.txt file.

Everything else generated and built just fine. ๐Ÿ‘

I would be happy if it was made into the instructions somehow, if this is something that happens for everyone.
This is a first time I'm making an issue, and maybe I could just make a pull request, tell me what you think.


PS: Just want to say I'm very glad this exists.
I'm making my own tiny game engine for learning purposes and really want to use YarnSpinner in it.
I understand YS was made for unity, but I definitely think it would benefit the community to have a engine agnostic version.
If nothing else your project showed me that it can be done.

Thank you!
Jan

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.