Grasshopper

algorithmic modeling for Rhino

  Hello all

I am writing a very basic code in python to draw me a Fibonacci spiral in grasshopper, i have completed the code with a working Fibonacci function but when I try to run the code I get an error of

"Runtime error (ArgumentTypeException): stepfib() takes exactly 1 argument (2 given)
Traceback:
line 48, in script"

Here is the code:  forum%20GHPy.py

Thank you for your help

Views: 287

Attachments:

Replies to This Discussion

Hi George,

When writing python class methods, use the "self" as the first argument.
When calling a method of the class from another method of the same class add the "self." in front of it. For more info on classes and methods, check the python documentation.

Check the attached file.

Attachments:

Thank you works perfectly!

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service