Hi folks, working with nyx for the first time and im making a multiple route tease. to make that happen i need to either select a random page using the button/delay event or to create a variable that then becomes the page name eg:
Var page = rand(1-5)
goto page
Im just not sure of the nyx syntax for this?
I have had a little look in the nyx coding thread but couldnt find the answer in there.
Can anyone help?
Nyx randomization?
- texturedshroom
- Taste the shroom

- Posts: 422
- Joined: Mon Aug 18, 2008 10:19 am
- Location: Midwest USA
- Contact:
Re: Nyx randomization?
Specify the page # as range(1, 5).
As in:
delay(30sec, range(1, 5))
Keep in mind the pages have to be named 1#, 2#, 3#, 4#, and 5# for this to work.
As in:
delay(30sec, range(1, 5))
Keep in mind the pages have to be named 1#, 2#, 3#, 4#, and 5# for this to work.
Re: Nyx randomization?
Ah i see, is it not possible to add the random number to a string with a variable:
var $page = "page"
var $random = range(1, 5)
var $page = "$page$random#"
So i end up with $page is "page3#"
If not ill go with the plain old numbered option, but itd be handy to categorized the groups of pages
var $page = "page"
var $random = range(1, 5)
var $page = "$page$random#"
So i end up with $page is "page3#"
If not ill go with the plain old numbered option, but itd be handy to categorized the groups of pages
- texturedshroom
- Taste the shroom

- Posts: 422
- Joined: Mon Aug 18, 2008 10:19 am
- Location: Midwest USA
- Contact:
Re: Nyx randomization?
No; Nyx does not currently support variables as such.
Re: Nyx randomization?
Ah okies, thanks for the response anyhoo, i can get to work now!
Theres my suggestion for nyx, variables!
Might not be easy to implement though!
Theres my suggestion for nyx, variables!
Might not be easy to implement though!

