|
|
|
|
@ -52,6 +52,7 @@ namespace OMS.NET.Instructs
|
|
|
|
|
"get_presence" => JsonSerializer.Deserialize<GetPresenceInstruct>(root.GetRawText(), options),
|
|
|
|
|
"get_mapData" => JsonSerializer.Deserialize<GetMapDataInstruct>(root.GetRawText(), options),
|
|
|
|
|
"get_mapLayer" => JsonSerializer.Deserialize<GetMapLayerInstruct>(root.GetRawText(), options),
|
|
|
|
|
"ping" => JsonSerializer.Deserialize<PingInstuct>(root.GetRawText(), options),
|
|
|
|
|
|
|
|
|
|
//广播指令
|
|
|
|
|
"broadcast" => classValue switch
|
|
|
|
|
@ -61,7 +62,7 @@ namespace OMS.NET.Instructs
|
|
|
|
|
_ => JsonSerializer.Deserialize<Instruct>(root.GetRawText(), options)
|
|
|
|
|
},
|
|
|
|
|
_ => null
|
|
|
|
|
} ?? throw new JsonException("反序列化失败");
|
|
|
|
|
} ?? throw new JsonException($"{typeValue} 反序列化失败");
|
|
|
|
|
return instruct;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
|