Script Manager

脚本管理器

Open the Script Manager (Extensions / Script Manager).

打开脚本管理器(扩展/脚本管理器)。

The Script Manager lets you create and manage Python. scripts and even assign new icons so that you can later easily access these scripts in the Extensions menu under User Scripts. It is no longer necessary to create plugins.

脚本管理器允许您创建和管理 Python。脚本,甚至分配新的图标,以便您以后可以轻松地访问用户脚本下的扩展菜单这些脚本。不再需要创建插件。

Scripts created using the Script Manager are saved to the user Library / Scripts directory.

使用脚本管理器创建的脚本保存到用户 Library/Scripts 目录中。

User Buttons

用户按钮

Using the script field

使用脚本字段

The following interactive functions are available for the script field:

下面的交互式函数可用于脚本字段:

File Menu

文件菜单

New Script

新剧本

A new, untitled script will be created (however, scripts that were not saved will be saved to the prefs/_last_script folder in the user directory with the file extension *.py (Python); for example, if a script should cause the application to crash the script will itself will not be lost).

将创建一个新的未命名脚本(但是,未保存的脚本将被保存到用户目录中具有文件扩展名 * 的 prefs/_ last _ script 文件夹中。Py (Python) ; 例如,如果一个脚本导致应用程序崩溃,那么该脚本本身将不会丢失)。

Open Script...

开放脚本..。

Use this command to load non-write protected (non-encrypted) Python codes (*.py). The file selection dialog will jump directly to the proper directory.

使用此命令加载非写保护(非加密)的 Python 代码(* 。Py).文件选择对话框将直接跳转到正确的目录。

Import Script...

导入脚本..。

Use this command to import code into the Script Manager. The following file formats can be imported:

使用此命令将代码导入脚本管理器。可以导入以下文件格式:

*.py (Python)

* . py (Python)

Save Script
Save Script as...

将 ScriptSave 脚本保存为..。

Save the script currently selected under Script (unsaved scripts have a * in their name). A new name can be assigned if you select Save Script As. Scripts will be saved by default to the "library / scripts" user directory.

保存当前在脚本下选择的脚本(未保存的脚本名称中有 *)。如果选择“另存脚本为” ,则可以分配一个新名称。默认情况下,脚本将被保存到“ library/Scripts”用户目录中。

Save All Scripts

保存所有脚本

All new or modified scripts will be saved.

将保存所有新的或修改过的脚本。

Delete Script

删除脚本

The script currently selected under Script will be deleted after a security prompt is confirmed by you.

当前在脚本下选择的脚本将在安全提示符被您确认后被删除。

Duplicate Script

剧本复本

Duplicates the script currently selected under Script.

复制当前在脚本下选择的脚本。

Load Icon...

载入图标..。

Select a square bitmap that you want to use for this script. This icon will be displayed in the corresponding menu’s icon list and even in the Command Manager. Even alpha channels will be displayed.

选择要用于此脚本的正方形位图。此图标将显示在相应菜单的图标列表中,甚至在命令管理器中。甚至 alpha 通道也会显示出来。

Render Icon

渲染图标

If you are looking for the ideal image to use for your icon, this is the button for you – the current Cinema 4D scene will be rendered and this image can be used as your icon.

如果你正在寻找理想的图像使用你的图标,这是你的按钮-当前C4D 场景将被渲染,这个图像可以用作你的图标。

Edit menu

编辑菜单

Undo
Redo

Changes made to the code can be undone or redone.

对代码所做的更改可以撤消或重做。

Cut

Cuts out the selected code and copies it to the cache.

删除选定的代码并将其复制到缓存。

Copy

收到

Copies the selected code to the cache.

将选定的代码复制到缓存中。

Paste

粘贴

Pastes the cut or copied code from the cache to the selected location.

将剪切或复制的代码从缓存粘贴到选定位置。

Delete

删除

Deletes the selected code.

删除选定的代码。

Select All
Deselect All

选择 AllDeselect All

Selects or deselects all selected code. The code can also be deselected by clicking anywhere within the code window.

选择或取消选择所有选定的代码。也可以通过单击代码窗口中的任意位置取消选择代码。

Dialog

对话

Icon

图标

This is the icon (see next image) that has been assigned to the current script. An icon can be assigned or changed by selecting Load Icon … or Render Icon …

这是分配给当前脚本的图标(请参阅下一个图像)。可以通过选择加载图标... 或渲染图标来分配或更改图标。

You can simply drag & drop this icon onto any Icon Palette or into a Menu Manager.

您可以简单地拖放这个图标到任何图标调色板或菜单管理器。

Note 注意
In order to save the resulting configuration, you must select 为了保存生成的配置,必须选择Window / Customize / Save as Startup Layout 窗口/自定义/另存为启动布局.

Script

剧本

Here, all scripts in the directory library / scripts in the user directory will be shown with their file names. Scripts marked with a small x are not yet saved.

在这里,用户目录中的目录库/脚本中的所有脚本都会显示它们的文件名。带有小 x 标记的脚本尚未保存。

Shortcut

捷径

Click on this button to open the Customize Commands Manager where you can assign a keyboard shortcut to this script.

点击这个按钮可以打开自定义命令管理器,在这里你可以为这个脚本分配一个快捷键。

Execute

执行

Executes the script. Error messages will be output to the Console (main menu: Extensions / Console).

执行脚本。错误消息将输出到控制台(主菜单: Extensions/Console)。