Documents
Writing Docs Gigedit SFZ Instrument Scripts NKSP Language NKSP Reference

in_range()

This function takes 3 integer values as arguments and checks whether the 1st integer value is in the range between the two integer values provided by the 2nd and 3rd arguments. The valid range includes the values of the 2nd and 3rd arguments.

Function Prototype

in_range(needle,low,high)

Arguments

Argument Name Data Type Description
needle Integer Number The value that is going to be checked whether it is in range.
[required]
low Integer Number The smallest value of the valid range (including this value).
[required]
high Integer Number The highest value of the valid range (including this value).
[required]

Return Value

Description Data Type
Returns true (1) in case the value is in the allowed range, false (0) otherwise. Integer Number

Examples

The following example prints the result of some example argument values to the terminal as soon as the script is loaded.

Availability

Since LinuxSampler 2.0.0.svn36.

Document Updated:  2017-05-28  |  Author:  Christian Schoenebeck