public static string maxplayer = string.Empty; //최대 입찰자 #endregion // Use this for initialization void Start() { lconstructor = GameObject.Find("LandConstructor").GetComponent <LandConstructor>(); cmanager = GameObject.Find("CardManager").GetComponent <CardManager>(); startbutton = GameObject.Find("StartButton"); endbutton = GameObject.Find("TurnEnd"); endbutton.SetActive(false); oplayerbutton = GameObject.Find("OtherPlayersButton"); oplayerbutton.SetActive(false); ainfobutton = GameObject.Find("AuctionInfoButton"); ainfobutton.SetActive(false); playerfield = GameObject.Find("PField"); help = GameObject.Find("Help"); help.transform.Find("Scrollbar Vertical").GetComponent <Scrollbar>().value = 1; help.SetActive(false); chatfield = GameObject.Find("ChatField"); turnpname = ""; systemtext = GameObject.Find("SystemText").GetComponent <Text>(); turntext = GameObject.Find("TurnText").GetComponent <Text>(); roundtext = GameObject.Find("RoundText").GetComponent <Text>(); IsGame = false; //IsAuction = true; //IsSelect = false; pinfo = new PlayerInfo[PhotonNetwork.playerList.Length]; price = 0; lnum = -1; //처음 위치 저장 AInfopos = auctiontext.transform.parent.position; InitPlayer(); if (players.Length == 1 || !PhotonNetwork.isMasterClient) { startbutton.SetActive(false); } IsPlayersPlayingCard = new bool[players.Length]; for (int i = 0; i < pinfo.Length; i++) { IsPlayersPlayingCard[i] = true; } if (PhotonNetwork.isMasterClient) { lconstructor.ChangeSource(); playersprice = new int[players.Length]; source = lconstructor.GetSource();//현재 경매에 나온 자원을 받아옴. SendSAuction(PhotonTargets.All, source.SourceName, source.SourceMoney); } }
private float multiple;//배율 //Renderer blockcolor; // Use this for initialization void Start() { owner = null; multiple = 1; lconstructor = GameObject.Find("LandConstructor").GetComponent <LandConstructor>(); amanager = GameObject.Find("GameManager").GetComponent <AuctionManager>(); //blockcolor = GetComponent<Renderer>(); //자기 위치에 텍스트 생성 ltext = Instantiate(text, Camera.main.WorldToScreenPoint(transform.position), Quaternion.identity); ltext.transform.SetParent(GameObject.Find("GameBoard").transform, true); //캔버스의 자식으로 둠 //false로 하면 위치가 좀 이상해짐 }