예제 #1
0
 private void Awake()
 {
     pdaID      = GetComponent <NetworkIdentity>();
     pickupable = GetComponent <Pickupable>();
     storage    = GetComponent <ItemStorage>();
     flashlight = GetComponent <ItemLightControl>();
 }
예제 #2
0
 private void Awake()
 {
     pickupable   = GetComponent <Pickupable>();
     storage      = GetComponent <ItemStorage>();
     flashlight   = GetComponent <ItemLightControl>();
     actionButton = GetComponent <ItemActionButton>();
 }
예제 #3
0
        private IEnumerator LightsOutAfterTime(ItemLightControl lightController, SpriteHandler handler)
        {
            yield return(WaitFor.Seconds(runsOutOverSeconds));

            lightController.Toggle(false);
            handler.SetSpriteSO(offSprite);
        }
예제 #4
0
 private void Awake()
 {
     itemAttributes = GetComponent <ItemAttributesV2>();
     lightControl   = GetComponent <ItemLightControl>();
     spriteHandler  = GetComponentInChildren <SpriteHandler>();
     if (color == SwordColor.Random)
     {
         // Get random color
         color = (SwordColor)Enum.GetValues(typeof(SwordColor)).GetValue(Random.Range(1, 5));
     }
 }
예제 #5
0
 private void Awake()
 {
     lightControl = GetComponent <ItemLightControl>();
     if (runsOutOverTime)
     {
         destroyThisComponentOnOpen = false;
         offSprite = spriteHandler.GetCurrentSpriteSO();
     }
     if (glowHandler != null)
     {
         glowHandler.SetActive(false);
     }
     if (actionButton == null)
     {
         return;
     }
     actionButton.ServerActionClicked += Open;
 }
예제 #6
0
 private void Awake()
 {
     lightControl = GetComponent <ItemLightControl>();
     actionButton = GetComponent <ItemActionButton>();
 }
예제 #7
0
 private void Awake()
 {
     itemAttributes = GetComponent <ItemAttributesV2>();
     lightControl   = GetComponent <ItemLightControl>();
     spriteHandler  = GetComponentInChildren <SpriteHandler>();
 }
예제 #8
0
 /// <summary>
 /// Grabs the "ItemLightControl" component from the current gameObject, used to toggle the light, only does this once
 /// </summary>
 private void Start()
 {
     lightControl = GetComponent <ItemLightControl>();
 }
예제 #9
0
 private void Awake()
 {
     fireSource   = GetComponent <FireSource>();
     pickupable   = GetComponent <Pickupable>();
     lightControl = GetComponent <ItemLightControl>();
 }
예제 #10
0
 private void Awake()
 {
     pickupable   = GetComponent <Pickupable>();
     lightControl = GetComponent <ItemLightControl>();
 }
예제 #11
0
 /// <summary>
 /// Grabs the "ItemLightControl" component from the current gameObject, used to toggle the light, only does this once
 /// </summary>
 private void Start()
 {
     lightControl = gameObject.GetComponent <ItemLightControl>();
 }