Skip to content
CoyoteMIDI
  • Upgrade to PRO
  • My account
  • Help
  • Contact
  • Shopping Cart
CoyoteMIDI
  • Shopping Cart
  • Upgrade to PRO
  • My account
  • Help
  • Contact

CoyoteScript (PRO only)

CoyoteScript Basics
  • Collection Operations
  • Command Nesting
  • Comments
  • Documentation Syntax
  • Events
  • Logical and Comparison operators
  • Math Operations
  • Triggers
  • Using Scripts
  • Variables
CoyoteScript Commands
  • After
  • Before
  • Case
  • Ceiling
  • Click
  • Cooldown
  • CopyFile
  • Cos
  • Count
  • CreateFolder
  • Date
  • DeleteFile
  • DeleteFolder
  • Else
  • Floor
  • Foreach
  • GetFiles
  • GetFolders
  • GetMouse
  • GetPixel
  • GetRecordingVolume
  • HeldNotes
  • If
  • Indicator
  • IsProcessFocused
  • IsProcessRunning
  • Key
  • KeyState
  • KillProcess
  • MapKeys
  • MapValues
  • Max
  • MessageBox
  • Midi
  • Min
  • MoveFile
  • MoveFolder
  • MoveMouse
  • ParseJSON
  • Print
  • Random
  • Repeat
  • Rest
  • Return
  • Round
  • RunScript
  • SearchImage
  • SearchPixel
  • SetFocusedProcess
  • SetRecordingEnabled
  • SetRecordingVolume
  • SetVolume
  • Sin
  • Split
  • StartProcess
  • Switch
  • Tan
  • Time
  • Wait
  • Web
  • While
  • Write
CoyoteScript Events
  • Key
  • Midi
  • Process
  • ScriptsLoaded
  • Shutdown
  • Startup
  • Time
  • WindowChanged
  • WindowsSession

Basic Operation

  • CoyoteMIDI FAQ
  • Getting Started
  • Overview
  • Using CoyoteMIDI with a DAW (loopback MIDI)

Other

  • Version Changelog
  • Home
  • Docs
  • CoyoteScript (PRO only)
  • CoyoteScript Basics
  • Collection Operations

Collection Operations

In CoyoteScript, variables can hold map or list based collections. These collections can be manipulated and read from through collection operations.

These operations include:

  1. “+” or “add” to add a value to a collection.
  2. “-” or “remove” to remove a value from a collection.
  3. “+>” or “include” to add multiple values to a collection as individual values.
  4. “->” or “exclude” to remove multiple values from a collection as individual values.

Example:

$list1 = 1, 2, 3
$list1 + 4
$list1 - 2
$list2 = 5, 6
$list1 +> $list2
print $list1
> (1, 3, 4, 5, 6)

List values can be accessed by their position by putting the list inside parenthesis followed by the position index.

Example:

$list = a, b, c
print ($list 2)
> b

Map values can be accessed by the key value of an item in the map by putting the map inside parenthesis followed by the value of the key.

Example:

$map = a: dog, b: cat, c: bird
print ($map b)
> cat
Share This Article :
  • Facebook
  • Twitter
  • LinkedIn
  • Pinterest
Updated on April 24, 2022
Using ScriptsCommand Nesting
© 2023 - CoyoteMIDI | All rights reserved