mirror of
https://gitgud.io/c0ffeeeeeeee/rimworld-animations.git
synced 2026-06-18 19:35:58 +00:00
30 lines
832 B
C#
30 lines
832 B
C#
using LudeonTK;
|
|
using RimWorld;
|
|
using RimWorld.QuestGen;
|
|
using rjw;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Verse;
|
|
|
|
namespace Rimworld_Animations
|
|
{
|
|
internal static class DebugActions
|
|
{
|
|
[DebugAction("Rimworld Animations", "Stop all Animations", allowedGameStates = AllowedGameStates.PlayingOnMap)]
|
|
public static void StopAll()
|
|
{
|
|
//adds stop all animations option to debug menu
|
|
//stops all pawns on map animating
|
|
foreach (Map m in Current.Game.Maps)
|
|
{
|
|
foreach (Pawn p in m.spawnedThings.Where(p => p is Pawn))
|
|
{
|
|
p.TryGetComp<CompExtendedAnimator>()?.StopAnimating();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|