Jump to content

The Hamma

Member
  • Content Count

    105
  • Joined

  • Last visited

Posts posted by The Hamma


  1. This modification corrects the issue but it seems to me that if the points are read from HCenter as inches then they should be passed to RegularPolygon as inches. 

     

    HCenter(h,Px,Py);
    RegularPolygon((Px*25.4),(Py*25.4),(9*25.4),6,1);


  2. Yes, I did try adding the unit to the script but that does not work either.  The size and the location of the created polygon are still 1/25.4 scaled. 


  3. I have attached a file with two scripts in progress.  It is a script that I was developing to replace circles with hexagons.  The first version doesn't work as expected. It creates the hexagons but they are 1/25.40157 sized and location from the origin.  I modified the script to multiply the X,Y coordinates by 24.40157 and the size.  This places the hexagons in their proper location and size.   It seems that the script is converting the units to mm from inches. If I set the drawing units to mm the first script works

    Script Error.vwx


  4. 1 hour ago, Matt Panzer said:

     

    @The Hamma ,

     

    It looks like most of the objects in the 3D Component are set to display along with the 2D components. This is causing the objects to be rendered in hidden line behind the displayed 2d component. Try editing the 3D component of the symbol, select all of the objects, click on the "Display with 2D Components" button in the Object Info platte and uncheck all of the options. Once you do that, it should render much faster.

    Thanks that was the issue. 

    • Like 1

  5. Below is a script by Peter Vandewalle and it work fine as a command or from the script palette but if I run it as a tool the angle constraints don't kick in to the second object duplication. Does any one know why and how to fix it. I like this script vs the move by point tool because it makes a duplicate object at every point that I click. and I don't have to keep switching the move by point from retain objects to not retaining objects.

    Procedure CopyPt;

    {Peter Vandewalle, 14-03-2003}

    LABEL 99;

    VAR

    ObjHdle,NewHandle:HANDLE;

    xi,yi,xm,ym,xp,yp,X,Y:REAL;

    YesNo:BOOLEAN;

    SelNum:LONGINT;

    Procedure do_error(s:STRING;v:REAL);

    BEGIN

    AlrtDialog(Concat(S,' = ',Num2Str(5,V)));

    END;

    BEGIN

    Absolute;

    SelNum:=NumSObj(ActLayer);

    IF (SelNum=0) THEN BEGIN

    Message('Select object to copy:');

    GetPt(X,Y);

    SetSelect(PickObject(X,Y));

    END;

    Message('Click reference point');

    GetPt(xi,yi);

    YesNo:=false;

    xp:=xi;

    yp:=yi;

    REPEAT

    Message('Click endpoint, double-click to exit');

    GetPtl(xi,yi,xm,ym);

    IF ((xp=xm) AND (yp=ym)) THEN GOTO 99;{Check 4 double-click}

    Duplicate(xm-xp,ym-yp);

    xp:=xm;

    yp:=ym;

    UNTIL YesNo;

    99:ClrMessage;

    DSelectAll;

    RedrawAll;

    ClrMessage;

    END;

    Run(CopyPt);


  6. I would like to know if there is a way to convert a 3d poly to a 2d poly in the layer plane so it moves in 3d the same way that a 3d poly does, not converted to the screen layer as a hidden line rendering of the 3d poly. If there is not a way I put out this challenge for some one to write a script that would do so.


  7. Anyone know why this script runs from the script Palette but not if I add it to the menu. When added to the menu it runs but nothing happens.

    PROCEDURE ClassStyle;

    PROCEDURE changedoors(h :HANDLE);

    BEGIN

    SETRFIELD(h, 'door', 'IDLabelClass', 'Marks');

    ResetObject(h);

    END;

    BEGIN

    ForEachObject(changedoors, (INSYMBOL & INVIEWPORT & (PON='door')));

    END;

    Run(ClassStyle);

 

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...