Today, I've tried several Built-In Functions in Yarn2, but none of them seem to work. Are these functions unavailable in your system?
Here's my .yarn file:
Code: Select all
title: BuildInFunc_Test
---
My lucky number is {random_range(1, 10)}!
<<if not visited("BuildInFunc_Test") >>
This is your first visit.
<<elseif visited_count("BuildInFunc_Test") == 1>>
This is your 2nd visit.
<<elseif visited_count("BuildInFunc_Test") == 2>>
This is your 3rd visit.
<<else>>
You have visited more than 4 times.
<<endif>>
===
1. random_range(1, 10) is parsed as "{0}" when I import it into Dialogue System. The dialogue always says "My lucky number is {0}!"
2. visited() and visited_count() are parsed as Conditions when I import it, but they don't seem to work properly. The dialogue always says "You have visited more than 4 times."