quantum-space-buddies/QSB/Tools/FlashlightTool/FlashlightCreator.cs

15 lines
397 B
C#
Raw Normal View History

2021-12-14 22:53:53 +00:00
using QSB.Player;
2022-03-03 03:46:33 +00:00
namespace QSB.Tools.FlashlightTool;
2023-07-28 18:49:30 +00:00
public static class FlashlightCreator
{
2022-03-03 03:46:33 +00:00
internal static void CreateFlashlight(PlayerInfo player)
{
2022-03-03 03:46:33 +00:00
var REMOTE_FlashlightRoot = player.CameraBody.transform.Find("REMOTE_FlashlightRoot").gameObject;
2022-03-03 03:46:33 +00:00
var qsbFlashlight = REMOTE_FlashlightRoot.GetComponent<QSBFlashlight>();
qsbFlashlight.Player = player;
qsbFlashlight.Init();
}
}