在不同游戏的类型可以用不同的条件配对成团,以下为常见配对後可以接受补位的情境:
Player 1 creates a Ticket (
T1
).Director calls
Backend.FetchMatches
with a MatchProfile.MMF runs
QueryBackfills
andQueryTickets
using the MatchProfile. It returnsT1
.MMF constructs a new Backfill (
B1
) and returns aMatch
containing ticketT1
and BackfillB1
. The Backfill should be created with fieldAllocateGameServer
set totrue
, so the game server orchestrator (e.g.: Agones) knows it has to create a new Game Server. The Director handles making calls to create the Game Server.Director starts allocating a Game Server with Backfill
B1
information.Player 2 creates a Ticket (
T2
).Director calls
Backend.FetchMatches
.MMF runs
QueryBackfills
andQueryTickets
using the MatchProfile. They returnB1
andT2
accordingly.MMF determines
B1
could be used based on data set onB1
by the last run of the MMF (e.g. a number of open slots).T2
andB1
form a new Match.When the Game Server has started, it begins polling Open Match to acknowledge the backfill with
Frontend.AcknowledgeBackfill
using the backfill’s ID (B1.ID
) and supplies connection information for the server, to be returned as theAssignment
data of the ticketsT1
andT2
. The Game Server also receives the ticket data of the tickets that were assigned so that any data supplied on the ticket (e.g. player IDs) may be used by the game server.
由上述流程可以看到一个重点,MMF 是让我们可以使用 backfill 机制的主要角色,想要使用 backfill,我们势必要在我们的 MMF 上,实作出符合补位机制的逻辑。而另一个需要注意的重点是,游戏服务器必须持续的向 Frontend,确认是否有需要补位的情况,透过使用 Frontend.AcknowledgeBackfill
接口,达成 Open-Match 与 Game Server 之间的资讯同步。
前言 当使用者输入资料时,若不小心输入跳脱字元 Escape Character,如 \n or \...
本期想介绍Android Studio上两个实用技巧,使程序撰写时能够事半功倍完成。 1. 代码提示...
不可靠的时钟 (Unreliable Clocks) 时钟对应用程序来说很重要,它可以回答以下问题:...
上一篇是用userDefalt去做资料的新增跟删除,但之前说过,userDefalt有个问题是他只能...
仙女棒 ( 光迹效果 ) 教学原文参考:仙女棒 ( 光迹效果 ) 这篇文章会介绍,如何在 Scrat...