- LocalizationManager: 新增翻译表(SetFormatted/SetDuration/LocalizeOperateMsg) - LoginPanel: InputField placeholder本地化、字体颜色保持 - HistoryPanel: 用时数据本地化、placeholder本地化 - RecordDetailPanel: 操作详情消息本地化(LanguageChanged重建) - AppraiseWindowBase: 评价等级本地化、操作消息重建 - EditorAppraiser: 所有评估消息改用InjectOperateMsgLocalized - StudentOperateRecorder: 新增InjectOperateMsgLocalized方法 - LocalizationLanguageTestBar: 单例模式、ScreenSpaceOverlay筛选 - 字体切换时保留颜色和verticalOverflow
88 lines
1.8 KiB
C#
88 lines
1.8 KiB
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using System;
|
|
namespace XFramework
|
|
{
|
|
/// <summary>
|
|
/// 可序列化的Vector3
|
|
/// </summary>
|
|
|
|
[Serializable]
|
|
public struct VectorThree
|
|
{
|
|
public float x;
|
|
public float y;
|
|
public float z;
|
|
|
|
public VectorThree(float x, float y, float z)
|
|
{
|
|
this.x = x;
|
|
this.y = y;
|
|
this.z = z;
|
|
}
|
|
|
|
public VectorThree(Vector3 vector3)
|
|
{
|
|
x = vector3.x;
|
|
y = vector3.y;
|
|
z = vector3.z;
|
|
}
|
|
|
|
public Vector3 GetVector3()
|
|
{
|
|
return new Vector3(x, y, z);
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// 可序列化的Vector2
|
|
/// </summary>
|
|
[Serializable]
|
|
public struct VectorTwo
|
|
{
|
|
public float x;
|
|
public float y;
|
|
|
|
public VectorTwo(float x, float y)
|
|
{
|
|
this.x = x;
|
|
this.y = y;
|
|
}
|
|
public VectorTwo(Vector2 vector2)
|
|
{
|
|
x = vector2.x;
|
|
y = vector2.y;
|
|
}
|
|
|
|
public Vector2 GetVector2()
|
|
{
|
|
return new Vector2(x, y);
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// 物体姿态同步数据 位置+角度
|
|
/// </summary>
|
|
[Serializable]
|
|
public struct TransGesture
|
|
{
|
|
public VectorThree pos;
|
|
public VectorThree rotAngle;
|
|
public TransGesture(Vector3 pos, Vector3 eulerAngle)
|
|
{
|
|
this.pos = new VectorThree( pos);
|
|
this.rotAngle = new VectorThree( eulerAngle);
|
|
}
|
|
public Vector3 GetPos()
|
|
{
|
|
return new Vector3(pos.x, pos.y, pos.z);
|
|
}
|
|
public Vector3 GetRotAnlgle()
|
|
{
|
|
return new Vector3(rotAngle.x, rotAngle.y, rotAngle.z);
|
|
}
|
|
}
|
|
}
|
|
|