修改动画回调事件
This commit is contained in:
@@ -22,15 +22,56 @@ namespace NBF
|
||||
|
||||
#region Rod专属
|
||||
|
||||
private bool _stretchRope;
|
||||
|
||||
public bool StretchRope
|
||||
{
|
||||
get => _stretchRope;
|
||||
set
|
||||
{
|
||||
_stretchRope = value;
|
||||
Scene.EventComponent.Publish(new PlayerItemRodLingChangeEvent
|
||||
{
|
||||
Item = this
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
private float _lineLength = 5f;
|
||||
|
||||
/// <summary>
|
||||
/// 线长度
|
||||
/// </summary>
|
||||
public float LineLength = 1.5f;
|
||||
public float LineLength
|
||||
{
|
||||
get => _lineLength;
|
||||
set
|
||||
{
|
||||
_lineLength = value;
|
||||
Scene.EventComponent.Publish(new PlayerItemRodLingChangeEvent
|
||||
{
|
||||
Item = this
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
private float _floatLength = 0.3f;
|
||||
|
||||
/// <summary>
|
||||
/// 浮漂线长度
|
||||
/// </summary>
|
||||
public float FloatLength = 0.5f;
|
||||
public float FloatLength
|
||||
{
|
||||
get => _floatLength;
|
||||
set
|
||||
{
|
||||
_floatLength = value;
|
||||
Scene.EventComponent.Publish(new PlayerItemRodLingChangeEvent
|
||||
{
|
||||
Item = this
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
private float _tension;
|
||||
|
||||
@@ -40,13 +81,17 @@ namespace NBF
|
||||
public float Tension
|
||||
{
|
||||
get => _tension;
|
||||
private set
|
||||
set
|
||||
{
|
||||
if (!Mathf.Approximately(_tension, value))
|
||||
{
|
||||
_tension = value;
|
||||
// OnTensionChanged?.Invoke(_tension);
|
||||
}
|
||||
|
||||
Scene.EventComponent.Publish(new PlayerItemRodLingChangeEvent
|
||||
{
|
||||
Item = this
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user