📋 Metadata

💬 Content

Hi Roaoao thanks for all your previous help.

I’m trying to make a script run from pie menu editor (99% not mine)

https://pastebin.com/u3dTB8Gs

works fine when I run from the text editor but says this when I use pme with this command ‘execute_script(“scripts/vertex_color_objects_gradient_blue.py”)’

Error: Traceback (most recent call last):
File “C:\Users\Frankie\AppData\Roaming\Blender Foundation\Blender\2.79\scripts\addons\pie_menu_editor\ui_utils.py”, line 171, in execute_script
exec(marshal.load(f), pme.context.globals, exec_locals)
File “C:\Users\Frankie\AppData\Roaming\Blender Foundation\Blender\2.79\scripts\addons\pie_menu_editor\scripts\vertex_color_objects_gradient_blue.py”, line 96, in
remap_1 = remap(zheight, lower_old, upper_old, lower_new, upper_new)
File “C:\Users\Frankie\AppData\Roaming\Blender Foundation\Blender\2.79\scripts\addons\pie_menu_editor\scripts\vertex_color_objects_gradient_blue.py”, line 35, in remap
old_min = Vector((0.0, 0.0, lower_old))
NameError: name ‘Vector’ is not defined

any ideas?

Thank you!


🔗 View on Blender Artists