Files
test/tests/python
Sybren A. Stüvel d00e6e7353 Anim: update slot selection for Action Constraint
Like with NLA strips, Action assignment on Action Constraints needs to
have an extra step (compared to regular assignment to animated
data-blocks).

For the Action Constraint, the auto slot selection gets one more
fallback option (compared to the generic code). This is to support the
following scenario, which used to be necessary as a workaround for a bug
in Blender (#127976):

- Python script creates an Action,
- assigns it to the animated object,
- unassigns it from that object,
- and assigns it to the object's Action Constraint.

The generic code doesn't work for this. The first assignment would see
the slot `XXSlot`, and because it has never been used, just use it. This
would change its name to `OBSlot`. The assignment to the Action
Constraint would not see a 'virgin' slot, and thus not auto-select
`OBSlot`. This behaviour makes sense when assigning Actions in the
Action editor (it shouldn't automatically pick the first slot of
matching ID type), but for the Action Constraint I (Sybren) feel that it
could be a bit more 'enthousiastic' in auto-picking a slot.

Note that this is the same behaviour as for NLA strips, albeit for a
slightly different reason. Because of that it's not sharing code with
the NLA.

Pull Request: https://projects.blender.org/blender/blender/pulls/128892
2024-10-14 13:45:36 +02:00
..
2024-07-02 15:06:14 +10:00
2024-09-05 13:07:03 +10:00
2024-09-05 13:07:03 +10:00
2024-10-03 18:41:06 +02:00
2024-09-12 13:01:34 -04:00