knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
A pattern table is composed of cells telling the tracker which notes to play in which order. It also has a field for effect commands. It is often represented as a three digit hexadecimal value. The first hex digit represents the effect command, the latter represent parameter values used by the command. The table below summarises all available effects in ProTracker.
library(ProTrackR2) library(kableExtra) data(effect_commands) effect_commands |> kbl()
To get an effect command from a ProTracker module, you can simply call
pt2_command()
to a pt2cell
or pt2celllist
class object (see vignette("s3class")
for
a ProTrackR2 object tree). There, are several ways of extracting cells as
documented in vignette("sel_assign")
. In the example below there is one way shown
of getting the effect commands of the first 8 rows of the second column in
the third pattern.
mod <- pt2_read_mod(pt2_demo()) pt2_command( mod$patterns[[ 3 ]] [ 1:8, 2 ])
You can also assign new effect commands to your selection like this:
pt2_command( mod$patterns[[ 3 ]] [ 1:8, 2 ]) <- "C10"
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.