mirror of
https://github.com/Maks1mS/pppi-rpg-game.git
synced 2024-12-23 22:32:59 +03:00
273 lines
16 KiB
HTML
273 lines
16 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||
<head>
|
||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
||
<meta name="generator" content="Doxygen 1.9.1"/>
|
||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||
<title>PPPI RPG Game: Класс MultiplayerManager</title>
|
||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||
<script type="text/javascript" src="jquery.js"></script>
|
||
<script type="text/javascript" src="dynsections.js"></script>
|
||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||
<script type="text/javascript" src="search/search.js"></script>
|
||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||
</head>
|
||
<body>
|
||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||
<div id="titlearea">
|
||
<table cellspacing="0" cellpadding="0">
|
||
<tbody>
|
||
<tr style="height: 56px;">
|
||
<td id="projectalign" style="padding-left: 0.5em;">
|
||
<div id="projectname">PPPI RPG Game
|
||
</div>
|
||
</td>
|
||
</tr>
|
||
</tbody>
|
||
</table>
|
||
</div>
|
||
<!-- end header part -->
|
||
<!-- Создано системой Doxygen 1.9.1 -->
|
||
<script type="text/javascript">
|
||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
||
var searchBox = new SearchBox("searchBox", "search",false,'Поиск','.html');
|
||
/* @license-end */
|
||
</script>
|
||
<script type="text/javascript" src="menudata.js"></script>
|
||
<script type="text/javascript" src="menu.js"></script>
|
||
<script type="text/javascript">
|
||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
||
$(function() {
|
||
initMenu('',true,false,'search.php','Поиск');
|
||
$(document).ready(function() { init_search(); });
|
||
});
|
||
/* @license-end */</script>
|
||
<div id="main-nav"></div>
|
||
<!-- window showing the filter options -->
|
||
<div id="MSearchSelectWindow"
|
||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||
</div>
|
||
|
||
<!-- iframe showing the search results (closed by default) -->
|
||
<div id="MSearchResultsWindow">
|
||
<iframe src="javascript:void(0)" frameborder="0"
|
||
name="MSearchResults" id="MSearchResults">
|
||
</iframe>
|
||
</div>
|
||
|
||
</div><!-- top -->
|
||
<div class="header">
|
||
<div class="summary">
|
||
<a href="#pub-methods">Открытые члены</a> |
|
||
<a href="#pri-methods">Закрытые члены</a> |
|
||
<a href="class_multiplayer_manager-members.html">Полный список членов класса</a> </div>
|
||
<div class="headertitle">
|
||
<div class="title">Класс MultiplayerManager</div> </div>
|
||
</div><!--header-->
|
||
<div class="contents">
|
||
|
||
<p>Класс <a class="el" href="class_multiplayer_manager.html" title="Класс MultiplayerManager позволяет игрокам взаимодействовать друг с другом в онлайн-режиме.">MultiplayerManager</a> позволяет игрокам взаимодействовать друг с другом в онлайн-режиме.
|
||
<a href="class_multiplayer_manager.html#details">Подробнее...</a></p>
|
||
|
||
<p><code>#include <<a class="el" href="multiplayer__manager_8h_source.html">multiplayer_manager.h</a>></code></p>
|
||
<table class="memberdecls">
|
||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
|
||
Открытые члены</h2></td></tr>
|
||
<tr class="memitem:a7e748fa6ce2900814ccd47dfd5c243b6"><td class="memItemLeft" align="right" valign="top"><a id="a7e748fa6ce2900814ccd47dfd5c243b6"></a>
|
||
void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#a7e748fa6ce2900814ccd47dfd5c243b6">initializeNetwork</a> ()</td></tr>
|
||
<tr class="memdesc:a7e748fa6ce2900814ccd47dfd5c243b6"><td class="mdescLeft"> </td><td class="mdescRight">Инициализирует сетевую инфраструктуру для мультиплеера. <br /></td></tr>
|
||
<tr class="separator:a7e748fa6ce2900814ccd47dfd5c243b6"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:a48d2617d5398f6e55a68e38c1fb37a8b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#a48d2617d5398f6e55a68e38c1fb37a8b">createSession</a> ()</td></tr>
|
||
<tr class="memdesc:a48d2617d5398f6e55a68e38c1fb37a8b"><td class="mdescLeft"> </td><td class="mdescRight">Создает новую мультиплеерную сессию. <a href="class_multiplayer_manager.html#a48d2617d5398f6e55a68e38c1fb37a8b">Подробнее...</a><br /></td></tr>
|
||
<tr class="separator:a48d2617d5398f6e55a68e38c1fb37a8b"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:a7b6261976a4ad3c2de89b8db964959f7"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#a7b6261976a4ad3c2de89b8db964959f7">joinSession</a> ()</td></tr>
|
||
<tr class="memdesc:a7b6261976a4ad3c2de89b8db964959f7"><td class="mdescLeft"> </td><td class="mdescRight">Присоединяется к существующей мультиплеерной сессии. <a href="class_multiplayer_manager.html#a7b6261976a4ad3c2de89b8db964959f7">Подробнее...</a><br /></td></tr>
|
||
<tr class="separator:a7b6261976a4ad3c2de89b8db964959f7"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:a8713ca0191b7261126272dafca29f2cf"><td class="memItemLeft" align="right" valign="top"><a id="a8713ca0191b7261126272dafca29f2cf"></a>
|
||
void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#a8713ca0191b7261126272dafca29f2cf">updateNetworkEvents</a> ()</td></tr>
|
||
<tr class="memdesc:a8713ca0191b7261126272dafca29f2cf"><td class="mdescLeft"> </td><td class="mdescRight">Обрабатывает события сети и обновляет состояние мультиплеера. <br /></td></tr>
|
||
<tr class="separator:a8713ca0191b7261126272dafca29f2cf"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:aa484c5d22767eab88a7af456ac6a099f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#aa484c5d22767eab88a7af456ac6a099f">sendData</a> ()</td></tr>
|
||
<tr class="memdesc:aa484c5d22767eab88a7af456ac6a099f"><td class="mdescLeft"> </td><td class="mdescRight">Отправляет данные игрока на сервер или другим игрокам. <a href="class_multiplayer_manager.html#aa484c5d22767eab88a7af456ac6a099f">Подробнее...</a><br /></td></tr>
|
||
<tr class="separator:aa484c5d22767eab88a7af456ac6a099f"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:a11316b07e85272b4e78b5aa54a4780d5"><td class="memItemLeft" align="right" valign="top"><a id="a11316b07e85272b4e78b5aa54a4780d5"></a>
|
||
void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#a11316b07e85272b4e78b5aa54a4780d5">receiveData</a> ()</td></tr>
|
||
<tr class="memdesc:a11316b07e85272b4e78b5aa54a4780d5"><td class="mdescLeft"> </td><td class="mdescRight">Получает данные от сервера или других игроков. <br /></td></tr>
|
||
<tr class="separator:a11316b07e85272b4e78b5aa54a4780d5"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:aaa962fd408388cbeb886be26c765926d"><td class="memItemLeft" align="right" valign="top"><a id="aaa962fd408388cbeb886be26c765926d"></a>
|
||
void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#aaa962fd408388cbeb886be26c765926d">closeSession</a> ()</td></tr>
|
||
<tr class="memdesc:aaa962fd408388cbeb886be26c765926d"><td class="mdescLeft"> </td><td class="mdescRight">Завершает сессию и отключается от мультиплеера. <br /></td></tr>
|
||
<tr class="separator:aaa962fd408388cbeb886be26c765926d"><td class="memSeparator" colspan="2"> </td></tr>
|
||
</table><table class="memberdecls">
|
||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-methods"></a>
|
||
Закрытые члены</h2></td></tr>
|
||
<tr class="memitem:ab79c879bd64db377585050b20ae4c77f"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#ab79c879bd64db377585050b20ae4c77f">handlePlayerJoin</a> ()</td></tr>
|
||
<tr class="memdesc:ab79c879bd64db377585050b20ae4c77f"><td class="mdescLeft"> </td><td class="mdescRight">Обрабатывает подключение нового игрока. <a href="class_multiplayer_manager.html#ab79c879bd64db377585050b20ae4c77f">Подробнее...</a><br /></td></tr>
|
||
<tr class="separator:ab79c879bd64db377585050b20ae4c77f"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:a4284fd956b3636f15277f53c83ba712a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#a4284fd956b3636f15277f53c83ba712a">handlePlayerLeave</a> ()</td></tr>
|
||
<tr class="memdesc:a4284fd956b3636f15277f53c83ba712a"><td class="mdescLeft"> </td><td class="mdescRight">Обрабатывает выход игрока из сессии. <a href="class_multiplayer_manager.html#a4284fd956b3636f15277f53c83ba712a">Подробнее...</a><br /></td></tr>
|
||
<tr class="separator:a4284fd956b3636f15277f53c83ba712a"><td class="memSeparator" colspan="2"> </td></tr>
|
||
<tr class="memitem:aac68b4eda8b76435634e85ba150c071a"><td class="memItemLeft" align="right" valign="top"><a id="aac68b4eda8b76435634e85ba150c071a"></a>
|
||
void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_multiplayer_manager.html#aac68b4eda8b76435634e85ba150c071a">synchronizeGameState</a> ()</td></tr>
|
||
<tr class="memdesc:aac68b4eda8b76435634e85ba150c071a"><td class="mdescLeft"> </td><td class="mdescRight">Синхронизирует состояние игры между всеми участниками. <br /></td></tr>
|
||
<tr class="separator:aac68b4eda8b76435634e85ba150c071a"><td class="memSeparator" colspan="2"> </td></tr>
|
||
</table>
|
||
<a name="details" id="details"></a><h2 class="groupheader">Подробное описание</h2>
|
||
<div class="textblock"><p>Класс <a class="el" href="class_multiplayer_manager.html" title="Класс MultiplayerManager позволяет игрокам взаимодействовать друг с другом в онлайн-режиме.">MultiplayerManager</a> позволяет игрокам взаимодействовать друг с другом в онлайн-режиме. </p>
|
||
</div><h2 class="groupheader">Методы</h2>
|
||
<a id="a48d2617d5398f6e55a68e38c1fb37a8b"></a>
|
||
<h2 class="memtitle"><span class="permalink"><a href="#a48d2617d5398f6e55a68e38c1fb37a8b">◆ </a></span>createSession()</h2>
|
||
|
||
<div class="memitem">
|
||
<div class="memproto">
|
||
<table class="memname">
|
||
<tr>
|
||
<td class="memname">void MultiplayerManager::createSession </td>
|
||
<td>(</td>
|
||
<td class="paramname"></td><td>)</td>
|
||
<td></td>
|
||
</tr>
|
||
</table>
|
||
</div><div class="memdoc">
|
||
|
||
<p>Создает новую мультиплеерную сессию. </p>
|
||
<dl class="params"><dt>Аргументы</dt><dd>
|
||
<table class="params">
|
||
<tr><td class="paramname">sessionParams</td><td>Параметры новой сессии. </td></tr>
|
||
</table>
|
||
</dd>
|
||
</dl>
|
||
|
||
</div>
|
||
</div>
|
||
<a id="ab79c879bd64db377585050b20ae4c77f"></a>
|
||
<h2 class="memtitle"><span class="permalink"><a href="#ab79c879bd64db377585050b20ae4c77f">◆ </a></span>handlePlayerJoin()</h2>
|
||
|
||
<div class="memitem">
|
||
<div class="memproto">
|
||
<table class="mlabels">
|
||
<tr>
|
||
<td class="mlabels-left">
|
||
<table class="memname">
|
||
<tr>
|
||
<td class="memname">void MultiplayerManager::handlePlayerJoin </td>
|
||
<td>(</td>
|
||
<td class="paramname"></td><td>)</td>
|
||
<td></td>
|
||
</tr>
|
||
</table>
|
||
</td>
|
||
<td class="mlabels-right">
|
||
<span class="mlabels"><span class="mlabel">private</span></span> </td>
|
||
</tr>
|
||
</table>
|
||
</div><div class="memdoc">
|
||
|
||
<p>Обрабатывает подключение нового игрока. </p>
|
||
<dl class="params"><dt>Аргументы</dt><dd>
|
||
<table class="params">
|
||
<tr><td class="paramname">playerData</td><td>Данные о новом подключившемся игроке. </td></tr>
|
||
</table>
|
||
</dd>
|
||
</dl>
|
||
|
||
</div>
|
||
</div>
|
||
<a id="a4284fd956b3636f15277f53c83ba712a"></a>
|
||
<h2 class="memtitle"><span class="permalink"><a href="#a4284fd956b3636f15277f53c83ba712a">◆ </a></span>handlePlayerLeave()</h2>
|
||
|
||
<div class="memitem">
|
||
<div class="memproto">
|
||
<table class="mlabels">
|
||
<tr>
|
||
<td class="mlabels-left">
|
||
<table class="memname">
|
||
<tr>
|
||
<td class="memname">void MultiplayerManager::handlePlayerLeave </td>
|
||
<td>(</td>
|
||
<td class="paramname"></td><td>)</td>
|
||
<td></td>
|
||
</tr>
|
||
</table>
|
||
</td>
|
||
<td class="mlabels-right">
|
||
<span class="mlabels"><span class="mlabel">private</span></span> </td>
|
||
</tr>
|
||
</table>
|
||
</div><div class="memdoc">
|
||
|
||
<p>Обрабатывает выход игрока из сессии. </p>
|
||
<dl class="params"><dt>Аргументы</dt><dd>
|
||
<table class="params">
|
||
<tr><td class="paramname">playerId</td><td>Идентификатор игрока, который вышел из сессии. </td></tr>
|
||
</table>
|
||
</dd>
|
||
</dl>
|
||
|
||
</div>
|
||
</div>
|
||
<a id="a7b6261976a4ad3c2de89b8db964959f7"></a>
|
||
<h2 class="memtitle"><span class="permalink"><a href="#a7b6261976a4ad3c2de89b8db964959f7">◆ </a></span>joinSession()</h2>
|
||
|
||
<div class="memitem">
|
||
<div class="memproto">
|
||
<table class="memname">
|
||
<tr>
|
||
<td class="memname">void MultiplayerManager::joinSession </td>
|
||
<td>(</td>
|
||
<td class="paramname"></td><td>)</td>
|
||
<td></td>
|
||
</tr>
|
||
</table>
|
||
</div><div class="memdoc">
|
||
|
||
<p>Присоединяется к существующей мультиплеерной сессии. </p>
|
||
<dl class="params"><dt>Аргументы</dt><dd>
|
||
<table class="params">
|
||
<tr><td class="paramname">sessionId</td><td>Идентификатор сессии, к которой присоединяется игрок. </td></tr>
|
||
</table>
|
||
</dd>
|
||
</dl>
|
||
|
||
</div>
|
||
</div>
|
||
<a id="aa484c5d22767eab88a7af456ac6a099f"></a>
|
||
<h2 class="memtitle"><span class="permalink"><a href="#aa484c5d22767eab88a7af456ac6a099f">◆ </a></span>sendData()</h2>
|
||
|
||
<div class="memitem">
|
||
<div class="memproto">
|
||
<table class="memname">
|
||
<tr>
|
||
<td class="memname">void MultiplayerManager::sendData </td>
|
||
<td>(</td>
|
||
<td class="paramname"></td><td>)</td>
|
||
<td></td>
|
||
</tr>
|
||
</table>
|
||
</div><div class="memdoc">
|
||
|
||
<p>Отправляет данные игрока на сервер или другим игрокам. </p>
|
||
<dl class="params"><dt>Аргументы</dt><dd>
|
||
<table class="params">
|
||
<tr><td class="paramname">data</td><td>Данные для отправки. </td></tr>
|
||
</table>
|
||
</dd>
|
||
</dl>
|
||
|
||
</div>
|
||
</div>
|
||
<hr/>Объявления и описания членов класса находятся в файле:<ul>
|
||
<li><a class="el" href="multiplayer__manager_8h_source.html">multiplayer_manager.h</a></li>
|
||
</ul>
|
||
</div><!-- contents -->
|
||
<!-- start footer part -->
|
||
<hr class="footer"/><address class="footer"><small>
|
||
Создано системой <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1
|
||
</small></address>
|
||
</body>
|
||
</html>
|