Project

General

Profile

Actions

Bug #808

closed

Parameters not working properly on Instruction command with AOZ code.

Added by Brian Flanagan over 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
High
Target version:
Start date:
08/08/2021
Due date:
% Done:

0%

Estimated time:
Affected version:

Description

Example:

Instruction "Regular Polygon", x,y,radius,sides
    startX=x
    startY=y
    Print startX,startY,radius,sides
End Instruction

Regular Polygon 100,100,50,5

The above returns:
NaN NaN undefined undefined

This bug can be circumvented by grabbing the JavaScript equivalents of the parameters:

Instruction "Regular Polygon", x,y,radius,sides
    startX = { vars.x }
    startY = { vars.y }
    radius = { vars.radius }
    sides = { vars.sides }
    Print startX,startY,radius,sides
End Instruction

Regular Polygon 100,100,50,5

...which prints the proper results:
100 100 50 5

Actions

Also available in: Atom PDF