-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a basic implementation of battlegrounds in preparation for cross-…
…realm
- Loading branch information
Showing
84 changed files
with
6,524 additions
and
408 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
syntax = "proto3"; | ||
package v1; | ||
|
||
option go_package = "gen/matchmaking/pb"; | ||
|
||
service MatchmakingService { | ||
rpc EnqueueToBattleground(EnqueueToBattlegroundRequest) returns (EnqueueToBattlegroundResponse); | ||
|
||
rpc BattlegroundQueueDataForPlayer(BattlegroundQueueDataForPlayerRequest) returns (BattlegroundQueueDataForPlayerResponse); | ||
|
||
rpc PlayerLeftBattleground(PlayerLeftBattlegroundRequest) returns (PlayerLeftBattlegroundResponse); | ||
rpc PlayerJoinedBattleground(PlayerJoinedBattlegroundRequest) returns (PlayerJoinedBattlegroundResponse); | ||
rpc BattlegroundStatusChanged(BattlegroundStatusChangedRequest) returns (BattlegroundStatusChangedResponse); | ||
} | ||
|
||
enum PVPTeamID { | ||
Any = 0; | ||
Alliance = 1; | ||
Horde = 2; | ||
} | ||
|
||
enum PlayerQueueStatus { | ||
NotInQueue = 0; | ||
InQueue = 1; | ||
Invited = 2; | ||
InProgress = 3; | ||
} | ||
|
||
message EnqueueToBattlegroundRequest { | ||
string api = 1; | ||
uint32 realmID = 2; | ||
|
||
uint64 leaderGUID = 3; | ||
repeated uint64 partyMembers = 4; | ||
|
||
uint32 leadersLvl = 5; | ||
|
||
uint32 bgTypeID = 6; | ||
PVPTeamID teamID = 7; | ||
} | ||
|
||
message EnqueueToBattlegroundResponse { | ||
string api = 1; | ||
} | ||
|
||
message BattlegroundQueueDataForPlayerRequest { | ||
string api = 1; | ||
|
||
uint32 realmID = 2; | ||
uint64 playerGUID = 3; | ||
} | ||
|
||
message BattlegroundQueueDataForPlayerResponse { | ||
string api = 1; | ||
|
||
message AssignedBattlegroundData { | ||
uint32 assignedBattlegroundInstanceID = 1; | ||
uint32 mapID = 2; | ||
uint32 battlegroupID = 3; | ||
string gameserverAddress = 4; | ||
string gameserverGRPCAddress = 5; | ||
} | ||
|
||
message QueueSlot { | ||
uint32 bgTypeID = 1; | ||
PlayerQueueStatus status = 2; | ||
optional AssignedBattlegroundData assignedBattlegroundData = 3; | ||
}; | ||
|
||
repeated QueueSlot slots = 2; | ||
} | ||
|
||
message PlayerLeftBattlegroundRequest { | ||
string api = 1; | ||
|
||
uint32 realmID = 2; | ||
uint64 playerGUID = 3; | ||
uint32 instanceID = 4; | ||
bool isCrossRealm = 5; | ||
} | ||
|
||
message PlayerLeftBattlegroundResponse { | ||
string api = 1; | ||
} | ||
|
||
message PlayerJoinedBattlegroundRequest { | ||
string api = 1; | ||
|
||
uint32 realmID = 2; | ||
uint64 playerGUID = 3; | ||
uint32 instanceID = 4; | ||
bool isCrossRealm = 5; | ||
} | ||
|
||
message PlayerJoinedBattlegroundResponse { | ||
string api = 1; | ||
} | ||
|
||
message BattlegroundStatusChangedRequest { | ||
string api = 1; | ||
|
||
uint32 realmID = 2; | ||
uint32 instanceID = 3; | ||
bool isCrossRealm = 4; | ||
|
||
// Use the same statuses as in gameserver (AC/TC) | ||
enum Status { | ||
None = 0; // unused | ||
WaitQueue = 1; // unused | ||
WaitJoin = 2; // unused | ||
InProgress = 3; | ||
Ended = 4; | ||
} | ||
Status status = 5; | ||
} | ||
|
||
message BattlegroundStatusChangedResponse { | ||
string api = 1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,14 @@ | ||
package game_load_balancer | ||
|
||
var RealmID uint32 | ||
|
||
var RetrievedBalancerID string | ||
|
||
const ( | ||
Ver = "0.0.1" | ||
SupportedCharServiceVer = "0.0.1" | ||
SupportedServerRegistryVer = "0.0.1" | ||
SupportedMailServiceVer = "0.0.1" | ||
SupportedGroupServiceVer = "0.0.1" | ||
Ver = "0.0.1" | ||
SupportedCharServiceVer = "0.0.1" | ||
SupportedServerRegistryVer = "0.0.1" | ||
SupportedMailServiceVer = "0.0.1" | ||
SupportedGroupServiceVer = "0.0.1" | ||
SupportedMatchmakingServiceVer = "0.0.1" | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.