mirror of
https://gitgud.io/AbstractConcept/rimworld-animation-studio.git
synced 2024-08-15 00:43:27 +00:00
v1.0.3
- Fixed an issue where changing the order of actors in the animation was not being perpetuated across all animation stages
This commit is contained in:
parent
b6d3df800d
commit
ab53ed284f
46 changed files with 71 additions and 62 deletions
|
@ -8,7 +8,7 @@ namespace RimWorldAnimationStudio
|
|||
public static class Constants
|
||||
{
|
||||
// Project data
|
||||
public static string currentVersion = "1.0.2";
|
||||
public static string currentVersion = "1.0.3";
|
||||
public static string projectHome = "https://gitgud.io/AbstractConcept/rimworld-animation-studio";
|
||||
public static string projectWiki = "https://gitgud.io/AbstractConcept/rimworld-animation-studio/-/wikis/home";
|
||||
|
||||
|
|
|
@ -99,12 +99,16 @@ namespace RimWorldAnimationStudio
|
|||
Workspace.animationDef.Actors[startIndex] = Workspace.animationDef.Actors[startIndex + delta];
|
||||
Workspace.animationDef.Actors[startIndex + delta] = actor;
|
||||
|
||||
PawnAnimationClip clip = Workspace.GetPawnAnimationClip(startIndex);
|
||||
Workspace.GetCurrentAnimationStage().AnimationClips[startIndex] = Workspace.GetCurrentAnimationStage().AnimationClips[startIndex + delta];
|
||||
Workspace.GetCurrentAnimationStage().AnimationClips[startIndex + delta] = clip;
|
||||
foreach (AnimationStage stage in Workspace.animationDef.animationStages)
|
||||
{
|
||||
int stageID = stage.GetStageID();
|
||||
|
||||
PawnAnimationClip clip = Workspace.GetPawnAnimationClip(stageID, startIndex);
|
||||
Workspace.GetAnimationStage(stageID).AnimationClips[startIndex] = Workspace.GetAnimationStage(stageID).AnimationClips[startIndex + delta];
|
||||
Workspace.GetAnimationStage(stageID).AnimationClips[startIndex + delta] = clip;
|
||||
}
|
||||
|
||||
Workspace.ActorID = startIndex + delta;
|
||||
|
||||
Workspace.RecordEvent("Timeline move");
|
||||
|
||||
return true;
|
||||
|
|
|
@ -139,6 +139,11 @@ namespace RimWorldAnimationStudio
|
|||
return animationDef?.AnimationStages.ElementAtOrDefault(stageID);
|
||||
}
|
||||
|
||||
public static PawnAnimationClip GetPawnAnimationClip(int stageID, int actorID)
|
||||
{
|
||||
return GetAnimationStage(stageID)?.AnimationClips.ElementAtOrDefault(actorID);
|
||||
}
|
||||
|
||||
public static PawnAnimationClip GetPawnAnimationClip(int actorID)
|
||||
{
|
||||
return GetCurrentAnimationStage()?.AnimationClips.ElementAtOrDefault(actorID);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue