Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial integration of new protobufs #3

Merged
merged 1 commit into from
Jun 18, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ game-tracking:
git remote add -f origin https://github.com/SteamDatabase/GameTracking && \
git config core.sparseCheckout true && \
echo Protobufs/dota/ >> .git/info/sparse-checkout && \
echo Protobufs/dota_reborn/ >> .git/info/sparse-checkout && \
echo Protobufs/dota_s2/ >> .git/info/sparse-checkout && \
echo Protobufs/dota_test/ >> .git/info/sparse-checkout && \
git pull --depth=1 origin master
Expand All @@ -28,7 +29,7 @@ update-game-tracking: game-tracking

gen-dota-proto: dota/google/protobuf/descriptor.pb.go
rm -rf dota/*.proto
cp -f game-tracking/Protobufs/dota_s2/*/*.proto -t dota/ || true
cp -f game-tracking/Protobufs/dota_reborn/*/*.proto -t dota/ || true
sed -i 's/^\(\s*\)\(optional\|repeated\|required\|extend\)\s*\./\1\2 /' dota/*.proto
sed -i 's!^\s*rpc\s*\(\S*\)\s*(\.\([^)]*\))\s*returns\s*(\.\([^)]*\))\s*{!rpc \1 (\2) returns (\3) {!' dota/*.proto
sed -i '1ipackage dota;\n' dota/*.proto
Expand All @@ -41,7 +42,7 @@ dota/google/protobuf/descriptor.pb.go: google/protobuf/descriptor.proto
protoc -I. --go_out=dota $<

gen-game-events:
go run gen/game_event.go fixtures/game_events_list.pbmsg game_event_lookup.go
go run gen/game_event.go fixtures/source_1_legacy_game_events_list.pbmsg game_event_lookup.go

gen-message-lookup:
go run gen/message_lookup.go dota message_lookup.go
Expand Down
2 changes: 1 addition & 1 deletion class_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ func (p *Parser) onCDemoClassInfo(m *dota.CDemoClassInfo) error {

// Updates the state of instancebaseline
func (p *Parser) updateInstanceBaseline() {
// We can't update the instancebaseline until we have class info.
if !p.hasClassInfo {
_debugf("skipping updateInstanceBaseline: no class info")
return
}

Expand Down
188 changes: 81 additions & 107 deletions dota/base_gcmessages.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 15 additions & 18 deletions dota/base_gcmessages.proto
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ enum EGCBaseMsg {
k_EMsgGCError = 4509;
k_EMsgGCReplay_UploadedToYouTube = 4510;
k_EMsgGCLANServerAvailable = 4511;
k_EMsgGCInviteToLobby = 4512;
k_EMsgGCLobbyInviteResponse = 4513;
}

enum EGCBaseProtoObjectTypes {
Expand Down Expand Up @@ -52,18 +54,6 @@ message CMsgGCStorePurchaseInitResponse {
optional uint64 txn_id = 2;
}

message CSOPartyInvite {
optional uint64 group_id = 1 [(key_field) = true];
optional fixed64 sender_id = 2;
optional string sender_name = 3;
}

message CSOLobbyInvite {
optional uint64 group_id = 1 [(key_field) = true];
optional fixed64 sender_id = 2;
optional string sender_name = 3;
}

message CMsgSystemBroadcast {
optional string message = 1;
}
Expand All @@ -75,6 +65,11 @@ message CMsgInviteToParty {
optional bool as_coach = 4;
}

message CMsgInviteToLobby {
optional fixed64 steam_id = 1;
optional uint32 client_version = 2;
}

message CMsgInvitationCreated {
optional uint64 group_id = 1;
optional fixed64 steam_id = 2;
Expand All @@ -90,6 +85,14 @@ message CMsgPartyInviteResponse {
optional string game_language_name = 7;
}

message CMsgLobbyInviteResponse {
optional fixed64 lobby_id = 1;
optional bool accept = 2;
optional uint32 client_version = 3;
optional uint32 game_language_enum = 4;
optional string game_language_name = 5;
}

message CMsgKickFromParty {
optional fixed64 steam_id = 1;
}
Expand Down Expand Up @@ -202,12 +205,6 @@ message CSOEconItem {
repeated CSOEconItemEquipped equipped_state = 18;
}

message CMsgAdjustItemEquippedState {
optional uint64 item_id = 1;
optional uint32 new_class = 2;
optional uint32 new_slot = 3;
}

message CMsgSortItems {
optional uint32 sort_type = 1;
}
Expand Down
Loading