Jump to content

Sam Jones

  • Content Count

  • Joined

  • Last visited

Community Reputation

179 Spectacular

About Sam Jones

  • Rank
    500 Club

Personal Information

  • Occupation
    Technical Director
  • Homepage
  • Location
    Los Angeles

Contact Info

  • Skype

Recent Profile Visitors

4,651 profile views
  1. Not in my local 2021 version, but I'll go back and download and see if I get something newer.
  2. The URL is what I needed. Even after emptying the cache, I can't get Safari to go to that version of the online Function Reference without clicking on the URL shown above.
  3. Is it possible for VS to get the structural units of a .vwx file?
  4. Josh, and perhaps Vlado and Kevin could way in, Paragraph 1 I get the concept Paragraph 2 brings up a set of questions. Question 1 Does this mean that the "LDevice_GetParamStr()" calls can be substituted for the "GetRField()" calls wherever there is a check mark in the "Multi-cell" or "Accessory" columns? Question 2 Would the following be true? "LDevice_SetParamStr(FixtureHandle, -1, -2, 'Breaker ID', '34');" and "SetRField(FixtureHandle, 'Breaker ID', '34');" are both syntactically correct and are effectively the same statements Question 3 Does an ETC Source 436 fixture have 1 cell whose index would be 0? Question 4 If so, when considering an ETC Source 436 fixture are the following statements syntactically valid and effectively equivalent? "LDevice_SetParamStr(FixtureHandle, -1, -2, 'Breaker ID', '34');" "LDevice_SetParamStr(FixtureHandle, 0, -2, 'Breaker ID', '34');" "SetRField(FixtureHandle, 'Breaker ID', '34');" Question 5 If not, why not? Question 6 What does "LDevice_ReleaseRes;" do? Question 7 (4 parts) What does the following do? LDevice_DlgResource( LayoutID :INTEGER; ControlID :INTEGER; SymbolName :STRING); what layout? what control? symbolName of what?
  5. Glad you figured it out. To me, it was the a question of "Universal Name" of what since I would be passing the handle to the lighting device and not the accessory. Good for you, and thanks.
  6. First of all I'm super glad that you found away to get the symbol name of the accessory, but the symbol name that you reference above and that I reference in the lighting device parameter list is the symbol used by the lighting device that has the accessory not the accessory. GetRField(ObjHandle, 'Lighting Device', 'Symbol Name'). Once I test it, I will use what you have figured out to reference bunch of stuff (I hope).
  7. Thank you for the pointer. I will try it out, however. Below is the list of LD parameters that I have and no where does the syntax that are using shows up. Where is "cell index", "accessory index", and "Symbol Name". I can use "Symbol Name to get the symbol name of the lighting device that has accessories. Though I haven't tried it yet, I'm confident that your use of ...GetParamStr works, but how did you think to use it in the way that you did, because to me there is not hint about doing that that I can derive from the LD parameter list. Lighting Device Universal Device Type Inst Type Edit Cell Edit Accessory FixtureID Old Inst Type Gobo Data Color Data Color Flag Data Fixture Mode Old Fixture Mode Vision Lit Override Vision Fixture Name GDTF Fixture Name GDTF Fixture Mode GDTF Fixture Type ID GDTF Fixture Custom ID GDTF CIE Color Wattage Purpose Position Unit Number Color Dimmer Absolute Address Channel UniverseAddress Universe DMX Address Num Channels Circuit Number Circuit Name System User Field 1 User Field 2 User Field 3 User Field 4 User Field 5 User Field 6 Voltage Breaker ID Time Cost Frame Size Field Angle Field Angle 2 Beam Angle Beam Angle 2 Weight Template TemplateRot1 Template2 TemplateRot2 Gobo Shift Mark Draw Beam Draw Beam as Solid Use Vertical Beam Show Beam at Fall off distance Lamp Rotation Angle Top Shutter Depth Top Shutter Angle Left Shutter Depth Left Shutter Angle Right Shutter Depth Right Shutter Angle Bottom Shutter Depth Bottom Shutter Angle Light On Lit Fog Brightness Symbol Name Use Legend Legend View 3D Flip 3D Top Bottom Flip 3D Left Right Rotate 3D Legend Flip Front Back Flip Left Right Focus Pan Tilt Throw Distance Rotate3DPosition xRot yRot EnableZRot zRot zRot2D Focus Angle Vertical Focus Angle Horizontal Angle To Face Plane Off Axis Angle ShowData Ganged With Use Active Symbol ControlPoint01X ControlPoint01Y ControlPoint02X ControlPoint02Y ControlPoint03X ControlPoint03Y ControlPoint04X ControlPoint04Y ControlPoint05X ControlPoint05Y ControlPoint06X ControlPoint06Y ControlPoint07X ControlPoint07Y ControlPoint08X ControlPoint08Y X Location Y Location Z Location Do Not Edit Alt-Chan Alt-Dim Alt-Unit Alt-Circ Is New __Version NoExport Lightwright ID RGBColor UID __CommPasteName __LabelHandlesData __LabelHandles3DData __CellsCount __AccessoriesCount Dimension UseGDTFGeometry WeightDouble Edit GDTF Data
  8. How do I get the symbol name of an accessory that is attached to a light at a given cell index and accessory index? There does not seem to be a parameter to query.
  9. Unfortunately, I cannot get that to work. This code from the developer wiki fails to allow the selection of a .vwx file. PROCEDURE Example; VAR fileName, title :STRING; defaultFolder :STRING; mask :STRING; BEGIN title := 'Select the object library file...'; defaultFolder := ''; mask := '*.vwx'; fileName := 'Drafting Tools.vwx'; IF GetFileN(title, defaultFolder, mask, fileName) THEN AlrtDialog(fileName); END; RUN(Example);
  10. I don't see how these help. They don't let the user look around their hard disk for the file they want to get resources from. With "PutFile", the user can look around their hard disk for the text file they desire. Perhaps, you have nifty little algorithm that simulates this functionality for finding .vwx files?????
  11. It is possible to import resources from a file into the current file. There are a variety of ways to do this with BuildResourcList() and ImportResourceToCurrentFile() and CopySymbol(). All of these require that the script maker know the file name or folder name containing the resource. Is it possible to present the user with a Finder brower or Director trouser similar to the one presented with the PutFile() command? I would like to present the user with a way to find a file or folder from which to import resources. Possible ??
  12. How do I set the selection of elements in a List Box? The set up dialog creates a list box with CreateListBoxN( dialog, kLabelLegendList, 35, 10, TRUE ); I have a button in the dialog that wants to select all the elements of the list box; however, kSelectAllBtn: BEGIN FOR index := 1 TO NumLLs DO SelectChoice(dialog, kLabelLegendList, index, TRUE); END; selects nothing in the list box. kSelectAllBtn: BEGIN SetSelectionRange(dialog, kLabelLegendList, 0, NumLLs); END; selects nothing in the list box. I have checked to be sure that I am entering the kSelectAllBtn case in the Case statement that polls items in the dialog handler.
  13. At that level, the binary math is not that foreign to me and pretty straight forward. I keep needing to wrap my head around the "anding" of boolean values, but it ends up being pretty simple. I needed the routine above that Kevin provided to extract the values from the integers yielded by the function. I confess that Julian generously and privately offered a simpler solution, but I was/am pissed off that the documentation let put out what I thought was a simple solution that totally hosed my student users and without my knowledge.
  14. Thank you Kevin, To clarify for later vectorscript users: PROCEDURE TestCurrentMode; {DEBUG} CONST kcr = chr(13); Educational = 4; Student = 8; Banner = 64; WaterNewFiles = 128; PrintWatermark = 256; SaveEd = 512; OpenEd = 1024; BetaSerial = 4096; VAR VWMode :LONGINT; IsFull :BOOLEAN; IsEd :BOOLEAN; IsStudent :BOOLEAN; IsMakeWater :BOOLEAN; IsPrintWater :BOOLEAN; IsBanner :BOOLEAN; IsBeta :BOOLEAN; {================================================================================} FUNCTION BitSet(largeNum, smallNum :LONGINT) :BOOLEAN; {Returns true if smallNum is a power of 2 present in largeNum.} VAR bit :INTEGER; BEGIN BitSet := FALSE; bit := 15; WHILE bit > -1 DO BEGIN IF largeNum >= (2 ^ bit) THEN {IF vwMode >= 2 to the power of bit} BEGIN largeNum := largeNum - (2 ^ bit); {Strip large bit off largeNum (off of vwMode)} IF (2 ^ bit) = smallNum THEN {IF 2 to the power of bit = smallNum (2 ^bit = smallNum[requested test number])} {requested is mode found in wvMode } BEGIN {END while loop. } BitSet := TRUE; bit := 0; END; {IF (2 ^ bit) = smallNum} END; {if largeNum >= (2 ^ bit)} bit := bit - 1; {strip large bit to test next smallest bit} END; {while bit > -1 } END; {FUNCTION BitSet} {================================================================================} BEGIN vwMode := 456; vwMode := GetCurrentMode; IsFull := BitSet(vwMode, 1); isEd := BitSet(vwMode, Educational); IsStudent := BitSet(vwMode, Student); IsMakeWater := BitSet(vwMode, WaterNewFiles); IsPrintWater := BitSet(vwMode, PrintWatermark); IsBanner := BitSet(vwMode, Banner); IsBeta := BitSet(vwMode, BetaSerial); AlrtDialog(CONCAT('vwMode = ', vwMode, kcr, kcr,'IsFull = ', IsFull, kcr, 'isEd = ', isEd, kcr, 'IsStudent = ', IsStudent, kcr, 'IsMakeWater = ', IsMakeWater, kcr, 'IsPrintWater = ', IsPrintWater, kcr, 'IsBanner = ', IsBanner, kcr, 'IsBeta = ', IsBeta)); END; RUN(TestCurrentMode);


7150 Riverwood Drive, Columbia, Maryland 21046, USA   |   Contact Us:   410-290-5114


© 2018 Vectorworks, Inc. All Rights Reserved. Vectorworks, Inc. is part of the Nemetschek Group.

  • Create New...