Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(1 edit)

Thanks for the reply, I'm having a little difficulty wrapping my head around how to do this.

From what you said, inside of the visualnovelexample you use the drawstring class to manage custom commands. I believe you are referring to the following:

You subscribe to that delegate event by using the drawstring.RunCommandEvent+=Runcommand; and it leads me to this line


By following that rabbit hole to the drawtring script I see an event called RunCommandEvent and underneath that the bool for Runcommand()

Unfortunately that bool only lets me run commands in the "Raw Text" portion of the fleece dialogue line editor. Trying to put it in the "Link Raw Text" portions when you have a branching choice causes the text to not be read or parsed properly.

So now, after reading through your message several times, I've tried instead to look through the parsers and figure out how to resolve it that way. I found the "FleeceDefaultParser" that comes included with fleece and the script associated with it and am now trying to figure out how to implement something the returns "true" or "false"

I made a function "isLeader" to check if you had an object or leader of a specific type in the leader slot of FleeceDefaultParser (this is in the parser.cs file)
It checks and in the inspector displays it as FALSE if the leader is not correct (as intended)

However, whenever I test this in the live game it completely disregards the "False" text and plays that line of dialogue that should have been rejected. I haven't done anything different than you have for the visited or !visited line. Using a debug string prints out False which means it should technically be rejecting it. But it does not. I tried deleting those passages and making new ones but it still is rejecting it.

I followed the same format you set up and tried to establish things to be as close to how you did it as possible but was wondering if there was something super obveous I was missing, or perhaps it's that I just dont have a good enough foundation to understand how to make these kinds of edits.

Thanks for your time.

Okay, so after tinkering with it for a few hours I found out the problem. It's super strange. This is an example of what I had before


In the "Let's Test" passage I had a single line of text, then at the end of that it would check to see if that value was true.
BUT what ended up happening is that it would just pick the first link in the chain as if it said true. Now I tried this with the <<!visited>> function too, and it caused the same response which nearly caused me to tear my hair out because I saw it work before. So I tried this:



The only difference being that I put no input text on the first passage. If there's no text then it will check the values first and function properly. But if there's ANY TEXT AT ALL in the passage it refuses to acknowledge it.

I have no idea if I ran into an extremely fringe bug or I coded something strangely to cause this to happen.