From 930911e7df64bb031dc9fb12d69a7fc9e0e9130a Mon Sep 17 00:00:00 2001
From: "DESKTOP-5RP3AKU\\Jisol" <2858626794@qq.com>
Date: Mon, 21 Oct 2024 04:04:13 +0800
Subject: [PATCH] =?UTF-8?q?=E8=BD=BB=E8=BD=BB=E6=9D=BE=E6=9D=BE=E6=94=B9?=
=?UTF-8?q?=E6=88=90=E5=AE=9A=E7=82=B9=E6=95=B0=E5=92=AF?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../GAS/AttributeSet/AttributeSetClassGen.cs | 15 +-
.../Editor/GAS/Attributes/AttributeAsset.cs | 7 +-
.../Editor/GAS/Effect/ModifierConfigEditor.cs | 4 +-
.../JNGame/Root/Math/BaseType/LFloat.cs | 14 +-
.../HotScripts/JNGame/Root/Math/LMath.cs | 8 +
.../JNGame/Runtime/GAS/General/GASTimer.cs | 3 +-
.../GAS/General/Util/DebugExtension.cs | 245 ++++++-------
.../GAS/Runtime/Ability/AbilitySpec.cs | 5 +-
.../TimelineAbility/TimelineAbility.cs | 7 +-
.../TimelineAbility/TimelineAbilityAsset.cs | 3 +-
.../TimelineAbility/TimelineAbilityPlayer.cs | 5 +-
.../ReleaseGameplayEffectTrackData.cs | 6 +-
.../Runtime/Attribute/AttributeAggregator.cs | 23 +-
.../GAS/Runtime/Attribute/AttributeBase.cs | 71 ++--
.../Runtime/Attribute/Value/AttributeValue.cs | 28 +-
.../GAS/Runtime/AttributeSet/AttributeSet.cs | 6 +-
.../AttributeSet/AttributeSetContainer.cs | 13 +-
.../Component/AbilitySystemComponent.cs | 7 +-
.../Component/IAbilitySystemComponent.cs | 7 +-
.../CompositeAttribute/CompositeAttribute.cs | 33 +-
.../GAS/Runtime/Effects/CooldownTimer.cs | 8 +-
.../GAS/Runtime/Effects/GameplayEffect.cs | 5 +-
.../Effects/GameplayEffectContainer.cs | 5 +-
.../Effects/GameplayEffectPeriodTicker.cs | 7 +-
.../GAS/Runtime/Effects/GameplayEffectSpec.cs | 44 +--
.../AttrBasedWithStackModCalculation.cs | 7 +-
.../Modifier/AttributeBasedModCalculation.cs | 6 +-
.../Modifier/GameplayEffectModifier.cs | 11 +-
.../Modifier/ModifierMagnitudeCalculation.cs | 3 +-
.../Modifier/ScalableFloatModCalculation.cs | 15 +-
.../SetByCallerFromNameModCalculation.cs | 3 +-
.../SetByCallerFromTagModCalculation.cs | 3 +-
.../Effects/Modifier/StackModCalculation.cs | 11 +-
.../Events/EventAttributeChanged.cs | 11 +-
.../HotScripts/JNGame/Runtime/GAS/Wiki/MMC.md | 6 +-
.../Assets/Resources/GASSamples/GASMain.unity | 2 +-
.../GameplayAbilityLib/JisolDemo1.asset | 3 +-
.../GameplayEffectLib/GE_JisolDemo1.asset | 5 +-
.../GameplayCue/GameplayCue_PlayerDemo01.cs | 2 +-
.../Scripts/GAS/MMC/AttrModCalculation.cs | 2 +-
.../GASSamples/Scripts/Gen/GAttrSetLib.gen.cs | 15 +-
JNFrame2/Logs/AssetImportWorker0.log | 339 ++++++++++++++++++
JNFrame2/Logs/AssetImportWorker1.log | 331 +++++++++++++++++
.../shadercompiler-AssetImportWorker0.log | 6 +
...hadercompiler-UnityShaderCompiler.exe0.log | 18 +
JNFrame2/ProjectSettings/AttributeAsset.asset | 9 +-
46 files changed, 1070 insertions(+), 317 deletions(-)
create mode 100644 JNFrame2/Logs/AssetImportWorker0.log
create mode 100644 JNFrame2/Logs/AssetImportWorker1.log
create mode 100644 JNFrame2/Logs/shadercompiler-AssetImportWorker0.log
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/AttributeSet/AttributeSetClassGen.cs b/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/AttributeSet/AttributeSetClassGen.cs
index 5557a8a7..d3d5a823 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/AttributeSet/AttributeSetClassGen.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/AttributeSet/AttributeSetClassGen.cs
@@ -70,6 +70,7 @@ namespace GAS.Editor
writer.WriteLine("using System;");
writer.WriteLine("using System.Collections.Generic;");
+ writer.WriteLine("using JNGame.Math;");
writer.WriteLine("");
@@ -97,14 +98,14 @@ namespace GAS.Editor
writer.WriteLine("");
{
writer.WriteLine($"/// {attributeAccessor.Comment}");
- writer.WriteLine($"public AttributeBase {validAttrName} {{ get; }} = new(\"AS_{validName}\", \"{attributeName}\", {attributeAccessor.DefaultValue}f, CalculateMode.{attributeAccessor.CalculateMode}, (SupportedOperation){(byte)attributeAccessor.SupportedOperation}, {(attributeAccessor.LimitMinValue ? attributeAccessor.MinValue + "f" : "float.MinValue")}, {(attributeAccessor.LimitMaxValue ? attributeAccessor.MaxValue + "f" : "float.MaxValue")});");
+ writer.WriteLine($"public AttributeBase {validAttrName} {{ get; }} = new(\"AS_{validName}\", \"{attributeName}\", new LFloat(true,{attributeAccessor.DefaultValue.rawValue}), {(attributeAccessor.LimitMinValue ? $"new LFloat(true,{attributeAccessor.MinValue.rawValue})" : "LFloat.MinValue")}, {(attributeAccessor.LimitMaxValue ? $"new LFloat(true,{attributeAccessor.MaxValue.rawValue})" : "LFloat.MaxValue")}, CalculateMode.{attributeAccessor.CalculateMode}, (SupportedOperation){(byte)attributeAccessor.SupportedOperation});");
writer.WriteLine("");
- writer.WriteLine($"public void Init{validAttrName}(float value) => {validAttrName}.Init(value);");
- writer.WriteLine($"public void SetCurrent{validAttrName}(float value) => {validAttrName}.SetCurrentValue(value);");
- writer.WriteLine($"public void SetBase{validAttrName}(float value) => {validAttrName}.SetBaseValue(value);");
- writer.WriteLine($"public void SetMin{validAttrName}(float value) => {validAttrName}.SetMinValue(value);");
- writer.WriteLine($"public void SetMax{validAttrName}(float value) => {validAttrName}.SetMaxValue(value);");
- writer.WriteLine($"public void SetMinMax{validAttrName}(float min, float max) => {validAttrName}.SetMinMaxValue(min, max);");
+ writer.WriteLine($"public void Init{validAttrName}(LFloat value) => {validAttrName}.Init(value);");
+ writer.WriteLine($"public void SetCurrent{validAttrName}(LFloat value) => {validAttrName}.SetCurrentValue(value);");
+ writer.WriteLine($"public void SetBase{validAttrName}(LFloat value) => {validAttrName}.SetBaseValue(value);");
+ writer.WriteLine($"public void SetMin{validAttrName}(LFloat value) => {validAttrName}.SetMinValue(value);");
+ writer.WriteLine($"public void SetMax{validAttrName}(LFloat value) => {validAttrName}.SetMaxValue(value);");
+ writer.WriteLine($"public void SetMinMax{validAttrName}(LFloat min, LFloat max) => {validAttrName}.SetMinMaxValue(min, max);");
}
writer.WriteLine("");
writer.WriteLine($"#endregion {attributeName}");
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Attributes/AttributeAsset.cs b/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Attributes/AttributeAsset.cs
index 4f58e3a2..a47ec282 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Attributes/AttributeAsset.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Attributes/AttributeAsset.cs
@@ -5,6 +5,7 @@ using GAS.Editor.General;
using GAS.General;
using GAS.General.Validation;
using GAS.Runtime;
+using JNGame.Math;
using Sirenix.OdinInspector;
using UnityEditor;
using UnityEngine;
@@ -191,7 +192,7 @@ namespace GAS.Editor
[DelayedProperty]
[PropertyOrder(5)]
[HorizontalGroup("$DisplayName/Values")]
- public float DefaultValue = 0f;
+ public LFloat DefaultValue = LFloat.L0;
[FoldoutGroup("$DisplayName")]
[LabelText("最小值"), LabelWidth(40)]
@@ -207,7 +208,7 @@ namespace GAS.Editor
[PropertyOrder(6)]
[EnableIf("LimitMinValue")]
[HorizontalGroup("$DisplayName/Values")]
- public float MinValue = float.MinValue;
+ public LFloat MinValue = LFloat.MinValue;
[FoldoutGroup("$DisplayName")]
[LabelText("最大值"), LabelWidth(50)]
@@ -222,7 +223,7 @@ namespace GAS.Editor
[PropertyOrder(7)]
[EnableIf("LimitMaxValue")]
[HorizontalGroup("$DisplayName/Values")]
- public float MaxValue = float.MaxValue;
+ public LFloat MaxValue = LFloat.MaxValue;
}
}
}
\ No newline at end of file
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Effect/ModifierConfigEditor.cs b/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Effect/ModifierConfigEditor.cs
index afd54f08..7bbfee82 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Effect/ModifierConfigEditor.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Editor/GAS/Effect/ModifierConfigEditor.cs
@@ -1,3 +1,5 @@
+using JNGame.Math;
+
#if UNITY_EDITOR
namespace GAS.Editor
{
@@ -41,7 +43,7 @@ namespace GAS.Editor
EditorGUILayout.BeginHorizontal();
EditorGUILayout.LabelField("Value:", GUILayout.Width(100));
- _sourceModifier.ModiferMagnitude = EditorGUILayout.FloatField("", _sourceModifier.ModiferMagnitude);
+ _sourceModifier.ModiferMagnitude = EditorGUILayout.FloatField("", _sourceModifier.ModiferMagnitude).ToLFloat();
EditorGUILayout.EndHorizontal();
EditorGUILayout.Space();
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Root/Math/BaseType/LFloat.cs b/JNFrame2/Assets/HotScripts/JNGame/Root/Math/BaseType/LFloat.cs
index bf67e473..514a4d79 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Root/Math/BaseType/LFloat.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Root/Math/BaseType/LFloat.cs
@@ -621,12 +621,17 @@ namespace JNGame.Math
/// 毫秒单位时间 = 0.001f
///
public static readonly LFloat EPS_1MS = new LFloat(null, 1L);
-
+
+
+ ///
+ /// 0
+ ///
+ public static LFloat L0 => 0.ToLFloat();
///
/// 10
///
- public static LFloat L05 => new("",500);
+ public static LFloat L0D5 => new("",500);
///
/// 10
@@ -652,6 +657,11 @@ namespace JNGame.Math
/// 10000
///
public static readonly LFloat L10000 = 10000.ToLFloat();
+
+ ///
+ /// 360
+ ///
+ public static readonly LFloat L360 = 360.ToLFloat();
#endregion
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Root/Math/LMath.cs b/JNFrame2/Assets/HotScripts/JNGame/Root/Math/LMath.cs
index 28bc99ca..b79009c0 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Root/Math/LMath.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Root/Math/LMath.cs
@@ -577,6 +577,14 @@ namespace JNGame.Math
#region Min、Max、Clamp相关
+ public static bool Approximately(LFloat a, LFloat b)
+ {
+ // 计算两个浮点数之间的差的绝对值
+ float difference = Abs(a - b);
+ // 检查差的绝对值是否小于阈值
+ return difference < LFloat.EPSILON;
+ }
+
public static int Clamp(int value, int min, int max)
{
if (value < min)
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/GASTimer.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/GASTimer.cs
index 6bfb7c37..a502c631 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/GASTimer.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/GASTimer.cs
@@ -1,5 +1,6 @@
using System;
using GAS.Runtime;
+using JNGame.Math;
using UnityEngine;
namespace GAS.General
@@ -17,7 +18,7 @@ namespace GAS.General
public static int CurrentFrameCount => _currentFrameCount;
public static void UpdateCurrentFrameCount()
{
- _currentFrameCount = Mathf.FloorToInt((Timestamp() - _startTimestamp) / 1000f * JexGasManager.FrameRate);
+ _currentFrameCount = LMath.FloorToInt((Timestamp() - _startTimestamp) / LFloat.L1000 * JexGasManager.FrameRate);
}
private static long _startTimestamp;
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/Util/DebugExtension.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/Util/DebugExtension.cs
index 06bb1ef7..c8a544c9 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/Util/DebugExtension.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/General/Util/DebugExtension.cs
@@ -1,17 +1,18 @@
-using UnityEngine;
+using JNGame.Math;
+using UnityEngine;
namespace GAS.General
{
public static class DebugExtension
{
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DebugBox(Vector2 center, Vector2 size, float angle, Color color, float showTime)
+ public static void DebugBox(LVector2 center, LVector2 size, LFloat angle, Color color, LFloat showTime)
{
- var halfSize = size * 0.5f;
- var p1 = new Vector2(center.x - halfSize.x, center.y - halfSize.y);
- var p2 = new Vector2(center.x + halfSize.x, center.y - halfSize.y);
- var p3 = new Vector2(center.x + halfSize.x, center.y + halfSize.y);
- var p4 = new Vector2(center.x - halfSize.x, center.y + halfSize.y);
+ var halfSize = size * LFloat.L0D5;
+ var p1 = new LVector2(center.x - halfSize.x, center.y - halfSize.y);
+ var p2 = new LVector2(center.x + halfSize.x, center.y - halfSize.y);
+ var p3 = new LVector2(center.x + halfSize.x, center.y + halfSize.y);
+ var p4 = new LVector2(center.x - halfSize.x, center.y + halfSize.y);
// p1 绕center旋转angle角度
p1 = RotatePoint(center, p1, angle);
p2 = RotatePoint(center, p2, angle);
@@ -23,24 +24,24 @@ namespace GAS.General
DrawLine(p4, p1, color, showTime);
}
- public static Vector2 RotatePoint(Vector2 center, Vector2 point, float angle)
+ public static LVector2 RotatePoint(LVector2 center, LVector2 point, LFloat angle)
{
- var cos = Mathf.Cos(angle * Mathf.Deg2Rad);
- var sin = Mathf.Sin(angle * Mathf.Deg2Rad);
+ var cos = LMath.Cos(angle * LMath.Deg2Rad);
+ var sin = LMath.Sin(angle * LMath.Deg2Rad);
var x = cos * (point.x - center.x) - sin * (point.y - center.y) + center.x;
var y = sin * (point.x - center.x) + cos * (point.y - center.y) + center.y;
- return new Vector2(x, y);
+ return new LVector2(x, y);
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DebugDrawCircle(Vector2 center, float radius, Color color, float showTime, float segments = 120)
+ public static void DebugDrawCircle(LVector2 center, LFloat radius, Color color, LFloat showTime, LFloat segments = default) // segments = 120
{
- var step = 360f / segments;
- var from = center + new Vector2(radius, 0);
+ var step = LFloat.L360 / segments;
+ var from = center + new LVector2(radius, LFloat.L0);
for (var i = 0; i < segments; i++)
{
- var to = center + new Vector2(radius * Mathf.Cos((i + 1) * step * Mathf.Deg2Rad),
- radius * Mathf.Sin((i + 1) * step * Mathf.Deg2Rad));
+ var to = center + new LVector2(radius * LMath.Cos((i + 1) * step * LMath.Deg2Rad),
+ radius * LMath.Sin((i + 1) * step * LMath.Deg2Rad));
DrawLine(from, to, color, showTime);
from = to;
}
@@ -52,20 +53,20 @@ namespace GAS.General
/// 位置, 圆心
/// 旋转
/// 半径
- /// 分段数(建议与角度适配, 如每10°分一段: segments = Mathf.CeilToInt(angle / 10))
+ /// 分段数(建议与角度适配, 如每10°分一段: segments = LMath.CeilToInt(angle / 10))
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawCircle(in Vector3 position, in Quaternion rotation, float radius, int segments = 36,
- in Color? color = null, float duration = 0f)
+ public static void DrawCircle(in LVector3 position, in LQuaternion rotation, LFloat radius, int segments = 36,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
DrawArc(position, rotation, radius, 360, segments, color, duration);
}
- public static void DrawCircle(in Vector3 position, in Vector3 forward, float radius, int segments = 36,
- in Color? color = null, float duration = 0f)
+ public static void DrawCircle(in LVector3 position, in LVector3 forward, LFloat radius, int segments = 36,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawCircle(position, Quaternion.LookRotation(forward), radius, segments, color, duration);
+ DrawCircle(position, LQuaternion.LookRotation(forward), radius, segments, color, duration);
}
///
@@ -75,33 +76,33 @@ namespace GAS.General
/// 旋转
/// 半径
/// 角度
- /// 分段数(建议与角度适配, 如每10°分一段: segments = Mathf.CeilToInt(angle / 10))(建议与角度适配, 如每10°分一段: segments = Mathf.CeilToInt(angle / 10))
+ /// 分段数(建议与角度适配, 如每10°分一段: segments = LMath.CeilToInt(angle / 10))(建议与角度适配, 如每10°分一段: segments = LMath.CeilToInt(angle / 10))
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawArc(in Vector3 position, in Quaternion rotation, float radius, float angle, int segments = 12,
- in Color? color = null, float duration = 0f)
+ public static void DrawArc(in LVector3 position, in LQuaternion rotation, LFloat radius, LFloat angle, int segments = 12,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
if (angle <= 0) return;
if (radius <= 0) return;
if (segments <= 0) return;
var angleStep = angle / segments;
- var lastPoint = position + rotation * (Vector3.right * radius);
+ var lastPoint = position + rotation * (LVector3.Right * radius);
for (int i = 1; i <= segments; i++)
{
var currentAngle = i * angleStep;
- var nextPoint = position + rotation * (Quaternion.Euler(0, currentAngle, 0) * Vector3.right * radius);
+ var nextPoint = position + rotation * (LQuaternion.Euler(0, currentAngle, 0) * LVector3.Right * radius);
DrawLine(lastPoint, nextPoint, color, duration);
lastPoint = nextPoint;
}
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawArc(in Vector3 position, in Vector3 forward, float radius, float angle, int segments = 12,
- in Color? color = null, float duration = 0f)
+ public static void DrawArc(in LVector3 position, in LVector3 forward, LFloat radius, LFloat angle, int segments = 12,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawArc(position, Quaternion.LookRotation(forward), radius, angle, segments, color, duration);
+ DrawArc(position, LQuaternion.LookRotation(forward), radius, angle, segments, color, duration);
}
///
@@ -111,27 +112,27 @@ namespace GAS.General
/// 旋转
/// 外圈半径
/// 内圈半径
- /// 分段数(建议与角度适配, 如每10°分一段: segments = Mathf.CeilToInt(angle / 10))
+ /// 分段数(建议与角度适配, 如每10°分一段: segments = LMath.CeilToInt(angle / 10))
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawRing(in Vector3 position, in Quaternion rotation, float outerRadius, float innerRadius, int segments = 36,
- in Color? color = null, float duration = 0f)
+ public static void DrawRing(in LVector3 position, in LQuaternion rotation, LFloat outerRadius, LFloat innerRadius, int segments = 36,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
if (outerRadius <= 0) return;
if (segments <= 0) return;
- innerRadius = Mathf.Clamp(innerRadius, 0, outerRadius);
+ innerRadius = LMath.Clamp(innerRadius, LFloat.L0, outerRadius);
// 计算圆的每个点的位置
- var angleStep = 360f / segments;
- var lastOuterPoint = position + rotation * (Vector3.right * outerRadius);
- var lastInnerPoint = position + rotation * (Vector3.right * innerRadius);
+ var angleStep = LFloat.L360 / segments;
+ var lastOuterPoint = position + rotation * (LVector3.Right * outerRadius);
+ var lastInnerPoint = position + rotation * (LVector3.Right * innerRadius);
for (int i = 1; i <= segments; i++)
{
var angle = i * angleStep;
- var nextOuterPoint = position + rotation * (Quaternion.Euler(0, angle, 0) * Vector3.right * outerRadius);
- var nextInnerPoint = position + rotation * (Quaternion.Euler(0, angle, 0) * Vector3.right * innerRadius);
+ var nextOuterPoint = position + rotation * (LQuaternion.Euler(0, angle, 0) * LVector3.Right * outerRadius);
+ var nextInnerPoint = position + rotation * (LQuaternion.Euler(0, angle, 0) * LVector3.Right * innerRadius);
DrawLine(lastOuterPoint, nextOuterPoint, color, duration);
DrawLine(lastInnerPoint, nextInnerPoint, color, duration);
DrawLine(nextOuterPoint, nextInnerPoint, color, duration);
@@ -141,10 +142,10 @@ namespace GAS.General
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawRing(in Vector3 position, in Vector3 forward, float outerRadius, float innerRadius, int segments = 36,
- in Color? color = null, float duration = 0f)
+ public static void DrawRing(in LVector3 position, in LVector3 forward, LFloat outerRadius, LFloat innerRadius, int segments = 36,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawRing(position, Quaternion.LookRotation(forward), outerRadius, innerRadius, segments, color, duration);
+ DrawRing(position, LQuaternion.LookRotation(forward), outerRadius, innerRadius, segments, color, duration);
}
///
@@ -156,16 +157,16 @@ namespace GAS.General
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawRectangle(in Vector3 position, in Quaternion rotation, in Vector2 size,
- in Color? color = null, float duration = 0f)
+ public static void DrawRectangle(in LVector3 position, in LQuaternion rotation, in LVector2 size,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
// 计算矩形的四个角点在局部坐标系中的位置
- var halfSize = new Vector3(size.x * 0.5f, 0, size.y * 0.5f);
- var corners = new Vector3[4];
- corners[0] = new Vector3(-halfSize.x, 0, -halfSize.z); // 左下角
- corners[1] = new Vector3(halfSize.x, 0, -halfSize.z); // 右下角
- corners[2] = new Vector3(halfSize.x, 0, halfSize.z); // 右上角
- corners[3] = new Vector3(-halfSize.x, 0, halfSize.z); // 左上角
+ var halfSize = new LVector3(size.x * LFloat.L0D5, LFloat.L0, size.y * LFloat.L0D5);
+ var corners = new LVector3[4];
+ corners[0] = new LVector3(-halfSize.x, LFloat.L0, -halfSize.z); // 左下角
+ corners[1] = new LVector3(halfSize.x, LFloat.L0, -halfSize.z); // 右下角
+ corners[2] = new LVector3(halfSize.x, LFloat.L0, halfSize.z); // 右上角
+ corners[3] = new LVector3(-halfSize.x, LFloat.L0, halfSize.z); // 左上角
// 旋转角点并转换到世界坐标系
for (int i = 0; i < corners.Length; i++)
@@ -181,10 +182,10 @@ namespace GAS.General
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawRectangle(in Vector3 position, in Vector3 forward, in Vector2 size,
- in Color? color = null, float duration = 0f)
+ public static void DrawRectangle(in LVector3 position, in LVector3 forward, in LVector2 size,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawRectangle(position, Quaternion.LookRotation(forward), size, color, duration);
+ DrawRectangle(position, LQuaternion.LookRotation(forward), size, color, duration);
}
///
@@ -196,16 +197,16 @@ namespace GAS.General
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawFrontRectangle(in Vector3 position, in Quaternion rotation, in Vector2 size,
- in Color? color = null, float duration = 0f)
+ public static void DrawFrontRectangle(in LVector3 position, in LQuaternion rotation, in LVector2 size,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
// 计算矩形的四个角点在局部坐标系中的位置
- var halfX = size.x * 0.5f;
- var corners = new Vector3[4];
- corners[0] = new Vector3(-halfX, 0, 0); // 左下角
- corners[1] = new Vector3(halfX, 0, 0); // 右下角
- corners[2] = new Vector3(halfX, 0, size.y); // 右上角
- corners[3] = new Vector3(-halfX, 0, size.y); // 左上角
+ var halfX = size.x * LFloat.L0D5;
+ var corners = new LVector3[4];
+ corners[0] = new LVector3(-halfX, LFloat.L0, LFloat.L0); // 左下角
+ corners[1] = new LVector3(halfX, LFloat.L0, LFloat.L0); // 右下角
+ corners[2] = new LVector3(halfX, LFloat.L0, size.y); // 右上角
+ corners[3] = new LVector3(-halfX, LFloat.L0, size.y); // 左上角
// 旋转角点并转换到世界坐标系
for (int i = 0; i < corners.Length; i++)
@@ -221,10 +222,10 @@ namespace GAS.General
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawFrontRectangle(in Vector3 position, in Vector3 forward, in Vector2 size,
- in Color? color = null, float duration = 0f)
+ public static void DrawFrontRectangle(in LVector3 position, in LVector3 forward, in LVector2 size,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawFrontRectangle(position, Quaternion.LookRotation(forward), size, color, duration);
+ DrawFrontRectangle(position, LQuaternion.LookRotation(forward), size, color, duration);
}
///
@@ -236,24 +237,24 @@ namespace GAS.General
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawCube(in Vector3 position, in Quaternion rotation, in Vector3 size,
- in Color? color = null, float duration = 0f)
+ public static void DrawCube(in LVector3 position, in LQuaternion rotation, in LVector3 size,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
// 计算立方体的八个顶点在局部坐标系中的位置
- var halfSize = size * 0.5f;
- var vertices = new Vector3[8];
+ var halfSize = size * LFloat.L0D5;
+ var vertices = new LVector3[8];
// 下底面四个顶点
- vertices[0] = new Vector3(-halfSize.x, -halfSize.y, -halfSize.z);
- vertices[1] = new Vector3(halfSize.x, -halfSize.y, -halfSize.z);
- vertices[2] = new Vector3(halfSize.x, -halfSize.y, halfSize.z);
- vertices[3] = new Vector3(-halfSize.x, -halfSize.y, halfSize.z);
+ vertices[0] = new LVector3(-halfSize.x, -halfSize.y, -halfSize.z);
+ vertices[1] = new LVector3(halfSize.x, -halfSize.y, -halfSize.z);
+ vertices[2] = new LVector3(halfSize.x, -halfSize.y, halfSize.z);
+ vertices[3] = new LVector3(-halfSize.x, -halfSize.y, halfSize.z);
// 上顶面四个顶点
- vertices[4] = new Vector3(-halfSize.x, halfSize.y, -halfSize.z);
- vertices[5] = new Vector3(halfSize.x, halfSize.y, -halfSize.z);
- vertices[6] = new Vector3(halfSize.x, halfSize.y, halfSize.z);
- vertices[7] = new Vector3(-halfSize.x, halfSize.y, halfSize.z);
+ vertices[4] = new LVector3(-halfSize.x, halfSize.y, -halfSize.z);
+ vertices[5] = new LVector3(halfSize.x, halfSize.y, -halfSize.z);
+ vertices[6] = new LVector3(halfSize.x, halfSize.y, halfSize.z);
+ vertices[7] = new LVector3(-halfSize.x, halfSize.y, halfSize.z);
// 旋转顶点并转换到世界坐标系
for (int i = 0; i < vertices.Length; i++)
@@ -279,10 +280,10 @@ namespace GAS.General
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawCube(in Vector3 position, in Vector3 forward, in Vector3 size,
- in Color? color = null, float duration = 0f)
+ public static void DrawCube(in LVector3 position, in LVector3 forward, in LVector3 size,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawCube(position, Quaternion.LookRotation(forward), size, color, duration);
+ DrawCube(position, LQuaternion.LookRotation(forward), size, color, duration);
}
///
@@ -296,10 +297,10 @@ namespace GAS.General
///
///
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawCylinder(in Vector3 position, in Quaternion rotation, float radius, float height, int segments = 12,
- in Color? color = null, float duration = 0f)
+ public static void DrawCylinder(in LVector3 position, in LQuaternion rotation, LFloat radius, LFloat height, int segments = 12,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- var offset = rotation * Vector3.up * (height * 0.5f);
+ var offset = rotation * LVector3.Up * (height * LFloat.L0D5);
var topCenter = position + offset;
var bottomCenter = position - offset;
DrawCylinder(topCenter, bottomCenter, radius, segments, color, duration);
@@ -316,42 +317,42 @@ namespace GAS.General
///
///
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawCylinder(in Vector3 position, in Vector3 forward, float radius, float height, int segments = 12,
- in Color? color = null, float duration = 0f)
+ public static void DrawCylinder(in LVector3 position, in LVector3 forward, LFloat radius, LFloat height, int segments = 12,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawCylinder(position, Quaternion.LookRotation(forward), radius, height, segments, in color, duration);
+ DrawCylinder(position, LQuaternion.LookRotation(forward), radius, height, segments, in color, duration);
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawCylinder(in Vector3 topCenter, in Vector3 bottomCenter, float radius, int segments = 12,
- in Color? color = null, float duration = 0f)
+ public static void DrawCylinder(in LVector3 topCenter, in LVector3 bottomCenter, LFloat radius, int segments = 12,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
if (radius <= 0) return;
if (segments <= 0) return;
- if (Vector3.Distance(topCenter, bottomCenter) <= Mathf.Epsilon) return;
+ if (LVector3.Distance(topCenter, bottomCenter) <= LFloat.EPSILON) return;
- var direction = (topCenter - bottomCenter).normalized;
+ var direction = (topCenter - bottomCenter).Normalized;
// 计算一个垂直于direction的向量作为forward
- var forward = Vector3.Cross(direction, Vector3.up).normalized;
+ var forward = LVector3.Cross(direction, LVector3.Up).Normalized;
- // 如果forward和direction平行(即direction和Vector3.up共线),则选择一个不同的方向作为forward
- if (forward == Vector3.zero)
+ // 如果forward和direction平行(即direction和LVector3.up共线),则选择一个不同的方向作为forward
+ if (forward == LVector3.Zero)
{
- forward = Vector3.Cross(direction, Vector3.right).normalized;
+ forward = LVector3.Cross(direction, LVector3.Right).Normalized;
}
- var rotation = Quaternion.LookRotation(forward, direction);
+ var rotation = LQuaternion.LookRotation(forward, direction);
- var angleStep = 360f / segments;
- var offset = rotation * (Vector3.right * radius);
+ var angleStep = LFloat.L360 / segments;
+ var offset = rotation * (LVector3.Right * radius);
var lastTopPoint = topCenter + offset;
var lastBottomPoint = bottomCenter + offset;
for (int i = 1; i <= segments; i++)
{
var currentAngle = i * angleStep;
- offset = rotation * (Quaternion.Euler(0, currentAngle, 0) * (Vector3.right * radius));
+ offset = rotation * (LQuaternion.Euler(0, currentAngle, 0) * (LVector3.Right * radius));
var nextTopPoint = topCenter + offset;
var nextBottomPoint = bottomCenter + offset;
DrawLine(lastTopPoint, nextTopPoint, color, duration);
@@ -369,21 +370,21 @@ namespace GAS.General
/// 旋转
/// 扇形的半径
/// 扇形的角度(度)
- /// 分段数(建议与角度适配, 如每10°分一段: segments = Mathf.CeilToInt(angle / 10))
+ /// 分段数(建议与角度适配, 如每10°分一段: segments = LMath.CeilToInt(angle / 10))
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawSector(Vector3 position, Quaternion rotation, float radius, float angle, int segments = 12,
- Color? color = null, float duration = 0f)
+ public static void DrawSector(LVector3 position, LQuaternion rotation, LFloat radius, LFloat angle, int segments = 12,
+ Color? color = null, LFloat duration = default) //duration = 0
{
DrawAnnularSector(position, rotation, radius, 0, angle, segments, color, duration);
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawSector(in Vector3 position, in Vector3 forward, float radius, float angle, int segments = 12,
- in Color? color = null, float duration = 0f)
+ public static void DrawSector(in LVector3 position, in LVector3 forward, LFloat radius, LFloat angle, int segments = 12,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawSector(position, Quaternion.LookRotation(forward), radius, angle, segments, color, duration);
+ DrawSector(position, LQuaternion.LookRotation(forward), radius, angle, segments, color, duration);
}
@@ -395,29 +396,29 @@ namespace GAS.General
/// 扇形的外半径
/// 扇形的内半径, 为0时为标准扇形
/// 扇形的角度(度)
- /// 分段数(建议与角度适配, 如每10°分一段: segments = Mathf.CeilToInt(angle / 10))
+ /// 分段数(建议与角度适配, 如每10°分一段: segments = LMath.CeilToInt(angle / 10))
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawAnnularSector(in Vector3 position, in Quaternion rotation, float outerRadius, float innerRadius, float angle, int segments = 12,
- in Color? color = null, float duration = 0f)
+ public static void DrawAnnularSector(in LVector3 position, in LQuaternion rotation, LFloat outerRadius, LFloat innerRadius, LFloat angle, int segments = 12,
+ in Color? color = null, LFloat duration = default) //duration = 0
{
if (outerRadius <= 0) return;
if (segments <= 0) return;
if (angle <= 0) return;
- innerRadius = Mathf.Clamp(innerRadius, 0, outerRadius);
+ innerRadius = LMath.Clamp(innerRadius, LFloat.L0, outerRadius);
var angleStep = angle / segments;
- var currentAngle = -angle * 0.5f;
+ var currentAngle = -angle * LFloat.L0D5;
- var outerPoints = new Vector3[segments + 1];
- var innerPoints = new Vector3[segments + 1];
+ var outerPoints = new LVector3[segments + 1];
+ var innerPoints = new LVector3[segments + 1];
// 计算内外扇形的点
for (var i = 0; i <= segments; i++)
{
- var currentDirection = rotation * Quaternion.Euler(0, currentAngle, 0) * Vector3.forward;
+ var currentDirection = rotation * LQuaternion.Euler(0, currentAngle, 0) * LVector3.Forward;
outerPoints[i] = position + currentDirection * outerRadius;
innerPoints[i] = position + currentDirection * innerRadius;
currentAngle += angleStep;
@@ -443,9 +444,9 @@ namespace GAS.General
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawAnnularSector(in Vector3 position, in Vector3 forward, float outerRadius, float innerRadius, float angle, int segments = 12, in Color? color = null, float duration = 0f)
+ public static void DrawAnnularSector(in LVector3 position, in LVector3 forward, LFloat outerRadius, LFloat innerRadius, LFloat angle, int segments = 12, in Color? color = null, LFloat duration = default) //duration = 0
{
- DrawAnnularSector(position, Quaternion.LookRotation(forward), outerRadius, innerRadius, angle, segments, color, duration);
+ DrawAnnularSector(position, LQuaternion.LookRotation(forward), outerRadius, innerRadius, angle, segments, color, duration);
}
///
@@ -456,9 +457,9 @@ namespace GAS.General
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawLine(in Vector3 start, in Vector3 end, in Color? color = null, float duration = 0f)
+ public static void DrawLine(in LVector3 start, in LVector3 end, in Color? color = null, LFloat duration = default) //duration = 0
{
- Debug.DrawLine(start, end, color ?? Color.cyan, duration);
+ Debug.DrawLine(start.ToVector3(), end.ToVector3(), color ?? Color.cyan, duration);
}
///
@@ -469,12 +470,12 @@ namespace GAS.General
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawArrow(in Vector3 origin, in Vector3 destination, in Color? color = null, float duration = 0f)
+ public static void DrawArrow(in LVector3 origin, in LVector3 destination, in Color? color = null, LFloat duration = default) //duration = 0
{
DrawLine(origin, destination, color, duration);
var direction = destination - origin;
- var right = Quaternion.LookRotation(direction) * Quaternion.Euler(0, 180 + 30, 0) * Vector3.forward;
- var left = Quaternion.LookRotation(direction) * Quaternion.Euler(0, 180 - 30, 0) * Vector3.forward;
+ var right = LQuaternion.LookRotation(direction) * LQuaternion.Euler(0, 180 + 30, 0) * LVector3.Forward;
+ var left = LQuaternion.LookRotation(direction) * LQuaternion.Euler(0, 180 - 30, 0) * LVector3.Forward;
DrawLine(destination, destination + right, color, duration);
DrawLine(destination, destination + left, color, duration);
}
@@ -489,17 +490,17 @@ namespace GAS.General
/// 颜色
/// 绘制时长(0为1帧)
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawArrow(in Vector3 origin, in Quaternion rotation, float length, in Color? color = null, float duration = 0f)
+ public static void DrawArrow(in LVector3 origin, in LQuaternion rotation, LFloat length, in Color? color = null, LFloat duration = default) //duration = 0
{
- var direction = rotation * Vector3.forward;
+ var direction = rotation * LVector3.Forward;
var destination = origin + direction * length;
DrawArrow(origin, destination, color, duration);
}
[System.Diagnostics.Conditional("UNITY_EDITOR")]
- public static void DrawArrow(in Vector3 origin, in Vector3 direction, float length, in Color? color = null, float duration = 0f)
+ public static void DrawArrow(in LVector3 origin, in LVector3 direction, LFloat length, in Color? color = null, LFloat duration = default) //duration = 0
{
- var destination = origin + direction.normalized * length;
+ var destination = origin + direction.Normalized * length;
DrawArrow(origin, destination, color, duration);
}
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/AbilitySpec.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/AbilitySpec.cs
index 3295fa7b..5ddbcb36 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/AbilitySpec.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/AbilitySpec.cs
@@ -1,4 +1,5 @@
using System;
+using JNGame.Math;
namespace GAS.Runtime
{
@@ -137,11 +138,11 @@ namespace GAS.Runtime
Owner.GetAttributeCurrentValue(modifier.AttributeSetName, modifier.AttributeShortName);
if (modifier.Operation == GEOperation.Add)
- if (attributeCurrentValue + costValue < 0)
+ if (attributeCurrentValue != null && (attributeCurrentValue.Value + costValue) < LFloat.L0)
return false;
if (modifier.Operation == GEOperation.Minus)
- if (attributeCurrentValue - costValue < 0)
+ if (attributeCurrentValue != null && (attributeCurrentValue.Value - costValue) < LFloat.L0)
return false;
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbility.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbility.cs
index cc5768ce..73814997 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbility.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbility.cs
@@ -1,4 +1,5 @@
-using UnityEngine.Profiling;
+using JNGame.Math;
+using UnityEngine.Profiling;
namespace GAS.Runtime
{
@@ -19,7 +20,7 @@ namespace GAS.Runtime
///
/// 不受播放速率影响的总时间
///
- public float TotalTime => _player.TotalTime;
+ public LFloat TotalTime => _player.TotalTime;
///
/// 向性技能的作用目标
@@ -41,7 +42,7 @@ namespace GAS.Runtime
_player.Play();
}
- public virtual float GetPlaySpeed()
+ public virtual LFloat GetPlaySpeed()
{
return Data.AbilityAsset.Speed;
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityAsset.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityAsset.cs
index 35c7c1da..4b620fa7 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityAsset.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityAsset.cs
@@ -2,6 +2,7 @@ using System;
using System.Collections.Generic;
using System.Reflection;
using GAS.General;
+using JNGame.Math;
using Sirenix.OdinInspector;
using UnityEditor;
using UnityEngine;
@@ -39,7 +40,7 @@ namespace GAS.Runtime
[LabelText(GASTextDefine.ABILITY_PLAY_RATE)]
[LabelWidth(100)]
[MinValue(0)]
- public float Speed = 1.0f;
+ public LFloat Speed = 1;
[TabGroup("Data/H1/V1", "Timeline")]
[LabelText(GASTextDefine.ABILITY_MANUAL_ENDABILITY)]
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityPlayer.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityPlayer.cs
index c9023fc0..47abf8c3 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityPlayer.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TimelineAbilityPlayer.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using GAS.General;
+using JNGame.Math;
using UnityEngine;
//using UnityEngine.Profiling;
@@ -54,7 +55,7 @@ namespace GAS.Runtime
private readonly List _targets = new();
private int _currentFrame;
- private float _playTotalTime;
+ private LFloat _playTotalTime;
public TimelineAbilityPlayer(TimelineAbilitySpecT abilitySpec)
{
@@ -71,7 +72,7 @@ namespace GAS.Runtime
///
/// 不受播放速率影响的总时间
///
- public float TotalTime => (float)FrameCount / FrameRate;
+ public LFloat TotalTime => (LFloat)FrameCount / FrameRate;
private void Cache()
{
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TrackItem/ReleaseGameplayEffectTrackData.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TrackItem/ReleaseGameplayEffectTrackData.cs
index f73ea1a0..716ee6c7 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TrackItem/ReleaseGameplayEffectTrackData.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Ability/TimelineAbility/TrackItem/ReleaseGameplayEffectTrackData.cs
@@ -126,13 +126,13 @@ namespace GAS.Runtime
// public LayerMask checkLayer;
// public CenterType centerType;
//
- // public Vector3 center;
+ // public LVector3 center;
//
// // Circle2D,Sphere3D
- // public float radius;
+ // public LFloat radius;
//
// // Box2D,Box3D
- // public Vector3 size;
+ // public LVector3 size;
//
// // Custom
// public string customMethodRegisterKey;
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeAggregator.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeAggregator.cs
index ed044414..6965e622 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeAggregator.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeAggregator.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using GAS.General;
+using JNGame.Math;
using UnityEngine;
namespace GAS.Runtime
@@ -118,13 +119,13 @@ namespace GAS.Runtime
/// 3._modifierCache的AttributeBased类的MMC,Track类属性变化时
///
///
- float CalculateNewValue()
+ LFloat CalculateNewValue()
{
switch (_processedAttribute.CalculateMode)
{
case CalculateMode.Stacking:
{
- float newValue = _processedAttribute.BaseValue;
+ LFloat newValue = _processedAttribute.BaseValue;
foreach (var modifierSpec in _modifierCache)
{
var spec = modifierSpec.SpecRef;
@@ -163,7 +164,7 @@ namespace GAS.Runtime
case CalculateMode.MinValueOnly:
{
var hasOverride = false;
- var min = float.MaxValue;
+ var min = LFloat.MaxValue;
foreach (var modifierSpec in _modifierCache)
{
var spec = modifierSpec.SpecRef;
@@ -180,7 +181,7 @@ namespace GAS.Runtime
}
var magnitude = modifier.CalculateMagnitude(spec, modifier.ModiferMagnitude);
- min = Mathf.Min(min, magnitude);
+ min = LMath.Min(min, magnitude);
hasOverride = true;
}
@@ -189,7 +190,7 @@ namespace GAS.Runtime
case CalculateMode.MaxValueOnly:
{
var hasOverride = false;
- var max = float.MinValue;
+ var max = LFloat.MinValue;
foreach (var modifierSpec in _modifierCache)
{
var spec = modifierSpec.SpecRef;
@@ -206,7 +207,7 @@ namespace GAS.Runtime
}
var magnitude = modifier.CalculateMagnitude(spec, modifier.ModiferMagnitude);
- max = Mathf.Max(max, magnitude);
+ max = LMath.Max(max, magnitude);
hasOverride = true;
}
@@ -217,17 +218,17 @@ namespace GAS.Runtime
}
}
- void UpdateCurrentValueWhenBaseValueIsDirty(AttributeBase attribute, float oldBaseValue, float newBaseValue)
+ void UpdateCurrentValueWhenBaseValueIsDirty(AttributeBase attribute, LFloat oldBaseValue, LFloat newBaseValue)
{
- if (Mathf.Approximately(oldBaseValue, newBaseValue)) return;
+ if (LMath.Approximately(oldBaseValue, newBaseValue)) return;
- float newValue = CalculateNewValue();
+ LFloat newValue = CalculateNewValue();
_processedAttribute.SetCurrentValue(newValue);
}
void UpdateCurrentValueWhenModifierIsDirty()
{
- float newValue = CalculateNewValue();
+ LFloat newValue = CalculateNewValue();
_processedAttribute.SetCurrentValue(newValue);
}
@@ -275,7 +276,7 @@ namespace GAS.Runtime
}
}
- private void OnAttributeChanged(AttributeBase attribute, float oldValue, float newValue)
+ private void OnAttributeChanged(AttributeBase attribute, LFloat oldValue, LFloat newValue)
{
if (IsTrackingAttribute(attribute))
UpdateCurrentValueWhenModifierIsDirty();
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeBase.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeBase.cs
index 14837880..50d2536f 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeBase.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/AttributeBase.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.Linq;
+using JNGame.Math;
using UnityEngine;
namespace GAS.Runtime
@@ -10,34 +11,34 @@ namespace GAS.Runtime
public readonly string Name;
public readonly string SetName;
public readonly string ShortName;
- protected event Action _onPostCurrentValueChange;
- protected event Action _onPostBaseValueChange;
- protected event Action _onPreCurrentValueChange;
- protected event Func _onPreBaseValueChange;
- protected IEnumerable> _preBaseValueChangeListeners;
+ protected event Action _onPostCurrentValueChange;
+ protected event Action _onPostBaseValueChange;
+ protected event Action _onPreCurrentValueChange;
+ protected event Func _onPreBaseValueChange;
+ protected IEnumerable> _preBaseValueChangeListeners;
private AttributeValue _value;
private AbilitySystemComponent _owner;
public AbilitySystemComponent Owner => _owner;
- public AttributeBase(string attrSetName, string attrName, float value = 0,
+ public AttributeBase(string attrSetName, string attrName,
+ LFloat value,LFloat minValue, LFloat maxValue,
CalculateMode calculateMode = CalculateMode.Stacking,
- SupportedOperation supportedOperation = SupportedOperation.All,
- float minValue = float.MinValue, float maxValue = float.MaxValue)
+ SupportedOperation supportedOperation = SupportedOperation.All)
{
SetName = attrSetName;
Name = $"{attrSetName}.{attrName}";
ShortName = attrName;
- _value = new AttributeValue(value, calculateMode, supportedOperation, minValue, maxValue);
+ _value = new AttributeValue(value, minValue,maxValue,calculateMode, supportedOperation);
}
public AttributeValue Value => _value;
- public float BaseValue => _value.BaseValue;
- public float CurrentValue => _value.CurrentValue;
+ public LFloat BaseValue => _value.BaseValue;
+ public LFloat CurrentValue => _value.CurrentValue;
- public float MinValue => _value.MinValue;
- public float MaxValue => _value.MaxValue;
+ public LFloat MinValue => _value.MinValue;
+ public LFloat MaxValue => _value.MaxValue;
public CalculateMode CalculateMode => _value.CalculateMode;
public SupportedOperation SupportedOperation => _value.SupportedOperation;
@@ -47,17 +48,17 @@ namespace GAS.Runtime
_owner = owner;
}
- public void SetMinValue(float min)
+ public void SetMinValue(LFloat min)
{
_value.SetMinValue(min);
}
- public void SetMaxValue(float max)
+ public void SetMaxValue(LFloat max)
{
_value.SetMaxValue(max);
}
- public void SetMinMaxValue(float min, float max)
+ public void SetMinMaxValue(LFloat min, LFloat max)
{
_value.SetMinValue(min);
_value.SetMaxValue(max);
@@ -68,26 +69,26 @@ namespace GAS.Runtime
return _value.IsSupportOperation(operation);
}
- public void Init(float baseValue)
+ public void Init(LFloat baseValue)
{
SetBaseValue(baseValue);
SetCurrentValue(baseValue);
}
- public void SetCurrentValue(float value)
+ public void SetCurrentValue(LFloat value)
{
- value = Mathf.Clamp(value, _value.MinValue, _value.MaxValue);
+ value = LMath.Clamp(value, _value.MinValue, _value.MaxValue);
_onPreCurrentValueChange?.Invoke(this, value);
var oldValue = CurrentValue;
_value.SetCurrentValue(value);
- if (!Mathf.Approximately(oldValue, value))
+ if (!LMath.Approximately(oldValue, value))
_onPostCurrentValueChange?.Invoke(this, oldValue, value);
}
- public void SetBaseValue(float value)
+ public void SetBaseValue(LFloat value)
{
if (_onPreBaseValueChange != null)
{
@@ -97,60 +98,60 @@ namespace GAS.Runtime
var oldValue = _value.BaseValue;
_value.SetBaseValue(value);
- if (!Mathf.Approximately(oldValue, value))
+ if (!LMath.Approximately(oldValue, value))
_onPostBaseValueChange?.Invoke(this, oldValue, value);
}
- public void SetCurrentValueWithoutEvent(float value)
+ public void SetCurrentValueWithoutEvent(LFloat value)
{
_value.SetCurrentValue(value);
}
- public void SetBaseValueWithoutEvent(float value)
+ public void SetBaseValueWithoutEvent(LFloat value)
{
_value.SetBaseValue(value);
}
- public void RegisterPreBaseValueChange(Func func)
+ public void RegisterPreBaseValueChange(Func func)
{
_onPreBaseValueChange += func;
_preBaseValueChangeListeners =
- _onPreBaseValueChange?.GetInvocationList().Cast>();
+ _onPreBaseValueChange?.GetInvocationList().Cast>();
}
- public void RegisterPostBaseValueChange(Action action)
+ public void RegisterPostBaseValueChange(Action action)
{
_onPostBaseValueChange += action;
}
- public void RegisterPreCurrentValueChange(Action action)
+ public void RegisterPreCurrentValueChange(Action action)
{
_onPreCurrentValueChange += action;
}
- public void RegisterPostCurrentValueChange(Action action)
+ public void RegisterPostCurrentValueChange(Action action)
{
_onPostCurrentValueChange += action;
}
- public void UnregisterPreBaseValueChange(Func func)
+ public void UnregisterPreBaseValueChange(Func func)
{
_onPreBaseValueChange -= func;
_preBaseValueChangeListeners =
- _onPreBaseValueChange?.GetInvocationList().Cast>();
+ _onPreBaseValueChange?.GetInvocationList().Cast>();
}
- public void UnregisterPostBaseValueChange(Action action)
+ public void UnregisterPostBaseValueChange(Action action)
{
_onPostBaseValueChange -= action;
}
- public void UnregisterPreCurrentValueChange(Action action)
+ public void UnregisterPreCurrentValueChange(Action action)
{
_onPreCurrentValueChange -= action;
}
- public void UnregisterPostCurrentValueChange(Action action)
+ public void UnregisterPostCurrentValueChange(Action action)
{
_onPostCurrentValueChange -= action;
}
@@ -163,7 +164,7 @@ namespace GAS.Runtime
_onPostCurrentValueChange = null;
}
- private float InvokePreBaseValueChangeListeners(float value)
+ private LFloat InvokePreBaseValueChangeListeners(LFloat value)
{
if (_preBaseValueChangeListeners == null) return value;
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/Value/AttributeValue.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/Value/AttributeValue.cs
index 3da76e19..043579c0 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/Value/AttributeValue.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Attribute/Value/AttributeValue.cs
@@ -1,4 +1,5 @@
-using Sirenix.OdinInspector;
+using JNGame.Math;
+using Sirenix.OdinInspector;
namespace GAS.Runtime
{
@@ -16,10 +17,11 @@ namespace GAS.Runtime
public struct AttributeValue
{
- public AttributeValue(float baseValue,
+ public AttributeValue(
+ LFloat baseValue,LFloat minValue, LFloat maxValue,
CalculateMode calculateMode = CalculateMode.Stacking,
- SupportedOperation supportedOperation = SupportedOperation.All,
- float minValue = float.MinValue, float maxValue = float.MaxValue)
+ SupportedOperation supportedOperation = SupportedOperation.All
+ )
{
BaseValue = baseValue;
SupportedOperation = supportedOperation;
@@ -32,36 +34,36 @@ namespace GAS.Runtime
public CalculateMode CalculateMode { get; }
public SupportedOperation SupportedOperation { get; }
- public float BaseValue { get; private set; }
- public float CurrentValue { get; private set; }
+ public LFloat BaseValue { get; private set; }
+ public LFloat CurrentValue { get; private set; }
- public float MinValue { get; private set; }
- public float MaxValue { get; private set; }
+ public LFloat MinValue { get; private set; }
+ public LFloat MaxValue { get; private set; }
///
/// ignore min and max value, set current value directly
///
- public void SetCurrentValue(float value)
+ public void SetCurrentValue(LFloat value)
{
CurrentValue = value;
}
- public void SetBaseValue(float value)
+ public void SetBaseValue(LFloat value)
{
BaseValue = value;
}
- public void SetMinValue(float min)
+ public void SetMinValue(LFloat min)
{
MinValue = min;
}
- public void SetMaxValue(float max)
+ public void SetMaxValue(LFloat max)
{
MaxValue = max;
}
- public void SetMinMaxValue(float min, float max)
+ public void SetMinMaxValue(LFloat min, LFloat max)
{
MinValue = min;
MaxValue = max;
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSet.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSet.cs
index 9bbb906d..12b0119f 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSet.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSet.cs
@@ -1,4 +1,6 @@
-namespace GAS.Runtime
+using JNGame.Math;
+
+namespace GAS.Runtime
{
public abstract class AttributeSet
{
@@ -7,7 +9,7 @@
public abstract AttributeBase this[string key] { get; }
public abstract string[] AttributeNames { get; }
public abstract void SetOwner(AbilitySystemComponent owner);
- public void ChangeAttributeBase(string attributeShortName, float value)
+ public void ChangeAttributeBase(string attributeShortName, LFloat value)
{
if (this[attributeShortName] != null)
{
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSetContainer.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSetContainer.cs
index 88be3bd7..f78848e0 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSetContainer.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/AttributeSet/AttributeSetContainer.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using GAS.General;
+using JNGame.Math;
namespace GAS.Runtime
{
@@ -97,22 +98,22 @@ namespace GAS.Runtime
: (CalculateMode?)null;
}
- public float? GetAttributeBaseValue(string attrSetName, string attrShortName)
+ public LFloat? GetAttributeBaseValue(string attrSetName, string attrShortName)
{
- return _attributeSets.TryGetValue(attrSetName, out var set) ? set[attrShortName].BaseValue : (float?)null;
+ return _attributeSets.TryGetValue(attrSetName, out var set) ? set[attrShortName].BaseValue : (LFloat?)null;
}
- public float? GetAttributeCurrentValue(string attrSetName, string attrShortName)
+ public LFloat? GetAttributeCurrentValue(string attrSetName, string attrShortName)
{
return _attributeSets.TryGetValue(attrSetName, out var set)
? set[attrShortName].CurrentValue
- : (float?)null;
+ : (LFloat?)null;
}
- public Dictionary Snapshot()
+ public Dictionary Snapshot()
{
- var snapshot = JexGasObjectPool.Instance.Fetch>();
+ var snapshot = JexGasObjectPool.Instance.Fetch>();
foreach (var kv in _attributeSets)
{
var attributeSet = kv.Value;
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/AbilitySystemComponent.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/AbilitySystemComponent.cs
index 62026a7c..40a8f3c7 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/AbilitySystemComponent.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/AbilitySystemComponent.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using GAS.General;
+using JNGame.Math;
using UnityEngine;
namespace GAS.Runtime
@@ -270,13 +271,13 @@ namespace GAS.Runtime
return value;
}
- public float? GetAttributeCurrentValue(string setName, string attributeShortName)
+ public LFloat? GetAttributeCurrentValue(string setName, string attributeShortName)
{
var value = AttributeSetContainer.GetAttributeCurrentValue(setName, attributeShortName);
return value;
}
- public float? GetAttributeBaseValue(string setName, string attributeShortName)
+ public LFloat? GetAttributeBaseValue(string setName, string attributeShortName)
{
var value = AttributeSetContainer.GetAttributeBaseValue(setName, attributeShortName);
return value;
@@ -288,7 +289,7 @@ namespace GAS.Runtime
GameplayEffectContainer.Tick(dt);
}
- public Dictionary DataSnapshot()
+ public Dictionary DataSnapshot()
{
return AttributeSetContainer.Snapshot();
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/IAbilitySystemComponent.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/IAbilitySystemComponent.cs
index 3c8ecfa3..9af4b08a 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/IAbilitySystemComponent.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Component/IAbilitySystemComponent.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
+using JNGame.Math;
namespace GAS.Runtime
{
@@ -33,14 +34,14 @@ namespace GAS.Runtime
void Tick(int dt);
- Dictionary DataSnapshot();
+ Dictionary DataSnapshot();
AbilitySpec GrantAbility(AbstractAbility ability);
void RemoveAbility(string abilityName);
- float? GetAttributeCurrentValue(string setName, string attributeShortName);
- float? GetAttributeBaseValue(string setName, string attributeShortName);
+ LFloat? GetAttributeCurrentValue(string setName, string attributeShortName);
+ LFloat? GetAttributeBaseValue(string setName, string attributeShortName);
bool TryActivateAbility(string abilityName, object arg = null);
void TryEndAbility(string abilityName);
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/CompositeAttribute/CompositeAttribute.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/CompositeAttribute/CompositeAttribute.cs
index 91434094..3f95bea8 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/CompositeAttribute/CompositeAttribute.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/CompositeAttribute/CompositeAttribute.cs
@@ -1,4 +1,5 @@
using System;
+using JNGame.Math;
namespace GAS.Runtime
{
@@ -11,13 +12,13 @@ namespace GAS.Runtime
///
public sealed class CompositeAttribute
{
- public float Value { get; private set; }
- public float MinValue { get; private set; }
- public float MaxValue { get; private set; }
+ public LFloat Value { get; private set; }
+ public LFloat MinValue { get; private set; }
+ public LFloat MaxValue { get; private set; }
- public delegate float OnPreValueChange(CompositeAttribute compositeAttribute, float oldValue, float newValue);
+ public delegate LFloat OnPreValueChange(CompositeAttribute compositeAttribute, LFloat oldValue, LFloat newValue);
- public delegate void OnPostValueChange(CompositeAttribute compositeAttribute, float oldValue, float newValue);
+ public delegate void OnPostValueChange(CompositeAttribute compositeAttribute, LFloat oldValue, LFloat newValue);
private OnPreValueChange _onPreValueChange;
private event OnPostValueChange _onPostValueChange;
@@ -55,12 +56,12 @@ namespace GAS.Runtime
/// 最大值
public CompositeAttribute(
AttributeBase @base,
+ LFloat minValue,
+ LFloat maxValue,
AttributeBase baseAdditiveBonus = null,
AttributeBase additiveBonus = null,
AttributeBase multiplicativeBonus = null,
- AttributeBase maxValuePenalty = null,
- float minValue = float.MinValue,
- float maxValue = float.MaxValue)
+ AttributeBase maxValuePenalty = null)
{
Base = @base;
BaseAdditiveBonus = baseAdditiveBonus;
@@ -94,23 +95,23 @@ namespace GAS.Runtime
MaxValuePenalty?.SetOwner(owner);
}
- public void Init(float baseValue) => Base.Init(baseValue);
+ public void Init(LFloat baseValue) => Base.Init(baseValue);
- public void SetBaseValue(float baseValue) => Base.SetBaseValue(baseValue);
+ public void SetBaseValue(LFloat baseValue) => Base.SetBaseValue(baseValue);
- public void SetMinValue(float minValue)
+ public void SetMinValue(LFloat minValue)
{
MinValue = minValue;
Value = CalculateValue();
}
- public void SetMaxValue(float maxValue)
+ public void SetMaxValue(LFloat maxValue)
{
MaxValue = maxValue;
Value = CalculateValue();
}
- public void SetMinMaxValue(float minValue, float maxValue)
+ public void SetMinMaxValue(LFloat minValue, LFloat maxValue)
{
MinValue = minValue;
MaxValue = maxValue;
@@ -154,7 +155,7 @@ namespace GAS.Runtime
MaxValuePenalty?.UnregisterPostCurrentValueChange(OnAttributeChanged);
}
- private void OnAttributeChanged(AttributeBase attribute, float attrOldValue, float attrNewValue)
+ private void OnAttributeChanged(AttributeBase attribute, LFloat attrOldValue, LFloat attrNewValue)
{
var oldValue = Value;
var newValue = CalculateValue();
@@ -174,12 +175,12 @@ namespace GAS.Runtime
_onPostValueChange?.Invoke(this, oldValue, newValue);
}
- private float CalculateValue()
+ private LFloat CalculateValue()
{
return CalculateTotalValue(Base, BaseAdditiveBonus, AdditiveBonus, MultiplicativeBonus, MaxValuePenalty);
}
- public static float CalculateTotalValue(
+ public static LFloat CalculateTotalValue(
AttributeBase @base,
AttributeBase baseAdditiveBonus = null,
AttributeBase additiveBonus = null,
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/CooldownTimer.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/CooldownTimer.cs
index ff517d0e..bed6a232 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/CooldownTimer.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/CooldownTimer.cs
@@ -1,8 +1,10 @@
-namespace GAS.Runtime
+using JNGame.Math;
+
+namespace GAS.Runtime
{
public struct CooldownTimer
{
- public float TimeRemaining;
- public float Duration;
+ public LFloat TimeRemaining;
+ public LFloat Duration;
}
}
\ No newline at end of file
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffect.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffect.cs
index 4247651f..3c84c5c0 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffect.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffect.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using GAS.General;
+using JNGame.Math;
using Sirenix.OdinInspector;
using UnityEngine;
@@ -38,7 +39,7 @@ namespace GAS.Runtime
public readonly string GameplayEffectName;
public readonly EffectsDurationPolicy DurationPolicy;
public readonly int Duration; // -1 represents infinite duration
- public readonly float Period;
+ public readonly LFloat Period;
public readonly GameplayEffect PeriodExecution;
public readonly GameplayEffectTagContainer TagContainer;
@@ -71,7 +72,7 @@ namespace GAS.Runtime
public EntityRef CreateSpec(
AbilitySystemComponent creator,
AbilitySystemComponent owner,
- float level = 1,
+ LFloat level,
object userData = null)
{
var spec = JexGasObjectPool.Instance.Fetch();
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectContainer.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectContainer.cs
index 823f3a76..73da9a7e 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectContainer.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectContainer.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using GAS.General;
+using JNGame.Math;
using UnityEngine;
namespace GAS.Runtime
@@ -224,8 +225,8 @@ namespace GAS.Runtime
public CooldownTimer CheckCooldownFromTags(in GameplayTagSet tags)
{
- float longestCooldown = 0;
- float maxDuration = 0;
+ LFloat longestCooldown = 0;
+ LFloat maxDuration = 0;
// Check if the cooldown tag is granted to the player, and if so, capture the remaining duration for that tag
foreach (var spec in _gameplayEffectSpecs)
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectPeriodTicker.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectPeriodTicker.cs
index 246981e3..1e5216b1 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectPeriodTicker.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectPeriodTicker.cs
@@ -1,4 +1,5 @@
-using UnityEngine;
+using JNGame.Math;
+using UnityEngine;
namespace GAS.Runtime
{
@@ -6,7 +7,7 @@ namespace GAS.Runtime
{
public ulong InstanceId { get; private set; }
- private float _periodRemaining;
+ private LFloat _periodRemaining;
private GameplayEffectSpec _spec;
public void Awake(GameplayEffectSpec spec)
@@ -23,7 +24,7 @@ namespace GAS.Runtime
_periodRemaining = default;
}
- private float Period => _spec.GameplayEffect.Period;
+ private LFloat Period => _spec.GameplayEffect.Period;
public void Tick(int dt)
{
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectSpec.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectSpec.cs
index 608694d5..b2208a13 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectSpec.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/GameplayEffectSpec.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using GAS.General;
+using JNGame.Math;
using UnityEngine;
namespace GAS.Runtime
@@ -10,8 +11,8 @@ namespace GAS.Runtime
///
public sealed class GameplayEffectSpec : IEntity, IPool
{
- private Dictionary _valueMapWithTag;
- private Dictionary _valueMapWithName;
+ private Dictionary _valueMapWithTag;
+ private Dictionary _valueMapWithName;
private List _cueDurationalSpecs;
public object UserData { get; set; }
@@ -131,7 +132,7 @@ namespace GAS.Runtime
JexGasObjectPool.Instance.Recycle(this);
}
- public void Init(AbilitySystemComponent source, AbilitySystemComponent owner, float level = 1)
+ public void Init(AbilitySystemComponent source, AbilitySystemComponent owner, LFloat level)
{
Source = source;
Owner = owner;
@@ -140,7 +141,8 @@ namespace GAS.Runtime
{
if (GameplayEffect.PeriodExecution is not null)
{
- PeriodExecution = GameplayEffect.PeriodExecution.CreateSpec(source, owner);
+ //TODO 不知道为什么没有传Level
+ PeriodExecution = GameplayEffect.PeriodExecution.CreateSpec(source, owner,1);
}
SetGrantedAbility(GameplayEffect.GrantedAbilities);
@@ -151,7 +153,7 @@ namespace GAS.Runtime
public GameplayEffect GameplayEffect { get; private set; }
public int ActivationTime { get; private set; }
- public float Level { get; private set; }
+ public LFloat Level { get; private set; }
public AbilitySystemComponent Source { get; private set; }
public AbilitySystemComponent Owner { get; private set; }
public bool IsApplied { get; private set; }
@@ -165,23 +167,23 @@ namespace GAS.Runtime
public GameplayEffectStacking Stacking { get; private set; }
public GameplayEffectSnapshotPolicy SnapshotPolicy => GameplayEffect.SnapshotPolicy;
- public Dictionary SnapshotSourceAttributes { get; private set; }
- public Dictionary SnapshotTargetAttributes { get; private set; }
+ public Dictionary SnapshotSourceAttributes { get; private set; }
+ public Dictionary SnapshotTargetAttributes { get; private set; }
///
/// 堆叠数
///
public int StackCount { get; private set; } = 1;
- public float DurationRemaining()
+ public LFloat DurationRemaining()
{
if (DurationPolicy == EffectsDurationPolicy.Infinite)
return -1;
- return Mathf.Max(0, Duration - ActivationTime);
+ return LMath.Max(0, Duration - ActivationTime);
}
- public void SetLevel(float level)
+ public void SetLevel(LFloat level)
{
Level = level;
}
@@ -487,7 +489,7 @@ namespace GAS.Runtime
{
case GameplayEffectSpecifiedSnapshotConfig.ESnapshotTarget.Source:
{
- SnapshotSourceAttributes ??= JexGasObjectPool.Instance.Fetch>();
+ SnapshotSourceAttributes ??= JexGasObjectPool.Instance.Fetch>();
var attribute = Source.AttributeSetContainer.GetAttributeAttributeValue(config.AttributeSetName, config.AttributeShortName);
if (attribute != null)
{
@@ -502,7 +504,7 @@ namespace GAS.Runtime
}
case GameplayEffectSpecifiedSnapshotConfig.ESnapshotTarget.Target:
{
- SnapshotTargetAttributes ??= JexGasObjectPool.Instance.Fetch>();
+ SnapshotTargetAttributes ??= JexGasObjectPool.Instance.Fetch>();
var attribute = Owner.AttributeSetContainer.GetAttributeAttributeValue(config.AttributeSetName, config.AttributeShortName);
if (attribute != null)
{
@@ -538,15 +540,15 @@ namespace GAS.Runtime
}
}
- public void RegisterValue(in GameplayTag tag, float value)
+ public void RegisterValue(in GameplayTag tag, LFloat value)
{
- _valueMapWithTag ??= JexGasObjectPool.Instance.Fetch>();
+ _valueMapWithTag ??= JexGasObjectPool.Instance.Fetch>();
_valueMapWithTag[tag] = value;
}
- public void RegisterValue(string name, float value)
+ public void RegisterValue(string name, LFloat value)
{
- _valueMapWithName ??= JexGasObjectPool.Instance.Fetch>();
+ _valueMapWithName ??= JexGasObjectPool.Instance.Fetch>();
_valueMapWithName[name] = value;
}
@@ -562,16 +564,16 @@ namespace GAS.Runtime
return _valueMapWithName.Remove(name);
}
- public float? GetMapValue(in GameplayTag tag)
+ public LFloat? GetMapValue(in GameplayTag tag)
{
if (_valueMapWithTag == null) return null;
- return _valueMapWithTag.TryGetValue(tag, out var value) ? value : (float?)null;
+ return _valueMapWithTag.TryGetValue(tag, out var value) ? value : (LFloat?)null;
}
- public float? GetMapValue(string name)
+ public LFloat? GetMapValue(string name)
{
if (_valueMapWithName == null) return null;
- return _valueMapWithName.TryGetValue(name, out var value) ? value : (float?)null;
+ return _valueMapWithName.TryGetValue(name, out var value) ? value : (LFloat?)null;
}
private void TryActivateGrantedAbilities()
@@ -640,7 +642,7 @@ namespace GAS.Runtime
if (stackCount <= Stacking.limitCount)
{
// 更新栈数
- StackCount = Mathf.Max(1, stackCount); // 最小层数为1
+ StackCount = LMath.Max(1, stackCount); // 最小层数为1
// 是否刷新Duration
if (Stacking.durationRefreshPolicy == DurationRefreshPolicy.RefreshOnSuccessfulApplication)
{
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttrBasedWithStackModCalculation.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttrBasedWithStackModCalculation.cs
index 5e26f89e..9626192b 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttrBasedWithStackModCalculation.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttrBasedWithStackModCalculation.cs
@@ -1,3 +1,4 @@
+using JNGame.Math;
using Sirenix.OdinInspector;
using UnityEngine;
@@ -19,11 +20,11 @@ namespace GAS.Runtime
[TabGroup("Default", "AttributeBasedModCalculation")]
[Title("堆叠幅值计算")]
[LabelText("系数(sK)")]
- public float sK = 1;
+ public LFloat sK = 1;
[TabGroup("Default", "AttributeBasedModCalculation")]
[LabelText("常量(sB)")]
- public float sB = 0;
+ public LFloat sB = 0;
[TabGroup("Default", "AttributeBasedModCalculation")]
[Title("最终结果")]
@@ -52,7 +53,7 @@ namespace GAS.Runtime
}
}
- public override float CalculateMagnitude(GameplayEffectSpec spec, float modifierMagnitude)
+ public override LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat modifierMagnitude)
{
var attrMagnitude = base.CalculateMagnitude(spec, modifierMagnitude);
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttributeBasedModCalculation.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttributeBasedModCalculation.cs
index 190f1971..33c40531 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttributeBasedModCalculation.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/AttributeBasedModCalculation.cs
@@ -52,7 +52,7 @@ namespace GAS.Runtime
[ReadOnly]
public string attributeShortName;
- [InfoBox("计算逻辑与ScalableFloatModCalculation一致, 公式:AttributeValue * k + b")]
+ [InfoBox("计算逻辑与ScalableLFloatModCalculation一致, 公式:AttributeValue * k + b")]
[TabGroup("Default", "AttributeBasedModCalculation")]
[LabelText("系数(k)")]
public LFloat k = 1;
@@ -61,9 +61,9 @@ namespace GAS.Runtime
[LabelText("常量(b)")]
public LFloat b = 0;
- public override float CalculateMagnitude(GameplayEffectSpec spec, float modifierMagnitude)
+ public override LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat modifierMagnitude)
{
- float attributeValue;
+ LFloat attributeValue;
if (attributeFromType == AttributeFrom.Source)
{
if (captureType == GEAttributeCaptureType.SnapShot)
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/GameplayEffectModifier.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/GameplayEffectModifier.cs
index 3a36fd59..04e26382 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/GameplayEffectModifier.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/GameplayEffectModifier.cs
@@ -1,4 +1,5 @@
using System;
+using JNGame.Math;
using Sirenix.OdinInspector;
using UnityEngine;
@@ -69,9 +70,9 @@ namespace GAS.Runtime
[LabelText("运算参数", SdfIconType.Activity)]
[LabelWidth(LABEL_WIDTH)]
[Tooltip("修改器的基础数值。这个数值如何使用由MMC的运行逻辑决定。\nMMC未指定时直接使用这个值。")]
- [ValidateInput("@Operation != GEOperation.Divide || ModiferMagnitude != 0", "除数不能为零")]
+ // [ValidateInput("@Operation != GEOperation.Divide || ModiferMagnitude != 0", "除数不能为零")]
[PropertyOrder(3)]
- public float ModiferMagnitude;
+ public LFloat ModiferMagnitude;
[LabelText("运算法则", SdfIconType.PlusSlashMinus)]
[LabelWidth(LABEL_WIDTH)]
@@ -95,7 +96,7 @@ namespace GAS.Runtime
public GameplayEffectModifier(
string attributeName,
- float modiferMagnitude,
+ LFloat modiferMagnitude,
GEOperation operation,
ModifierMagnitudeCalculation mmc = null)
{
@@ -108,12 +109,12 @@ namespace GAS.Runtime
MMC = mmc;
}
- public float CalculateMagnitude(GameplayEffectSpec spec, float modifierMagnitude)
+ public LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat modifierMagnitude)
{
return MMC == null ? ModiferMagnitude : MMC.CalculateMagnitude(spec, modifierMagnitude);
}
- public void SetModiferMagnitude(float value)
+ public void SetModiferMagnitude(LFloat value)
{
ModiferMagnitude = value;
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ModifierMagnitudeCalculation.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ModifierMagnitudeCalculation.cs
index 7b1c05df..19ff8909 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ModifierMagnitudeCalculation.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ModifierMagnitudeCalculation.cs
@@ -1,5 +1,6 @@
using System.Linq;
using GAS.General;
+using JNGame.Math;
using Sirenix.OdinInspector;
using UnityEngine;
@@ -41,7 +42,7 @@ namespace GAS.Runtime
public string[] InheritanceChain => GetType().GetInheritanceChain().Reverse().ToArray();
#endif
- public abstract float CalculateMagnitude(GameplayEffectSpec spec, float modifierMagnitude);
+ public abstract LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat modifierMagnitude);
#if UNITY_EDITOR
private void OnValidate()
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ScalableFloatModCalculation.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ScalableFloatModCalculation.cs
index 8d5dc216..af766948 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ScalableFloatModCalculation.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/ScalableFloatModCalculation.cs
@@ -1,22 +1,23 @@
-using Sirenix.OdinInspector;
+using JNGame.Math;
+using Sirenix.OdinInspector;
using UnityEngine;
namespace GAS.Runtime
{
- [CreateAssetMenu(fileName = "ScalableFloatModCalculation", menuName = "GAS/MMC/ScalableFloatModCalculation")]
- public class ScalableFloatModCalculation : ModifierMagnitudeCalculation
+ [CreateAssetMenu(fileName = "ScalableLFloatModCalculation", menuName = "GAS/MMC/ScalableLFloatModCalculation")]
+ public class ScalableLFloatModCalculation : ModifierMagnitudeCalculation
{
private const string Desc = "计算公式:ModifierMagnitude * k + b";
private const string Detail =
- "ScalableFloatModCalculation:可缩放浮点数计算\n该类型是根据Magnitude计算Modifier模值的,计算公式为:ModifierMagnitude * k + b 实际上就是一个线性函数,k和b为可编辑参数,可以在编辑器中设置。";
+ "ScalableLFloatModCalculation:可缩放浮点数计算\n该类型是根据Magnitude计算Modifier模值的,计算公式为:ModifierMagnitude * k + b 实际上就是一个线性函数,k和b为可编辑参数,可以在编辑器中设置。";
[DetailedInfoBox(Desc, Detail, InfoMessageType.Info)] [SerializeField]
- private float k = 1f;
+ private LFloat k = LFloat.L1;
- [SerializeField] private float b = 0f;
+ [SerializeField] private LFloat b = LFloat.L0;
- public override float CalculateMagnitude(GameplayEffectSpec spec, float input)
+ public override LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat input)
{
return input * k + b;
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromNameModCalculation.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromNameModCalculation.cs
index 399e10cd..0148a377 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromNameModCalculation.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromNameModCalculation.cs
@@ -1,3 +1,4 @@
+using JNGame.Math;
using UnityEngine;
namespace GAS.Runtime
@@ -6,7 +7,7 @@ namespace GAS.Runtime
public class SetByCallerFromNameModCalculation : ModifierMagnitudeCalculation
{
[SerializeField] private string valueName;
- public override float CalculateMagnitude(GameplayEffectSpec spec,float input)
+ public override LFloat CalculateMagnitude(GameplayEffectSpec spec,LFloat input)
{
var value = spec.GetMapValue(valueName);
#if UNITY_EDITOR
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromTagModCalculation.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromTagModCalculation.cs
index 5ccf1c5b..cc39601c 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromTagModCalculation.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/SetByCallerFromTagModCalculation.cs
@@ -1,3 +1,4 @@
+using JNGame.Math;
using Sirenix.OdinInspector;
using UnityEngine;
@@ -10,7 +11,7 @@ namespace GAS.Runtime
[ValueDropdown("@ValueDropdownHelper.GameplayTagChoices", HideChildProperties = true)]
private GameplayTag _tag;
- public override float CalculateMagnitude(GameplayEffectSpec spec, float input)
+ public override LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat input)
{
var value = spec.GetMapValue(_tag);
#if UNITY_EDITOR
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/StackModCalculation.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/StackModCalculation.cs
index 2c22a71c..3eb36ff7 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/StackModCalculation.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/Effects/Modifier/StackModCalculation.cs
@@ -1,4 +1,5 @@
-using Sirenix.OdinInspector;
+using JNGame.Math;
+using Sirenix.OdinInspector;
using UnityEngine;
namespace GAS.Runtime
@@ -6,16 +7,16 @@ namespace GAS.Runtime
[CreateAssetMenu( fileName = "StackModCalculation", menuName = "GAS/MMC/StackModCalculation" )]
public class StackModCalculation:ModifierMagnitudeCalculation
{
- [InfoBox("计算逻辑与ScalableFloatModCalculation一致, 公式:(StackCount) * k + b")]
+ [InfoBox("计算逻辑与ScalableLFloatModCalculation一致, 公式:(StackCount) * k + b")]
[TabGroup("Default", "StackModCalculation")]
[LabelText("系数(k)")]
- public float k = 1;
+ public LFloat k = 1;
[TabGroup("Default", "StackModCalculation")]
[LabelText("常量(b)")]
- public float b = 0;
+ public LFloat b = 0;
- public override float CalculateMagnitude(GameplayEffectSpec spec, float modifierMagnitude)
+ public override LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat modifierMagnitude)
{
if (spec.Stacking.stackingType == StackingType.None) return 0;
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/EventSystem/Events/EventAttributeChanged.cs b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/EventSystem/Events/EventAttributeChanged.cs
index 3d91c74e..f2522bfc 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/EventSystem/Events/EventAttributeChanged.cs
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Runtime/EventSystem/Events/EventAttributeChanged.cs
@@ -1,11 +1,12 @@
using System;
+using JNGame.Math;
namespace GAS.Runtime
{
public class AttributeChangedEventArgs : EventArgs
{
- public AttributeChangedEventArgs(AbilitySystemComponent owner, AttributeBase attribute, float oldValue,
- float newValue)
+ public AttributeChangedEventArgs(AbilitySystemComponent owner, AttributeBase attribute, LFloat oldValue,
+ LFloat newValue)
{
Owner = owner;
Attribute = attribute;
@@ -15,13 +16,13 @@ namespace GAS.Runtime
public AbilitySystemComponent Owner { get; }
public AttributeBase Attribute { get; }
- public float OldValue { get; }
- public float NewValue { get; }
+ public LFloat OldValue { get; }
+ public LFloat NewValue { get; }
}
public class AttributeChangedEvent:EventBase
{
- public void Publish(AbilitySystemComponent owner, AttributeBase attribute, float oldValue, float newValue)
+ public void Publish(AbilitySystemComponent owner, AttributeBase attribute, LFloat oldValue, LFloat newValue)
{
Publish(new AttributeChangedEventArgs(owner, attribute, oldValue, newValue));
}
diff --git a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Wiki/MMC.md b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Wiki/MMC.md
index 9d374526..5ff099a4 100644
--- a/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Wiki/MMC.md
+++ b/JNFrame2/Assets/HotScripts/JNGame/Runtime/GAS/Wiki/MMC.md
@@ -20,17 +20,17 @@ GameplayEffectModifier:
AttributeName:AS_Fight.Health
ModifierMagnitude:50
Operation:Add
- MMC:ScalableFloatModCalculation -> k=-1,b=0 (下文会介绍ScalableFloatModCalculation的k,b含义)
+ MMC:ScalableLFloatModCalculation -> k=-1,b=0 (下文会介绍ScalableLFloatModCalculation的k,b含义)
```
## MMC的类型
MMC的基类为抽象类ModifierMagnitudeCalculation,它的子类有以下几种:
-- ScalableFloatModCalculation:可缩放浮点数计算
+- ScalableLFloatModCalculation:可缩放浮点数计算
- 该类型是根据ModifierMagnitude计算Modifier模值的,计算公式为:`ModifierMagnitude * k + b`
实际上就是一个线性函数,k和b为可编辑参数,可以在编辑器中设置。
- AttributeBasedModCalculation:基于属性的计算
- 该类型是根据属性值计算Modifier模值的,计算公式为:`AttributeValue * k + b`
- 计算逻辑与ScalableFloatModCalculation一致。
+ 计算逻辑与ScalableLFloatModCalculation一致。
- 重点在于属性值的来源,确定属性值来源的参数有3个:
- attributeFromType:属性值从谁身上取?是从游戏效果的来源(创建者),还是目标(拥有者)。
- attributeName:属性值的名称,比如战斗属性集里的生命值:AS_Fight.Health
diff --git a/JNFrame2/Assets/Resources/GASSamples/GASMain.unity b/JNFrame2/Assets/Resources/GASSamples/GASMain.unity
index 0b19d961..83f47222 100644
--- a/JNFrame2/Assets/Resources/GASSamples/GASMain.unity
+++ b/JNFrame2/Assets/Resources/GASSamples/GASMain.unity
@@ -133,7 +133,7 @@ PrefabInstance:
m_Modifications:
- target: {fileID: 1418229812123219311, guid: 2e5d0c510b71c714aaccc714aca99afc, type: 3}
propertyPath: m_LocalPosition.x
- value: 10
+ value: 0.18867925
objectReference: {fileID: 0}
- target: {fileID: 1418229812123219311, guid: 2e5d0c510b71c714aaccc714aca99afc, type: 3}
propertyPath: m_LocalPosition.y
diff --git a/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayAbilityLib/JisolDemo1.asset b/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayAbilityLib/JisolDemo1.asset
index 4a5a6c8c..5b06ae15 100644
--- a/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayAbilityLib/JisolDemo1.asset
+++ b/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayAbilityLib/JisolDemo1.asset
@@ -23,7 +23,8 @@ MonoBehaviour:
ActivationOwnedTags: []
ActivationRequiredTags: []
ActivationBlockedTags: []
- Speed: 1
+ Speed:
+ rawValue: 1000000
ManualEndAbility: 0
FrameCount: 60
DurationalCues:
diff --git a/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayEffectLib/GE_JisolDemo1.asset b/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayEffectLib/GE_JisolDemo1.asset
index f0c9b0b4..09c45f4d 100644
--- a/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayEffectLib/GE_JisolDemo1.asset
+++ b/JNFrame2/Assets/Scripts/GASSamples/GAS/Config/GameplayEffectLib/GE_JisolDemo1.asset
@@ -32,8 +32,9 @@ MonoBehaviour:
- AttributeName: AS_BaseAttribute.HP
AttributeSetName: AS_BaseAttribute
AttributeShortName: HP
- ModiferMagnitude: 10
- Operation: 3
+ ModiferMagnitude:
+ rawValue: 10000000
+ Operation: 0
MMC: {fileID: 11400000, guid: 331222964d02d1349b1a9c717605c8e9, type: 2}
AssetTags:
- _name: DeBuff
diff --git a/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/GameplayCue/GameplayCue_PlayerDemo01.cs b/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/GameplayCue/GameplayCue_PlayerDemo01.cs
index 6632f401..136e0738 100644
--- a/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/GameplayCue/GameplayCue_PlayerDemo01.cs
+++ b/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/GameplayCue/GameplayCue_PlayerDemo01.cs
@@ -23,7 +23,7 @@ namespace Demo.Scripts.GAS.GameplayCue
public override void Trigger()
{
- ((GAbilitySystemComponent)Owner).Entity.Transform.Scale = new LVector3(LFloat.L05,LFloat.L05,LFloat.L05);
+ ((GAbilitySystemComponent)Owner).Entity.Transform.Scale = new LVector3(LFloat.L0D5,LFloat.L0D5,LFloat.L0D5);
}
}
diff --git a/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/MMC/AttrModCalculation.cs b/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/MMC/AttrModCalculation.cs
index c9d101a3..07d25425 100644
--- a/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/MMC/AttrModCalculation.cs
+++ b/JNFrame2/Assets/Scripts/GASSamples/Scripts/GAS/MMC/AttrModCalculation.cs
@@ -11,7 +11,7 @@ namespace GASSamples.Scripts.GAS.MMC
[CreateAssetMenu(fileName = "AttrModCalculation", menuName = "GAS/MMC/AttrModCalculation")]
public class AttrModCalculation : ModifierMagnitudeCalculation
{
- public override float CalculateMagnitude(GameplayEffectSpec spec, float modifierMagnitude)
+ public override LFloat CalculateMagnitude(GameplayEffectSpec spec, LFloat modifierMagnitude)
{
return modifierMagnitude;
}
diff --git a/JNFrame2/Assets/Scripts/GASSamples/Scripts/Gen/GAttrSetLib.gen.cs b/JNFrame2/Assets/Scripts/GASSamples/Scripts/Gen/GAttrSetLib.gen.cs
index ea8ccdb0..43db699f 100644
--- a/JNFrame2/Assets/Scripts/GASSamples/Scripts/Gen/GAttrSetLib.gen.cs
+++ b/JNFrame2/Assets/Scripts/GASSamples/Scripts/Gen/GAttrSetLib.gen.cs
@@ -5,6 +5,7 @@
using System;
using System.Collections.Generic;
+using JNGame.Math;
namespace GAS.Runtime
{
@@ -13,14 +14,14 @@ namespace GAS.Runtime
#region HP
/// 血量
- public AttributeBase HP { get; } = new("AS_BaseAttribute", "HP", 0f, CalculateMode.Stacking, (SupportedOperation)31, float.MinValue, float.MaxValue);
+ public AttributeBase HP { get; } = new("AS_BaseAttribute", "HP", new LFloat(true,0), LFloat.MinValue, LFloat.MaxValue, CalculateMode.Stacking, (SupportedOperation)31);
- public void InitHP(float value) => HP.Init(value);
- public void SetCurrentHP(float value) => HP.SetCurrentValue(value);
- public void SetBaseHP(float value) => HP.SetBaseValue(value);
- public void SetMinHP(float value) => HP.SetMinValue(value);
- public void SetMaxHP(float value) => HP.SetMaxValue(value);
- public void SetMinMaxHP(float min, float max) => HP.SetMinMaxValue(min, max);
+ public void InitHP(LFloat value) => HP.Init(value);
+ public void SetCurrentHP(LFloat value) => HP.SetCurrentValue(value);
+ public void SetBaseHP(LFloat value) => HP.SetBaseValue(value);
+ public void SetMinHP(LFloat value) => HP.SetMinValue(value);
+ public void SetMaxHP(LFloat value) => HP.SetMaxValue(value);
+ public void SetMinMaxHP(LFloat min, LFloat max) => HP.SetMinMaxValue(min, max);
#endregion HP
diff --git a/JNFrame2/Logs/AssetImportWorker0.log b/JNFrame2/Logs/AssetImportWorker0.log
new file mode 100644
index 00000000..59c5bfce
--- /dev/null
+++ b/JNFrame2/Logs/AssetImportWorker0.log
@@ -0,0 +1,339 @@
+Using pre-set license
+Built from '2022.3/china_unity/release' branch; Version is '2022.3.16f1c1 (2f3f1b3bde89) revision 3096347'; Using compiler version '192829333'; Build Type 'Release'
+OS: 'Windows 11 (10.0.22631) 64bit Core' Language: 'zh' Physical Memory: 16088 MB
+BatchMode: 1, IsHumanControllingUs: 0, StartBugReporterOnCrash: 0, Is64bit: 1, IsPro: 1
+
+COMMAND LINE ARGUMENTS:
+C:\APP\UnityEdit\2022.3.16f1c1\Editor\Unity.exe
+-adb2
+-batchMode
+-noUpm
+-name
+AssetImportWorker0
+-projectPath
+D:/Jisol/JisolGame/JNFrame2
+-logFile
+Logs/AssetImportWorker0.log
+-srvPort
+53829
+Successfully changed project path to: D:/Jisol/JisolGame/JNFrame2
+D:/Jisol/JisolGame/JNFrame2
+[UnityMemory] Configuration Parameters - Can be set up in boot.config
+ "memorysetup-bucket-allocator-granularity=16"
+ "memorysetup-bucket-allocator-bucket-count=8"
+ "memorysetup-bucket-allocator-block-size=33554432"
+ "memorysetup-bucket-allocator-block-count=8"
+ "memorysetup-main-allocator-block-size=16777216"
+ "memorysetup-thread-allocator-block-size=16777216"
+ "memorysetup-gfx-main-allocator-block-size=16777216"
+ "memorysetup-gfx-thread-allocator-block-size=16777216"
+ "memorysetup-cache-allocator-block-size=4194304"
+ "memorysetup-typetree-allocator-block-size=2097152"
+ "memorysetup-profiler-bucket-allocator-granularity=16"
+ "memorysetup-profiler-bucket-allocator-bucket-count=8"
+ "memorysetup-profiler-bucket-allocator-block-size=33554432"
+ "memorysetup-profiler-bucket-allocator-block-count=8"
+ "memorysetup-profiler-allocator-block-size=16777216"
+ "memorysetup-profiler-editor-allocator-block-size=1048576"
+ "memorysetup-temp-allocator-size-main=16777216"
+ "memorysetup-job-temp-allocator-block-size=2097152"
+ "memorysetup-job-temp-allocator-block-size-background=1048576"
+ "memorysetup-job-temp-allocator-reduction-small-platforms=262144"
+ "memorysetup-allocator-temp-initial-block-size-main=262144"
+ "memorysetup-allocator-temp-initial-block-size-worker=262144"
+ "memorysetup-temp-allocator-size-background-worker=32768"
+ "memorysetup-temp-allocator-size-job-worker=262144"
+ "memorysetup-temp-allocator-size-preload-manager=33554432"
+ "memorysetup-temp-allocator-size-nav-mesh-worker=65536"
+ "memorysetup-temp-allocator-size-audio-worker=65536"
+ "memorysetup-temp-allocator-size-cloud-worker=32768"
+ "memorysetup-temp-allocator-size-gi-baking-worker=262144"
+ "memorysetup-temp-allocator-size-gfx=262144"
+Player connection [30536] Host "[IP] 192.168.31.185 [Port] 0 [Flags] 2 [Guid] 3863844702 [EditorId] 3863844702 [Version] 1048832 [Id] WindowsEditor(7,DESKTOP-5RP3AKU) [Debug] 1 [PackageName] WindowsEditor [ProjectName] Editor" joined multi-casting on [225.0.0.222:54997]...
+
+Player connection [30536] Host "[IP] 192.168.31.185 [Port] 0 [Flags] 2 [Guid] 3863844702 [EditorId] 3863844702 [Version] 1048832 [Id] WindowsEditor(7,DESKTOP-5RP3AKU) [Debug] 1 [PackageName] WindowsEditor [ProjectName] Editor" joined alternative multi-casting on [225.0.0.222:34997]...
+
+[Physics::Module] Initialized MultithreadedJobDispatcher with 19 workers.
+Refreshing native plugins compatible for Editor in 108.86 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Initialize engine version: 2022.3.16f1c1 (2f3f1b3bde89)
+[Subsystems] Discovering subsystems at path C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/Resources/UnitySubsystems
+[Subsystems] Discovering subsystems at path D:/Jisol/JisolGame/JNFrame2/Assets
+GfxDevice: creating device client; threaded=0; jobified=0
+Direct3D:
+ Version: Direct3D 11.0 [level 11.1]
+ Renderer: NVIDIA GeForce RTX 3060 Laptop GPU (ID=0x2520)
+ Vendor: NVIDIA
+ VRAM: 5996 MB
+ Driver: 31.0.15.5176
+Initialize mono
+Mono path[0] = 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/Managed'
+Mono path[1] = 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/MonoBleedingEdge/lib/mono/unityjit-win32'
+Mono config path = 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/MonoBleedingEdge/etc'
+Using monoOptions --debugger-agent=transport=dt_socket,embedding=1,server=y,suspend=n,address=127.0.0.1:56928
+Begin MonoManager ReloadAssembly
+Registering precompiled unity dll's ...
+Register platform support module: C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/PlaybackEngines/AndroidPlayer/UnityEditor.Android.Extensions.dll
+Register platform support module: C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/PlaybackEngines/WindowsStandaloneSupport/UnityEditor.WindowsStandalone.Extensions.dll
+Registered in 0.015835 seconds.
+- Loaded All Assemblies, in 0.394 seconds
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+Android Extension - Scanning For ADB Devices 690 ms
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 0.962 seconds
+Domain Reload Profiling: 1348ms
+ BeginReloadAssembly (132ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (0ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (1ms)
+ RebuildCommonClasses (28ms)
+ RebuildNativeTypeToScriptingClass (9ms)
+ initialDomainReloadingComplete (75ms)
+ LoadAllAssembliesAndSetupDomain (141ms)
+ LoadAssemblies (126ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (138ms)
+ TypeCache.Refresh (136ms)
+ TypeCache.ScanAssembly (123ms)
+ ScanForSourceGeneratedMonoScriptInfo (0ms)
+ ResolveRequiredComponents (0ms)
+ FinalizeReload (963ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (920ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (790ms)
+ SetLoadedEditorAssemblies (2ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (2ms)
+ ProcessInitializeOnLoadAttributes (88ms)
+ ProcessInitializeOnLoadMethodAttributes (38ms)
+ AfterProcessingInitializeOnLoad (0ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (0ms)
+========================================================================
+Worker process is ready to serve import requests
+Begin MonoManager ReloadAssembly
+- Loaded All Assemblies, in 1.094 seconds
+Refreshing native plugins compatible for Editor in 59.61 ms, found 3 plugins.
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+Package Manager log level set to [2]
+[Package Manager] Server::EnsureServerProcessIsRunning -- launch failed, reason: Unity was launched with the -noUpm command-line argument
+[Package Manager] UpmClient::Send -- Unable to send message (not connected to UPM process).
+[Package Manager] Cannot connect to Unity Package Manager local server
+Launched and connected shader compiler UnityShaderCompiler.exe after 0.05 seconds
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 0.920 seconds
+Domain Reload Profiling: 2000ms
+ BeginReloadAssembly (150ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (4ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (18ms)
+ RebuildCommonClasses (27ms)
+ RebuildNativeTypeToScriptingClass (8ms)
+ initialDomainReloadingComplete (67ms)
+ LoadAllAssembliesAndSetupDomain (827ms)
+ LoadAssemblies (668ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (256ms)
+ TypeCache.Refresh (230ms)
+ TypeCache.ScanAssembly (211ms)
+ ScanForSourceGeneratedMonoScriptInfo (18ms)
+ ResolveRequiredComponents (6ms)
+ FinalizeReload (920ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (802ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (22ms)
+ SetLoadedEditorAssemblies (3ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (61ms)
+ ProcessInitializeOnLoadAttributes (406ms)
+ ProcessInitializeOnLoadMethodAttributes (291ms)
+ AfterProcessingInitializeOnLoad (18ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (6ms)
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Refreshing native plugins compatible for Editor in 34.97 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Unloading 5569 Unused Serialized files (Serialized files now loaded: 0)
+Unloading 175 unused Assets / (231.0 KB). Loaded Objects now: 6017.
+Memory consumption went from 210.4 MB to 210.2 MB.
+Total: 13.986300 ms (FindLiveObjects: 0.346200 ms CreateObjectMapping: 0.163700 ms MarkObjects: 13.228100 ms DeleteObjects: 0.247300 ms)
+
+AssetImportParameters requested are different than current active one (requested -> active):
+ custom:container-demuxer-ogg: 62fdf1f143b41e24485cea50d1cbac27 ->
+ custom:video-codec-MediaFoundation-h265: 746d11721c4dcdbdad8f713fa42b33f4 ->
+ custom:video-decoder-ogg-theora: a1e56fd34408186e4bbccfd4996cb3dc ->
+ custom:framework-win-MediaFoundation: 216162199b28c13a410421893ffa2e32 ->
+ custom:CustomObjectIndexerAttribute: 43b350a4d6e6d1791af0b5038c4bea17 ->
+ custom:container-demuxer-webm: 4f35f7cbe854078d1ac9338744f61a02 ->
+ custom:scripting/monoscript/fileName/m_generatorPluginAttribute.cs: b059e60ee6785702b3dbf85733765f7f -> bef7912753b2bc58bba0d70946e69a22
+ custom:scripting/monoscript/fileName/m_generatorAttribute.cs: 9a3832caedb205d9d2bd83dcddfd1f7d -> 4d18a73bcdf3c1dd8d7046481e79d093
+ custom:container-muxer-webm: aa71ff27fc2769a1b78a27578f13a17b ->
+ custom:video-decoder-webm-vp8: 9c59270c3fd7afecdb556c50c9e8de78 ->
+ custom:SearchIndexIgnoredProperties: e643bd26f0fe6173181afceb89e7c659 ->
+ custom:AudioImporter_EditorPlatform: d09bf68614088b80899f8185d706f6e7 ->
+ custom:video-encoder-webm-vp8: eb34c28f22e8b96e1ab97ce403110664 ->
+ custom:audio-decoder-ogg-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/OdinLVector3.cs: 335a14c82456d6f8a32079e834218188 ->
+ custom:audio-encoder-webm-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/m_generatorPackageAttribute.cs: e10470c8d55ee14386c756ed32808741 -> c0108c2656ca6f9f00b8de673fb8aace
+========================================================================
+Received Prepare
+Begin MonoManager ReloadAssembly
+- Loaded All Assemblies, in 0.906 seconds
+Refreshing native plugins compatible for Editor in 36.59 ms, found 3 plugins.
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+[Package Manager] Server::EnsureServerProcessIsRunning -- launch failed, reason: Unity was launched with the -noUpm command-line argument
+[Package Manager] UpmClient::Send -- Unable to send message (not connected to UPM process).
+[Package Manager] Cannot connect to Unity Package Manager local server
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 1.913 seconds
+Domain Reload Profiling: 2802ms
+ BeginReloadAssembly (203ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (3ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (46ms)
+ RebuildCommonClasses (38ms)
+ RebuildNativeTypeToScriptingClass (11ms)
+ initialDomainReloadingComplete (86ms)
+ LoadAllAssembliesAndSetupDomain (551ms)
+ LoadAssemblies (626ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (37ms)
+ TypeCache.Refresh (21ms)
+ TypeCache.ScanAssembly (10ms)
+ ScanForSourceGeneratedMonoScriptInfo (7ms)
+ ResolveRequiredComponents (8ms)
+ FinalizeReload (1913ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (545ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (25ms)
+ SetLoadedEditorAssemblies (3ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (61ms)
+ ProcessInitializeOnLoadAttributes (256ms)
+ ProcessInitializeOnLoadMethodAttributes (179ms)
+ AfterProcessingInitializeOnLoad (21ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (16ms)
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Refreshing native plugins compatible for Editor in 38.92 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Unloading 5552 Unused Serialized files (Serialized files now loaded: 0)
+Unloading 134 unused Assets / (203.5 KB). Loaded Objects now: 6032.
+Memory consumption went from 208.9 MB to 208.7 MB.
+Total: 13.355800 ms (FindLiveObjects: 0.384100 ms CreateObjectMapping: 0.189100 ms MarkObjects: 12.555800 ms DeleteObjects: 0.224600 ms)
+
+Prepare: number of updated asset objects reloaded= 0
+AssetImportParameters requested are different than current active one (requested -> active):
+ custom:container-demuxer-ogg: 62fdf1f143b41e24485cea50d1cbac27 ->
+ custom:video-codec-MediaFoundation-h265: 746d11721c4dcdbdad8f713fa42b33f4 ->
+ custom:video-decoder-ogg-theora: a1e56fd34408186e4bbccfd4996cb3dc ->
+ custom:framework-win-MediaFoundation: 216162199b28c13a410421893ffa2e32 ->
+ custom:CustomObjectIndexerAttribute: 43b350a4d6e6d1791af0b5038c4bea17 ->
+ custom:container-demuxer-webm: 4f35f7cbe854078d1ac9338744f61a02 ->
+ custom:container-muxer-webm: aa71ff27fc2769a1b78a27578f13a17b ->
+ custom:video-decoder-webm-vp8: 9c59270c3fd7afecdb556c50c9e8de78 ->
+ custom:SearchIndexIgnoredProperties: e643bd26f0fe6173181afceb89e7c659 ->
+ custom:AudioImporter_EditorPlatform: d09bf68614088b80899f8185d706f6e7 ->
+ custom:video-encoder-webm-vp8: eb34c28f22e8b96e1ab97ce403110664 ->
+ custom:audio-decoder-ogg-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/OdinLVector3.cs: 335a14c82456d6f8a32079e834218188 ->
+ custom:audio-encoder-webm-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+========================================================================
+Received Import Request.
+ Time since last request: 618241.049248 seconds.
+ path: Assets/Scripts/GASSamples/GAS/Config/GameplayEffectLib/GE_JisolDemo1.asset
+ artifactKey: Guid(25ef9a2206b693c4f9b93af896a038a8) Importer(815301076,1909f56bfc062723c751e8b465ee728b)
+Start importing Assets/Scripts/GASSamples/GAS/Config/GameplayEffectLib/GE_JisolDemo1.asset using Guid(25ef9a2206b693c4f9b93af896a038a8) Importer(815301076,1909f56bfc062723c751e8b465ee728b) -> (artifact id: '8feb0e18d1eda18ae435bb996a87b853') in 0.012677 seconds
+Number of updated asset objects reloaded before import = 0
+Number of asset objects unloaded after import = 4
+========================================================================
+Received Prepare
+Begin MonoManager ReloadAssembly
+- Loaded All Assemblies, in 0.631 seconds
+Refreshing native plugins compatible for Editor in 37.39 ms, found 3 plugins.
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+[Package Manager] Server::EnsureServerProcessIsRunning -- launch failed, reason: Unity was launched with the -noUpm command-line argument
+[Package Manager] UpmClient::Send -- Unable to send message (not connected to UPM process).
+[Package Manager] Cannot connect to Unity Package Manager local server
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 1.411 seconds
+Domain Reload Profiling: 2030ms
+ BeginReloadAssembly (165ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (3ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (43ms)
+ RebuildCommonClasses (25ms)
+ RebuildNativeTypeToScriptingClass (8ms)
+ initialDomainReloadingComplete (62ms)
+ LoadAllAssembliesAndSetupDomain (358ms)
+ LoadAssemblies (426ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (16ms)
+ TypeCache.Refresh (7ms)
+ TypeCache.ScanAssembly (0ms)
+ ScanForSourceGeneratedMonoScriptInfo (0ms)
+ ResolveRequiredComponents (7ms)
+ FinalizeReload (1413ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (656ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (30ms)
+ SetLoadedEditorAssemblies (3ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (74ms)
+ ProcessInitializeOnLoadAttributes (303ms)
+ ProcessInitializeOnLoadMethodAttributes (218ms)
+ AfterProcessingInitializeOnLoad (28ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (14ms)
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Refreshing native plugins compatible for Editor in 41.90 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Unloading 5551 Unused Serialized files (Serialized files now loaded: 0)
+Unloading 134 unused Assets / (203.6 KB). Loaded Objects now: 6048.
+Memory consumption went from 210.6 MB to 210.4 MB.
+Total: 15.395000 ms (FindLiveObjects: 0.396400 ms CreateObjectMapping: 0.264700 ms MarkObjects: 14.428400 ms DeleteObjects: 0.303800 ms)
+
+Prepare: number of updated asset objects reloaded= 0
+AssetImportParameters requested are different than current active one (requested -> active):
+ custom:container-demuxer-ogg: 62fdf1f143b41e24485cea50d1cbac27 ->
+ custom:video-codec-MediaFoundation-h265: 746d11721c4dcdbdad8f713fa42b33f4 ->
+ custom:video-decoder-ogg-theora: a1e56fd34408186e4bbccfd4996cb3dc ->
+ custom:framework-win-MediaFoundation: 216162199b28c13a410421893ffa2e32 ->
+ custom:CustomObjectIndexerAttribute: 43b350a4d6e6d1791af0b5038c4bea17 ->
+ custom:container-demuxer-webm: 4f35f7cbe854078d1ac9338744f61a02 ->
+ custom:container-muxer-webm: aa71ff27fc2769a1b78a27578f13a17b ->
+ custom:video-decoder-webm-vp8: 9c59270c3fd7afecdb556c50c9e8de78 ->
+ custom:SearchIndexIgnoredProperties: e643bd26f0fe6173181afceb89e7c659 ->
+ custom:AudioImporter_EditorPlatform: d09bf68614088b80899f8185d706f6e7 ->
+ custom:video-encoder-webm-vp8: eb34c28f22e8b96e1ab97ce403110664 ->
+ custom:audio-decoder-ogg-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/OdinLVector3.cs: 335a14c82456d6f8a32079e834218188 ->
+ custom:audio-encoder-webm-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
diff --git a/JNFrame2/Logs/AssetImportWorker1.log b/JNFrame2/Logs/AssetImportWorker1.log
new file mode 100644
index 00000000..47415682
--- /dev/null
+++ b/JNFrame2/Logs/AssetImportWorker1.log
@@ -0,0 +1,331 @@
+Using pre-set license
+Built from '2022.3/china_unity/release' branch; Version is '2022.3.16f1c1 (2f3f1b3bde89) revision 3096347'; Using compiler version '192829333'; Build Type 'Release'
+OS: 'Windows 11 (10.0.22631) 64bit Core' Language: 'zh' Physical Memory: 16088 MB
+BatchMode: 1, IsHumanControllingUs: 0, StartBugReporterOnCrash: 0, Is64bit: 1, IsPro: 1
+
+COMMAND LINE ARGUMENTS:
+C:\APP\UnityEdit\2022.3.16f1c1\Editor\Unity.exe
+-adb2
+-batchMode
+-noUpm
+-name
+AssetImportWorker1
+-projectPath
+D:/Jisol/JisolGame/JNFrame2
+-logFile
+Logs/AssetImportWorker1.log
+-srvPort
+53829
+Successfully changed project path to: D:/Jisol/JisolGame/JNFrame2
+D:/Jisol/JisolGame/JNFrame2
+[UnityMemory] Configuration Parameters - Can be set up in boot.config
+ "memorysetup-bucket-allocator-granularity=16"
+ "memorysetup-bucket-allocator-bucket-count=8"
+ "memorysetup-bucket-allocator-block-size=33554432"
+ "memorysetup-bucket-allocator-block-count=8"
+ "memorysetup-main-allocator-block-size=16777216"
+ "memorysetup-thread-allocator-block-size=16777216"
+ "memorysetup-gfx-main-allocator-block-size=16777216"
+ "memorysetup-gfx-thread-allocator-block-size=16777216"
+ "memorysetup-cache-allocator-block-size=4194304"
+ "memorysetup-typetree-allocator-block-size=2097152"
+ "memorysetup-profiler-bucket-allocator-granularity=16"
+ "memorysetup-profiler-bucket-allocator-bucket-count=8"
+ "memorysetup-profiler-bucket-allocator-block-size=33554432"
+ "memorysetup-profiler-bucket-allocator-block-count=8"
+ "memorysetup-profiler-allocator-block-size=16777216"
+ "memorysetup-profiler-editor-allocator-block-size=1048576"
+ "memorysetup-temp-allocator-size-main=16777216"
+ "memorysetup-job-temp-allocator-block-size=2097152"
+ "memorysetup-job-temp-allocator-block-size-background=1048576"
+ "memorysetup-job-temp-allocator-reduction-small-platforms=262144"
+ "memorysetup-allocator-temp-initial-block-size-main=262144"
+ "memorysetup-allocator-temp-initial-block-size-worker=262144"
+ "memorysetup-temp-allocator-size-background-worker=32768"
+ "memorysetup-temp-allocator-size-job-worker=262144"
+ "memorysetup-temp-allocator-size-preload-manager=33554432"
+ "memorysetup-temp-allocator-size-nav-mesh-worker=65536"
+ "memorysetup-temp-allocator-size-audio-worker=65536"
+ "memorysetup-temp-allocator-size-cloud-worker=32768"
+ "memorysetup-temp-allocator-size-gi-baking-worker=262144"
+ "memorysetup-temp-allocator-size-gfx=262144"
+Player connection [27260] Host "[IP] 192.168.31.185 [Port] 0 [Flags] 2 [Guid] 520795433 [EditorId] 520795433 [Version] 1048832 [Id] WindowsEditor(7,DESKTOP-5RP3AKU) [Debug] 1 [PackageName] WindowsEditor [ProjectName] Editor" joined multi-casting on [225.0.0.222:54997]...
+
+Player connection [27260] Host "[IP] 192.168.31.185 [Port] 0 [Flags] 2 [Guid] 520795433 [EditorId] 520795433 [Version] 1048832 [Id] WindowsEditor(7,DESKTOP-5RP3AKU) [Debug] 1 [PackageName] WindowsEditor [ProjectName] Editor" joined alternative multi-casting on [225.0.0.222:34997]...
+
+[Physics::Module] Initialized MultithreadedJobDispatcher with 19 workers.
+Refreshing native plugins compatible for Editor in 108.96 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Initialize engine version: 2022.3.16f1c1 (2f3f1b3bde89)
+[Subsystems] Discovering subsystems at path C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/Resources/UnitySubsystems
+[Subsystems] Discovering subsystems at path D:/Jisol/JisolGame/JNFrame2/Assets
+GfxDevice: creating device client; threaded=0; jobified=0
+Direct3D:
+ Version: Direct3D 11.0 [level 11.1]
+ Renderer: NVIDIA GeForce RTX 3060 Laptop GPU (ID=0x2520)
+ Vendor: NVIDIA
+ VRAM: 5996 MB
+ Driver: 31.0.15.5176
+Initialize mono
+Mono path[0] = 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/Managed'
+Mono path[1] = 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/MonoBleedingEdge/lib/mono/unityjit-win32'
+Mono config path = 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/MonoBleedingEdge/etc'
+Using monoOptions --debugger-agent=transport=dt_socket,embedding=1,server=y,suspend=n,address=127.0.0.1:56564
+Begin MonoManager ReloadAssembly
+Registering precompiled unity dll's ...
+Register platform support module: C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/PlaybackEngines/AndroidPlayer/UnityEditor.Android.Extensions.dll
+Register platform support module: C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/PlaybackEngines/WindowsStandaloneSupport/UnityEditor.WindowsStandalone.Extensions.dll
+Registered in 0.016605 seconds.
+- Loaded All Assemblies, in 0.401 seconds
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+Android Extension - Scanning For ADB Devices 690 ms
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 0.962 seconds
+Domain Reload Profiling: 1355ms
+ BeginReloadAssembly (135ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (0ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (1ms)
+ RebuildCommonClasses (30ms)
+ RebuildNativeTypeToScriptingClass (8ms)
+ initialDomainReloadingComplete (76ms)
+ LoadAllAssembliesAndSetupDomain (142ms)
+ LoadAssemblies (125ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (139ms)
+ TypeCache.Refresh (138ms)
+ TypeCache.ScanAssembly (123ms)
+ ScanForSourceGeneratedMonoScriptInfo (0ms)
+ ResolveRequiredComponents (0ms)
+ FinalizeReload (963ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (920ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (790ms)
+ SetLoadedEditorAssemblies (2ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (2ms)
+ ProcessInitializeOnLoadAttributes (88ms)
+ ProcessInitializeOnLoadMethodAttributes (38ms)
+ AfterProcessingInitializeOnLoad (0ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (0ms)
+========================================================================
+Worker process is ready to serve import requests
+Begin MonoManager ReloadAssembly
+- Loaded All Assemblies, in 1.096 seconds
+Refreshing native plugins compatible for Editor in 57.71 ms, found 3 plugins.
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+Package Manager log level set to [2]
+[Package Manager] Server::EnsureServerProcessIsRunning -- launch failed, reason: Unity was launched with the -noUpm command-line argument
+[Package Manager] UpmClient::Send -- Unable to send message (not connected to UPM process).
+[Package Manager] Cannot connect to Unity Package Manager local server
+Launched and connected shader compiler UnityShaderCompiler.exe after 0.05 seconds
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 0.921 seconds
+Domain Reload Profiling: 2003ms
+ BeginReloadAssembly (150ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (4ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (18ms)
+ RebuildCommonClasses (27ms)
+ RebuildNativeTypeToScriptingClass (8ms)
+ initialDomainReloadingComplete (68ms)
+ LoadAllAssembliesAndSetupDomain (829ms)
+ LoadAssemblies (667ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (259ms)
+ TypeCache.Refresh (234ms)
+ TypeCache.ScanAssembly (213ms)
+ ScanForSourceGeneratedMonoScriptInfo (18ms)
+ ResolveRequiredComponents (6ms)
+ FinalizeReload (921ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (807ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (26ms)
+ SetLoadedEditorAssemblies (3ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (61ms)
+ ProcessInitializeOnLoadAttributes (407ms)
+ ProcessInitializeOnLoadMethodAttributes (291ms)
+ AfterProcessingInitializeOnLoad (18ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (6ms)
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Refreshing native plugins compatible for Editor in 34.81 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Unloading 5569 Unused Serialized files (Serialized files now loaded: 0)
+Unloading 175 unused Assets / (231.2 KB). Loaded Objects now: 6017.
+Memory consumption went from 210.4 MB to 210.2 MB.
+Total: 13.806200 ms (FindLiveObjects: 0.281700 ms CreateObjectMapping: 0.155000 ms MarkObjects: 13.090200 ms DeleteObjects: 0.278100 ms)
+
+AssetImportParameters requested are different than current active one (requested -> active):
+ custom:container-demuxer-ogg: 62fdf1f143b41e24485cea50d1cbac27 ->
+ custom:video-codec-MediaFoundation-h265: 746d11721c4dcdbdad8f713fa42b33f4 ->
+ custom:video-decoder-ogg-theora: a1e56fd34408186e4bbccfd4996cb3dc ->
+ custom:framework-win-MediaFoundation: 216162199b28c13a410421893ffa2e32 ->
+ custom:CustomObjectIndexerAttribute: 43b350a4d6e6d1791af0b5038c4bea17 ->
+ custom:container-demuxer-webm: 4f35f7cbe854078d1ac9338744f61a02 ->
+ custom:scripting/monoscript/fileName/m_generatorPluginAttribute.cs: b059e60ee6785702b3dbf85733765f7f -> bef7912753b2bc58bba0d70946e69a22
+ custom:scripting/monoscript/fileName/m_generatorAttribute.cs: 9a3832caedb205d9d2bd83dcddfd1f7d -> 4d18a73bcdf3c1dd8d7046481e79d093
+ custom:container-muxer-webm: aa71ff27fc2769a1b78a27578f13a17b ->
+ custom:video-decoder-webm-vp8: 9c59270c3fd7afecdb556c50c9e8de78 ->
+ custom:SearchIndexIgnoredProperties: e643bd26f0fe6173181afceb89e7c659 ->
+ custom:AudioImporter_EditorPlatform: d09bf68614088b80899f8185d706f6e7 ->
+ custom:video-encoder-webm-vp8: eb34c28f22e8b96e1ab97ce403110664 ->
+ custom:audio-decoder-ogg-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/OdinLVector3.cs: 335a14c82456d6f8a32079e834218188 ->
+ custom:audio-encoder-webm-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/m_generatorPackageAttribute.cs: e10470c8d55ee14386c756ed32808741 -> c0108c2656ca6f9f00b8de673fb8aace
+========================================================================
+Received Prepare
+Begin MonoManager ReloadAssembly
+- Loaded All Assemblies, in 0.900 seconds
+Refreshing native plugins compatible for Editor in 37.13 ms, found 3 plugins.
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+[Package Manager] Server::EnsureServerProcessIsRunning -- launch failed, reason: Unity was launched with the -noUpm command-line argument
+[Package Manager] UpmClient::Send -- Unable to send message (not connected to UPM process).
+[Package Manager] Cannot connect to Unity Package Manager local server
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 1.913 seconds
+Domain Reload Profiling: 2796ms
+ BeginReloadAssembly (206ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (3ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (48ms)
+ RebuildCommonClasses (40ms)
+ RebuildNativeTypeToScriptingClass (10ms)
+ initialDomainReloadingComplete (85ms)
+ LoadAllAssembliesAndSetupDomain (542ms)
+ LoadAssemblies (618ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (36ms)
+ TypeCache.Refresh (21ms)
+ TypeCache.ScanAssembly (10ms)
+ ScanForSourceGeneratedMonoScriptInfo (7ms)
+ ResolveRequiredComponents (8ms)
+ FinalizeReload (1914ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (551ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (25ms)
+ SetLoadedEditorAssemblies (3ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (60ms)
+ ProcessInitializeOnLoadAttributes (254ms)
+ ProcessInitializeOnLoadMethodAttributes (187ms)
+ AfterProcessingInitializeOnLoad (21ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (9ms)
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Refreshing native plugins compatible for Editor in 38.75 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Unloading 5552 Unused Serialized files (Serialized files now loaded: 0)
+Unloading 134 unused Assets / (203.6 KB). Loaded Objects now: 6032.
+Memory consumption went from 208.9 MB to 208.7 MB.
+Total: 13.841200 ms (FindLiveObjects: 0.330300 ms CreateObjectMapping: 0.248000 ms MarkObjects: 12.998900 ms DeleteObjects: 0.262700 ms)
+
+Prepare: number of updated asset objects reloaded= 0
+AssetImportParameters requested are different than current active one (requested -> active):
+ custom:container-demuxer-ogg: 62fdf1f143b41e24485cea50d1cbac27 ->
+ custom:video-codec-MediaFoundation-h265: 746d11721c4dcdbdad8f713fa42b33f4 ->
+ custom:video-decoder-ogg-theora: a1e56fd34408186e4bbccfd4996cb3dc ->
+ custom:framework-win-MediaFoundation: 216162199b28c13a410421893ffa2e32 ->
+ custom:CustomObjectIndexerAttribute: 43b350a4d6e6d1791af0b5038c4bea17 ->
+ custom:container-demuxer-webm: 4f35f7cbe854078d1ac9338744f61a02 ->
+ custom:container-muxer-webm: aa71ff27fc2769a1b78a27578f13a17b ->
+ custom:video-decoder-webm-vp8: 9c59270c3fd7afecdb556c50c9e8de78 ->
+ custom:SearchIndexIgnoredProperties: e643bd26f0fe6173181afceb89e7c659 ->
+ custom:AudioImporter_EditorPlatform: d09bf68614088b80899f8185d706f6e7 ->
+ custom:video-encoder-webm-vp8: eb34c28f22e8b96e1ab97ce403110664 ->
+ custom:audio-decoder-ogg-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/OdinLVector3.cs: 335a14c82456d6f8a32079e834218188 ->
+ custom:audio-encoder-webm-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+========================================================================
+Received Prepare
+Begin MonoManager ReloadAssembly
+- Loaded All Assemblies, in 0.635 seconds
+Refreshing native plugins compatible for Editor in 37.42 ms, found 3 plugins.
+Native extension for WindowsStandalone target not found
+Native extension for Android target not found
+[Package Manager] Server::EnsureServerProcessIsRunning -- launch failed, reason: Unity was launched with the -noUpm command-line argument
+[Package Manager] UpmClient::Send -- Unable to send message (not connected to UPM process).
+[Package Manager] Cannot connect to Unity Package Manager local server
+Mono: successfully reloaded assembly
+- Finished resetting the current domain, in 1.413 seconds
+Domain Reload Profiling: 2034ms
+ BeginReloadAssembly (168ms)
+ ExecutionOrderSort (0ms)
+ DisableScriptedObjects (3ms)
+ BackupInstance (0ms)
+ ReleaseScriptingObjects (0ms)
+ CreateAndSetChildDomain (43ms)
+ RebuildCommonClasses (24ms)
+ RebuildNativeTypeToScriptingClass (8ms)
+ initialDomainReloadingComplete (63ms)
+ LoadAllAssembliesAndSetupDomain (357ms)
+ LoadAssemblies (429ms)
+ RebuildTransferFunctionScriptingTraits (0ms)
+ AnalyzeDomain (15ms)
+ TypeCache.Refresh (6ms)
+ TypeCache.ScanAssembly (0ms)
+ ScanForSourceGeneratedMonoScriptInfo (0ms)
+ ResolveRequiredComponents (7ms)
+ FinalizeReload (1413ms)
+ ReleaseScriptCaches (0ms)
+ RebuildScriptCaches (0ms)
+ SetupLoadedEditorAssemblies (658ms)
+ LogAssemblyErrors (0ms)
+ InitializePlatformSupportModulesInManaged (29ms)
+ SetLoadedEditorAssemblies (3ms)
+ RefreshPlugins (0ms)
+ BeforeProcessingInitializeOnLoad (74ms)
+ ProcessInitializeOnLoadAttributes (305ms)
+ ProcessInitializeOnLoadMethodAttributes (219ms)
+ AfterProcessingInitializeOnLoad (27ms)
+ EditorAssembliesLoaded (0ms)
+ ExecutionOrderSort2 (0ms)
+ AwakeInstancesAfterBackupRestoration (14ms)
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Shader 'FairyGUI/TextMeshPro/Distance Field': fallback shader 'TextMeshPro/Mobile/Distance Field' not found
+Refreshing native plugins compatible for Editor in 43.08 ms, found 3 plugins.
+Preloading 0 native plugins for Editor in 0.00 ms.
+Unloading 5552 Unused Serialized files (Serialized files now loaded: 0)
+Unloading 134 unused Assets / (202.8 KB). Loaded Objects now: 6047.
+Memory consumption went from 210.8 MB to 210.6 MB.
+Total: 15.860200 ms (FindLiveObjects: 0.350300 ms CreateObjectMapping: 0.218400 ms MarkObjects: 15.055800 ms DeleteObjects: 0.234300 ms)
+
+Prepare: number of updated asset objects reloaded= 0
+AssetImportParameters requested are different than current active one (requested -> active):
+ custom:container-demuxer-ogg: 62fdf1f143b41e24485cea50d1cbac27 ->
+ custom:video-codec-MediaFoundation-h265: 746d11721c4dcdbdad8f713fa42b33f4 ->
+ custom:video-decoder-ogg-theora: a1e56fd34408186e4bbccfd4996cb3dc ->
+ custom:framework-win-MediaFoundation: 216162199b28c13a410421893ffa2e32 ->
+ custom:CustomObjectIndexerAttribute: 43b350a4d6e6d1791af0b5038c4bea17 ->
+ custom:container-demuxer-webm: 4f35f7cbe854078d1ac9338744f61a02 ->
+ custom:container-muxer-webm: aa71ff27fc2769a1b78a27578f13a17b ->
+ custom:video-decoder-webm-vp8: 9c59270c3fd7afecdb556c50c9e8de78 ->
+ custom:SearchIndexIgnoredProperties: e643bd26f0fe6173181afceb89e7c659 ->
+ custom:AudioImporter_EditorPlatform: d09bf68614088b80899f8185d706f6e7 ->
+ custom:video-encoder-webm-vp8: eb34c28f22e8b96e1ab97ce403110664 ->
+ custom:audio-decoder-ogg-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
+ custom:scripting/monoscript/fileName/OdinLVector3.cs: 335a14c82456d6f8a32079e834218188 ->
+ custom:audio-encoder-webm-vorbis: bf7c407c2cedff20999df2af8eb42d56 ->
diff --git a/JNFrame2/Logs/shadercompiler-AssetImportWorker0.log b/JNFrame2/Logs/shadercompiler-AssetImportWorker0.log
new file mode 100644
index 00000000..d5ac9076
--- /dev/null
+++ b/JNFrame2/Logs/shadercompiler-AssetImportWorker0.log
@@ -0,0 +1,6 @@
+Base path: 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data', plugins path 'C:/APP/UnityEdit/2022.3.16f1c1/Editor/Data/PlaybackEngines'
+Cmd: initializeCompiler
+
+Cmd: preprocess
+ insize=4032 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=195
+
diff --git a/JNFrame2/Logs/shadercompiler-UnityShaderCompiler.exe0.log b/JNFrame2/Logs/shadercompiler-UnityShaderCompiler.exe0.log
index 2b95176f..8d134f46 100644
--- a/JNFrame2/Logs/shadercompiler-UnityShaderCompiler.exe0.log
+++ b/JNFrame2/Logs/shadercompiler-UnityShaderCompiler.exe0.log
@@ -10,3 +10,21 @@ Cmd: preprocess
Cmd: preprocess
insize=1516 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=295
+Cmd: preprocess
+ insize=4032 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=195
+
+Cmd: preprocess
+ insize=1516 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=295
+
+Cmd: preprocess
+ insize=4032 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=195
+
+Cmd: preprocess
+ insize=1516 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=295
+
+Cmd: preprocess
+ insize=4032 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=195
+
+Cmd: preprocess
+ insize=1516 file=/ surfaceOnly=0 buildPlatform=19 validAPIs=295472 pKW=SHADER_API_DESKTOP dKW=UNITY_NO_DXT5nm UNITY_ENABLE_REFLECTION_BUFFERS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_SCREENSPACE_SHADOWS UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS UNITY_PBS_USE_BRDF1 UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_NO_FULL_STANDARD_SHADER UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING UNITY_ENABLE_DETAIL_NORMALMAP UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_COLORSPACE_GAMMA UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_LIGHTMAP_FULL_HDR UNITY_VIRTUAL_TEXTURING UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_ASTC_NORMALMAP_ENCODING SHADER_API_GLES30 UNITY_UNIFIED_SHADER_PRECISION_MODEL ok=1 outsize=295
+
diff --git a/JNFrame2/ProjectSettings/AttributeAsset.asset b/JNFrame2/ProjectSettings/AttributeAsset.asset
index b6aabe65..793737d1 100644
--- a/JNFrame2/ProjectSettings/AttributeAsset.asset
+++ b/JNFrame2/ProjectSettings/AttributeAsset.asset
@@ -17,8 +17,11 @@ MonoBehaviour:
Comment: "\u8840\u91CF"
CalculateMode: 0
SupportedOperation: 31
- DefaultValue: 0
+ DefaultValue:
+ rawValue: 0
LimitMinValue: 0
- MinValue: -3.4028235e+38
+ MinValue:
+ rawValue: -9223372036854775808
LimitMaxValue: 0
- MaxValue: 3.4028235e+38
+ MaxValue:
+ rawValue: 9223372036854775807