Открыть боковую панель
nikitronn
sverchok
Коммиты
d1eaad13
Коммит
d1eaad13
создал
Май 31, 2022
по автору
Durman
Просмотр файлов
fix
#4410
владелец
f7537fba
Изменения
1
Скрыть пробелы
Построчно
Рядом
utils/sv_json_struct.py
Просмотр файла @
d1eaad13
...
@@ -642,13 +642,15 @@ class NodeStruct(Struct):
...
@@ -642,13 +642,15 @@ class NodeStruct(Struct):
# it will cause replacing of all sockets with wrong identifiers in the group node.
# it will cause replacing of all sockets with wrong identifiers in the group node.
# clearing and adding sockets of Group input and Group output nodes
# clearing and adding sockets of Group input and Group output nodes
# immediately cause their rebuilding by Blender, so JSON file does not save information about their sockets.
# immediately cause their rebuilding by Blender, so JSON file does not save information about their sockets.
node
.
inputs
.
clear
()
if
node
.
bl_idname
not
in
{
'NodeGroupInput'
,
'NodeGroupOutput'
}:
node
.
inputs
.
clear
()
for
sock_identifier
,
raw_struct
in
self
.
_struct
.
get
(
"inputs"
,
dict
()).
items
():
for
sock_identifier
,
raw_struct
in
self
.
_struct
.
get
(
"inputs"
,
dict
()).
items
():
with
self
.
logger
.
add_fail
(
"Add in socket"
,
with
self
.
logger
.
add_fail
(
"Add in socket"
,
f
"Tree:
{
node
.
id_data
.
name
}
, Node
{
node
.
name
}
, Sock:
{
sock_identifier
}
"
):
f
"Tree:
{
node
.
id_data
.
name
}
, Node
{
node
.
name
}
, Sock:
{
sock_identifier
}
"
):
factories
.
sock
(
sock_identifier
,
self
.
logger
,
raw_struct
).
build
(
node
.
inputs
,
factories
,
imported_data
)
factories
.
sock
(
sock_identifier
,
self
.
logger
,
raw_struct
).
build
(
node
.
inputs
,
factories
,
imported_data
)
node
.
outputs
.
clear
()
if
node
.
bl_idname
not
in
{
'NodeGroupInput'
,
'NodeGroupOutput'
}:
node
.
outputs
.
clear
()
for
sock_identifier
,
raw_struct
in
self
.
_struct
.
get
(
"outputs"
,
dict
()).
items
():
for
sock_identifier
,
raw_struct
in
self
.
_struct
.
get
(
"outputs"
,
dict
()).
items
():
with
self
.
logger
.
add_fail
(
"Add out socket"
,
with
self
.
logger
.
add_fail
(
"Add out socket"
,
f
"Tree:
{
node
.
id_data
.
name
}
, Node
{
node
.
name
}
, Sock:
{
sock_identifier
}
"
):
f
"Tree:
{
node
.
id_data
.
name
}
, Node
{
node
.
name
}
, Sock:
{
sock_identifier
}
"
):
...
...
Редактирование
Предварительный просмотр
Поддерживает Markdown
0%
Попробовать снова
или
прикрепить новый файл
.
Отмена
You are about to add
0
people
to the discussion. Proceed with caution.
Сначала завершите редактирование этого сообщения!
Отмена
Пожалуйста,
зарегистрируйтесь
или
войдите
чтобы прокомментировать