<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.diychristmas.org/wiki/index.php?action=history&amp;feed=atom&amp;title=Archived_ChristmasWiki%3AVixen_Script_Projects</id>
	<title>Archived ChristmasWiki:Vixen Script Projects - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.diychristmas.org/wiki/index.php?action=history&amp;feed=atom&amp;title=Archived_ChristmasWiki%3AVixen_Script_Projects"/>
	<link rel="alternate" type="text/html" href="https://www.diychristmas.org/wiki/index.php?title=Archived_ChristmasWiki:Vixen_Script_Projects&amp;action=history"/>
	<updated>2026-08-08T15:56:43Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.35.11</generator>
	<entry>
		<id>https://www.diychristmas.org/wiki/index.php?title=Archived_ChristmasWiki:Vixen_Script_Projects&amp;diff=5892&amp;oldid=prev</id>
		<title>ErnieHorning: Restored from the archived ChristmasWiki backup. Image references updated where required.</title>
		<link rel="alternate" type="text/html" href="https://www.diychristmas.org/wiki/index.php?title=Archived_ChristmasWiki:Vixen_Script_Projects&amp;diff=5892&amp;oldid=prev"/>
		<updated>2026-08-07T03:36:44Z</updated>

		<summary type="html">&lt;p&gt;Restored from the archived ChristmasWiki backup. Image references updated where required.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Vixen Script Projects are written in C#, and allow for non-sequential control of displays.&lt;br /&gt;
&lt;br /&gt;
==Vixen Standard Scripts==&lt;br /&gt;
Vixen Standard Scrips provide basic on/off, fade/ramp, timed control. To use this, create a New Event Sequence &amp;gt; Script Project.  Then, one must select &amp;#039;&amp;#039;Standard.dll&amp;#039;&amp;#039; from the Script &amp;gt; Modules menu.&lt;br /&gt;
&lt;br /&gt;
===Standard.dll===&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Note:&amp;#039;&amp;#039;&amp;#039; The examples will use this example channel list:&lt;br /&gt;
* Channel_1&lt;br /&gt;
* Channel_2&lt;br /&gt;
* Channel_3&lt;br /&gt;
* Channel_4&lt;br /&gt;
&lt;br /&gt;
====Properties====&lt;br /&gt;
Any of the channels imported into the scripted sequence are available by name.&lt;br /&gt;
Also, there is an additional &amp;quot;All&amp;quot; channel, which is all of the channels.&lt;br /&gt;
&lt;br /&gt;
====Methods====&lt;br /&gt;
All assume to operate asynchronously; the action will return unless the Wait modifier is used (below).&lt;br /&gt;
* void On(channels, modifiers);&lt;br /&gt;
* void Off(channels, modifiers);&lt;br /&gt;
* void Ramp(channels, int startIntensity, int endIntensity, modifiers); // Intensities are 0-100&lt;br /&gt;
* void Random(channels, int saturationLevel, modifiers); // Saturation level is 0-100&lt;br /&gt;
* void Chase(channels, modifiers);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=====Arguments=====&lt;br /&gt;
&amp;quot;channels&amp;quot; is a ChannelCollection. There are a number of ways to create a ChannelCollection:&lt;br /&gt;
&lt;br /&gt;
* ChannelCollection ChannelRange(startChannel, endChannel);&lt;br /&gt;
: Example: ChannelRange(Channel_2, Channel_4)&lt;br /&gt;
* ChannelCollection ChannelRange(startChannel, int count);&lt;br /&gt;
: Example: ChannelRange(Channel_2, 3)&lt;br /&gt;
* ChannelCollection ChannelRange(int startIndex, int count);&lt;br /&gt;
: Example: ChannelRange(1, 3)&lt;br /&gt;
* ChannelCollection Channels(...);&lt;br /&gt;
: The parameters for Channels() is a params list of channel collections. It can be used to create a single set of disjointed channel collections.&lt;br /&gt;
: Example: Channels( Channel_1, ChannelRange(Channel_3,2) );&lt;br /&gt;
: Example: Channels( ChannelRange(DateTime.Now.Hour,1), ChannelRange(10,10), Channel_2 );&lt;br /&gt;
&lt;br /&gt;
&amp;quot;modifiers&amp;quot; is a params list made up of 0 or more of the following:&lt;br /&gt;
* At(int level) // Intensity level, 0-100&lt;br /&gt;
* For(int seconds) // Applies the action for the given time period.&lt;br /&gt;
* Over(int seconds) // Same as For(), just makes better sense in some uses.&lt;br /&gt;
* Wait // Wait for the action to complete.&lt;br /&gt;
* Every(int seconds) // Occurs at every time interval.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Modifier time span&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
The default measure of time is seconds. So For(5) would cause the action to span 5 seconds. The measure of time can be changed with one of the following properties on the modifer:&lt;br /&gt;
* Millisecond&lt;br /&gt;
* Second&lt;br /&gt;
* Minute&lt;br /&gt;
* Hour&lt;br /&gt;
: The plural version of each of those is also valid.&lt;br /&gt;
: Example: To have a chase span 3.7 seconds over the first 10 channels synchronously...&lt;br /&gt;
:: Chase( ChannelRange(1,10), Over(3700).Milliseconds, Wait )&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====Example Scripts====&lt;br /&gt;
To have certain channels on for a given time range:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void Start() {&lt;br /&gt;
	Off(All);&lt;br /&gt;
&lt;br /&gt;
       DateTime now = DateTime.Now; //get the current time&lt;br /&gt;
&lt;br /&gt;
        //The DateTime constructor goes (YYYY, MM, DD, HH, MM, SS)&lt;br /&gt;
	DateTime start = new DateTime(now.Year, now.Month, now.Day, 17, 30, 00);&lt;br /&gt;
	DateTime end = new DateTime(now.Year, now.Month, now.Day, 23, 00, 00);&lt;br /&gt;
&lt;br /&gt;
        //We only want the channels to turn on while the current time is&lt;br /&gt;
        //between 5:30 and 11 pm&lt;br /&gt;
	while (now.CompareTo(start) &amp;gt;= 0 &amp;amp;&amp;amp; now.CompareTo(end) &amp;lt;= 0)&lt;br /&gt;
	{&lt;br /&gt;
               On (Channels(Tree_1), At(100));&lt;br /&gt;
               On (ChannelRange(1,15), At(100));&lt;br /&gt;
               On (ChannelRange(18,7), At(100));&lt;br /&gt;
               On (ChannelRange(27,8), At(100));&lt;br /&gt;
&lt;br /&gt;
               Random (ChannelRange(15,2), 50, For(50).Second);&lt;br /&gt;
&lt;br /&gt;
	       now = DateTime.Now;  //update the current time&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	Off(All);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Archived ChristmasWiki:Vixen]]&lt;br /&gt;
[[Category:Archived ChristmasWiki:DIYC Index]]&lt;/div&gt;</summary>
		<author><name>ErnieHorning</name></author>
	</entry>
</feed>