66 lines
1.4 KiB
C#
66 lines
1.4 KiB
C#
using UnityEngine;
|
|
|
|
public class InteractiveObiectsEvents : MonoBehaviour
|
|
{
|
|
private void Start()
|
|
{
|
|
}
|
|
|
|
private void Update()
|
|
{
|
|
}
|
|
|
|
public void UnlockReel()
|
|
{
|
|
if ((bool)ScriptsHandler.Instance.m_PlayerMain.currentRod)
|
|
{
|
|
Rod component = ScriptsHandler.Instance.m_PlayerMain.currentRightHandObject.GetComponent<Rod>();
|
|
if (component != null && component.fishingLine.reel != null && !component.fishingLine.reel.animator.GetBool("Unlock"))
|
|
{
|
|
ScriptsHandler.Instance.m_InteractionControl.StartReelUnlockInteractionWithLeftHand();
|
|
}
|
|
}
|
|
}
|
|
|
|
public void ThrowCurrentRod()
|
|
{
|
|
if ((bool)ScriptsHandler.Instance.m_PlayerMain.currentRod)
|
|
{
|
|
Rod component = ScriptsHandler.Instance.m_PlayerMain.currentRightHandObject.GetComponent<Rod>();
|
|
if (component != null)
|
|
{
|
|
component.Throw();
|
|
}
|
|
}
|
|
}
|
|
|
|
public void StopThrowCurrentRod()
|
|
{
|
|
if ((bool)ScriptsHandler.Instance.m_PlayerMain.currentRod)
|
|
{
|
|
Rod component = ScriptsHandler.Instance.m_PlayerMain.currentRightHandObject.GetComponent<Rod>();
|
|
Debug.Log("STOP");
|
|
if (component != null)
|
|
{
|
|
component.isTrowing = false;
|
|
}
|
|
}
|
|
}
|
|
|
|
public void ShowRodFromSlot()
|
|
{
|
|
}
|
|
|
|
public void HideRodToSlot()
|
|
{
|
|
if ((bool)ScriptsHandler.Instance.m_PlayerMain.currentRod)
|
|
{
|
|
Object.Destroy(ScriptsHandler.Instance.m_PlayerMain.currentRightHandObject.GetComponent<Rod>().gameObject);
|
|
}
|
|
}
|
|
|
|
public void ShowFishCatchPanel()
|
|
{
|
|
}
|
|
}
|