1
+ <snippet >
2
+ <content ><![CDATA[
3
+ //-----------------------------------------
4
+ // LScript Channel Filter template
5
+ //
6
+
7
+ @version 2.2
8
+ @warnings
9
+ @script channel
10
+
11
+ // global values go here
12
+
13
+ create
14
+ {
15
+ // one-time initialization takes place here
16
+ }
17
+
18
+ destroy
19
+ {
20
+ // take care of final clean-up activities here
21
+ }
22
+
23
+ process: ca, frame, time
24
+ {
25
+ // 'ca' is the Channel Filter Object Agent
26
+
27
+ // it exports one read-only data member:
28
+ // name the name of the channel as
29
+ // it is displayed to the user
30
+
31
+ // it provides two methods:
32
+ // get returns the value of the
33
+ // channel (as a floating-point
34
+ // number) for an indicated time
35
+ // index
36
+ // set sets the channel's value to
37
+ // the provided floating-point
38
+ // value for the current time
39
+ // index (indicated by the 'time'
40
+ // argument to process()).
41
+
42
+ }
43
+
44
+ load: what,io
45
+ {
46
+ if(what == SCENEMODE) // processing an ASCII scene file
47
+ {
48
+ }
49
+ }
50
+
51
+ save: what,io
52
+ {
53
+ if(what == SCENEMODE)
54
+ {
55
+ }
56
+ }
57
+
58
+ options
59
+ {
60
+ reqbegin("<Requester Title>");
61
+
62
+ c0 = ctlinteger("Integer Control",1);
63
+ c1 = ctlnumber("Number Control",1.0);
64
+ c2 = ctlstring("String Control","my string");
65
+ c3 = ctlcheckbox("Checkbox Control",true);
66
+ c4 = ctlpopup("Popup control",1,@"Item 1","Item 2","Item 3"@);
67
+ c5 = ctlchoice("Choice Control",1,@"X","Y","Z"@);
68
+
69
+ return if !reqpost();
70
+
71
+ // get requester control values here
72
+
73
+ reqend();
74
+ }
75
+
76
+ ]]> </content >
77
+ <!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
78
+ <tabTrigger ></tabTrigger >
79
+ <!-- Optional: Set a scope to limit where the snippet will trigger -->
80
+ <scope >source.lscript</scope >
81
+ <!-- description, syns i auto completion listan in view -->
82
+ <description >Template: Channel Filter</description >
83
+ </snippet >
0 commit comments