Skip to content
This repository has been archived by the owner on Nov 19, 2024. It is now read-only.

Commit

Permalink
Merge pull request #11 from Maren0000/pr-1
Browse files Browse the repository at this point in the history
Add CS_10018 and SC_10019 to dissection tool
  • Loading branch information
Molly authored Jul 11, 2024
2 parents 2e473de + 095c188 commit 21f62c7
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion misc/proto_to_json.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ func ProtoToJson(packetId int, data *[]byte) (string, error) {
var err error
var output []byte
switch packetId {
case 64007:
case 64007:
var p protobuf.CS_64007
if err = proto.Unmarshal(*data, &p); err != nil {
return "", err
Expand Down Expand Up @@ -5382,6 +5382,18 @@ func ProtoToJson(packetId int, data *[]byte) (string, error) {
return "", err
}
output, err = json.MarshalIndent(p, "", " ")
case 10018:
var p protobuf.CS_10018
if err = proto.Unmarshal(*data, &p); err != nil {
return "", err
}
output, err = json.MarshalIndent(p, "", " ")
case 10019:
var p protobuf.SC_10019
if err = proto.Unmarshal(*data, &p); err != nil {
return "", err
}
output, err = json.MarshalIndent(p, "", " ")
}
return string(output), err
}

0 comments on commit 21f62c7

Please sign in to comment.