r2mods/ilspy_dump/ror2_csproj/EntityStates.Interactables..../GoldBeaconBaseState.cs

38 lines
913 B
C#
Raw Permalink Normal View History

2024-10-04 07:26:37 +00:00
using RoR2;
using RoR2.Hologram;
using UnityEngine;
namespace EntityStates.Interactables.GoldBeacon;
public class GoldBeaconBaseState : BaseState
{
protected void SetReady(bool ready)
{
Transform modelTransform = GetModelTransform();
if ((bool)modelTransform)
{
PrintController component = modelTransform.GetComponent<PrintController>();
component.paused = !ready;
if (!ready)
{
component.age = 0f;
}
ChildLocator component2 = modelTransform.GetComponent<ChildLocator>();
if ((bool)component2)
{
component2.FindChild("Purchased").gameObject.SetActive(ready);
}
}
PurchaseInteraction component3 = GetComponent<PurchaseInteraction>();
if ((bool)component3)
{
component3.SetAvailable(!ready);
}
HologramProjector component4 = GetComponent<HologramProjector>();
if ((bool)component4)
{
component4.hologramPivot.gameObject.SetActive(!ready);
}
}
}