ํฌํค ๊ธฐ๋ณธ ์์ ๋ฒ ์ด์ค๋ก ๋ง๋ค๊ณ ์๋๋ฐย
{
#pragma warning disable 649
/// <summary>
/// Player manager.
/// Handles fire Input and Beams.
/// </summary>
public class PlayerManager : MonoBehaviourPunCallbacks, IPunObservable
{
๋ด๋ถ์
if(Input.GetKeyDown(KeyCode.B)){
photonView.RPC("AttackOpponent", RpcTarget.AllBuffered, 10);
}
์ด๋ ๊ฒ ์จ๋๊ณ ์คํ ์ํค๋ฉด ์ ์คํ๋จ. ํ๋ ์ด์ด ๋๋ค.
๊ทผ๋ฐ ๋ด๊ฐ ์ง์ ์ด ํด๋์ค์์
if (SelectedCardList.Count == 5){
PlayerManager.LocalPlayerInstance.GetComponent<PlayerManager>().photonView.RPC("AttackOpponent",PhotonNetwork.CurrentRoom.GetPlayer(2),7 );
PlayerManager.LocalPlayerInstance.GetComponent<PlayerManager>().photonView.RPC("AttackOpponent",PhotonNetwork.CurrentRoom.GetPlayer(1),7 );
์๊ฐ์ด ์ฐ๋ฉด ๋ก์ปฌํ๋ ์ด์ด๊ป ์ ๋ฐ์ดํธ๊ฐ ๋๋๋ฐย ์๋๊บผ๋ย ์ ๋ฐ์ดํธ๊ฐ ์๋์.
OthersBuffered๋ก ํด๋ ๋๊ฐ์.
์ด๋ป๊ฒ ํด์ผ ์ธ๋ถ์์ RPC ๋ก ์ ์ด ๊ฐ๋ฅํ๊ฐ์?
๋๊ธ 0