//Float3DText名称 //对应FloatTextType枚举值 //private string[] FloatText3DPath = { // "", // "AttackDamageText", // "AttackCritDamageText", // "TreatText", // "TreatCritText", // "HurtDamageText", // "HurtCritDamageText", // "ExpText", // "AttackMissText", // "DodgeText" //}; //Float2DText名称 //对应FloatTextType枚举值 //private string[] FloatText2DPath = { // "", // "AttackDamage2DText", // "AttackCritDamage2DText", // "Treat2DText", // "TreatCrit2DText", // "HurtDamage2DText", // "HurtCritDamage2DText", // "Exp2DText", // "AttackMiss2DText", // "Dodge2DText" //}; private string GetDisplayByFloatTextType(FloatTextType type, string value = "") { //Match with bmfont string result = ""; switch (type) { case FloatTextType.Attack: case FloatTextType.Hurt: case FloatTextType.Treat: case FloatTextType.TreatCrit: result = value; break; case FloatTextType.AttackCrit: case FloatTextType.HurtCrit: result = "~" + value; break; case FloatTextType.GetExp: result = "jy+" + value; break; case FloatTextType.Dodge: result = "sb"; break; case FloatTextType.AttackMiss: result = "wmz"; break; } return(result); }
/// <summary> /// 转换成可支持的类型; /// </summary> private FloatTextType ConvertType(/*需要定义*/) { FloatTextType value = FloatTextType.None; //转换FloatTextType return(value); }
public static void WriteFloatTextType(this PacketWriter writer, FloatTextType data) { writer.WriteByte((byte)data); }