拿起放下物品
This commit is contained in:
@@ -35,7 +35,7 @@ namespace NBF
|
||||
/// 鱼线处理器
|
||||
/// </summary>
|
||||
public FLineHandler lineHandler;
|
||||
|
||||
|
||||
public Transform GearRoot;
|
||||
|
||||
// public FWaterDisplacement LureHookWaterDisplacement;
|
||||
@@ -60,6 +60,11 @@ namespace NBF
|
||||
|
||||
public IEnumerator Destroy()
|
||||
{
|
||||
if (GearRoot != null)
|
||||
{
|
||||
Object.Destroy(GearRoot.gameObject);
|
||||
}
|
||||
|
||||
yield return 1;
|
||||
}
|
||||
|
||||
@@ -134,8 +139,7 @@ namespace NBF
|
||||
lineItemInfo = child;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
yield return 1;
|
||||
if (Reel)
|
||||
@@ -151,18 +155,18 @@ namespace NBF
|
||||
{
|
||||
Bobber.Init(Player, this);
|
||||
}
|
||||
|
||||
|
||||
if (Hook)
|
||||
{
|
||||
Hook.Init(Player, this);
|
||||
// LureHookWaterDisplacement = Hook.GetComponent<FWaterDisplacement>();
|
||||
}
|
||||
|
||||
|
||||
if (Bait)
|
||||
{
|
||||
Bait.Init(Player, this);
|
||||
}
|
||||
|
||||
|
||||
if (Lure)
|
||||
{
|
||||
Lure.Init(Player, this);
|
||||
@@ -182,7 +186,6 @@ namespace NBF
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void CreateFishingHandler()
|
||||
{
|
||||
if (lineHandler == null)
|
||||
@@ -201,7 +204,6 @@ namespace NBF
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void CreateObiFishingLine(int currentLineTypeIndex)
|
||||
{
|
||||
// if ((bool)Owner.Gears.Reel && !currentLineHandler)
|
||||
@@ -211,10 +213,10 @@ namespace NBF
|
||||
var path =
|
||||
$"Assets/ResRaw/Prefabs/{indexNames[currentLineTypeIndex]}.prefab"; //$"GameItemsPrefabs/Lines/{indexNames[currentLineTypeIndex]}";
|
||||
var prefab = Assets.Load<GameObject>(path);
|
||||
|
||||
|
||||
// var toRodConnector = rodAsset.lineConnector.GetComponent<Rigidbody>();
|
||||
GameObject obj = Instantiate(prefab, GearRoot.position, Quaternion.identity, GearRoot);
|
||||
|
||||
|
||||
lineHandler = obj.GetComponent<FLineHandler>();
|
||||
// lineHandler.transform.SetParent(toRodConnector.transform);
|
||||
lineHandler.transform.position = Asset.lineConnector.position;
|
||||
@@ -226,7 +228,7 @@ namespace NBF
|
||||
SceneSettings.Instance.obiFixedUpdater.solvers.Add(obiSolver);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void SetRing(RodRingAsset ringAsset)
|
||||
{
|
||||
if (Asset.rings == null || Asset.rings.Length < 1) return;
|
||||
|
||||
Reference in New Issue
Block a user