public MainWindow() { InitializeComponent(); AppPropertys.mainWindow = this; AppPropertys.Initialize(); PlayController.Initialize(); }
// Use this for initialization void Start () { sound = GetComponent<AudioSource>(); sound.Play (); // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag ("PlayController"); if (playController == null) { SceneManager.LoadScene ("menu"); return; } play = playController.GetComponent<PlayController>(); // Playコントローラーがない場合は無条件でメニュー画面に戻る bentoObj1 = GameObject.FindWithTag ("BentoObj"); if (bentoObj1 == null) { SceneManager.LoadScene ("menu"); return; } bentoObj1.transform.localScale = new Vector3 (0.15f, 0.15f, transform.localScale.z); bentoObj1.transform.position = new Vector3 (0.0f, -1.5f, transform.localScale.z); bentoObj2 = (GameObject)Instantiate (bentoObj1, new Vector3 (-2.55f, -1.5f, 0.0f), Quaternion.identity); bentoObj3 = (GameObject)Instantiate (bentoObj1, new Vector3 (2.55f, -1.5f, 0.0f), Quaternion.identity); Invoke ("ShowFab", 8.0f); Invoke ("ShowResult", 8.0f); Invoke ("ChangeScene", sound.clip.length + 0.5f); }
// Use this for initialization void Start() { sound = GetComponent <AudioSource>(); sound.Play(); // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag("PlayController"); if (playController == null) { SceneManager.LoadScene("menu"); return; } play = playController.GetComponent <PlayController>(); // Playコントローラーがない場合は無条件でメニュー画面に戻る bentoObj1 = GameObject.FindWithTag("BentoObj"); if (bentoObj1 == null) { SceneManager.LoadScene("menu"); return; } bentoObj1.transform.localScale = new Vector3(0.15f, 0.15f, transform.localScale.z); bentoObj1.transform.position = new Vector3(0.0f, -1.5f, transform.localScale.z); bentoObj2 = (GameObject)Instantiate(bentoObj1, new Vector3(-2.55f, -1.5f, 0.0f), Quaternion.identity); bentoObj3 = (GameObject)Instantiate(bentoObj1, new Vector3(2.55f, -1.5f, 0.0f), Quaternion.identity); Invoke("ShowFab", 8.0f); Invoke("ShowResult", 8.0f); Invoke("ChangeScene", sound.clip.length + 0.5f); }
// Use this for initialization void Start () { AudioSource[] audioSources = GetComponents<AudioSource>(); BGM = audioSources[0]; BGMonVoice = audioSources[1]; BGMonVoice.Play (); Invoke ("PlayNoVoice", BGMonVoice.clip.length); // メインBGMを止める GameObject obj = GameObject.FindWithTag ("MainBgmController"); if (obj != null) { GameObject.Destroy (obj); } buttonCloseMenuCol.enabled = false; // Playコントローラーがある場合は削除してからインスタンス生成する GameObject obj2 = GameObject.FindWithTag ("PlayController"); if (obj2 != null) { GameObject.Destroy (obj2); } playController = (GameObject)Instantiate (playControllerPrefab); play = playController.GetComponent<PlayController>(); // お題表示 Invoke ("ShowFab", 6.0f); }
static void Main() { Application.SetHighDpiMode(HighDpiMode.SystemAware); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); //HttpClient client = new HttpClient(); //HttpResponseMessage response = await client.GetAsync("http://localhost:8080/accounts/"); //response.EnsureSuccessStatusCode(); AuthView = new AuthView(); ConnectView = new ConnectView(); LoginView = new LoginView(); PlayView = new PlayView(); RegisterView = new RegisterView(); CreditBankMenurView = new CreditBankMenuView(); CreditBankAuthenticationVIew = new CreditBankAuthenticationVIew(); AuthController = new AuthController(); ConnectController = new ConnectController(); PlayController = new PlayController(); AuthController = new AuthController(); CreditBankController = new CreditBankController(); Application.Run(ConnectView); }
public BoardView(PlayController playController) { this._playController = playController; this._secretCombinationView = new SecretCombinationView(this._playController); this._proposedCombinationView = new ProposedCombinationView(this._playController); this._resultView = new ResultView(this._playController); }
public void PrivateBoardClear_EqualTrue() { PlayController playController = new PlayController(); PrivateObject privateObject = new PrivateObject(playController); ICheckersCell[] checkersCell = new ICheckersCell[] { null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, }; privateObject.Invoke("BoardClear"); IBoard board = (IBoard)(privateObject.GetFieldOrProperty("Board")); for (int i = 1; i <= board.Size; i++) { Assert.AreEqual(checkersCell[i - 1], board[i]); } }
void Awake() { base.Awake(); perfilController = GetComponent <PerfilController>(); playController = GetComponent <PlayController>(); sesionController = GetComponent <SesionController>(); }
private void TextBlock_MouseDown_2(object sender, MouseButtonEventArgs e) { if (e.ChangedButton == MouseButton.Left) { PlayController.PlayNext(); } }
/// <summary> /// Configuration of app /// </summary> public void Configuration(IAppBuilder app) { JoinController.Configure(app); MasterController.Configure(app); VotingController.Configure(app); PlayController.Configure(app); }
// Use this for initialization void Start() { AudioSource[] audioSources = GetComponents <AudioSource>(); BGM = audioSources[0]; BGMonVoice = audioSources[1]; voiceFinish = audioSources[2]; BGMonVoice.Play(); Invoke("PlayNoVoice", BGMonVoice.clip.length); buttonYesCol.enabled = false; buttonNoCol.enabled = false; // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag("PlayController"); if (playController == null) { SceneManager.LoadScene("menu"); return; } play = playController.GetComponent <PlayController>(); // 表示 play.InitObj(); play.Show(-1); }
private void Image_MouseDown(object sender, MouseButtonEventArgs e) { if (e.ChangedButton == MouseButton.Left) { PlayController.setMute(); } }
public PlayControllerTest() { wordsRepositoryMock = new Mock <IWordsRepository>(); gameLogicMock = new Mock <IGameLogic>(); ghostPlayerMock = new Mock <IGhostPlayer>(); controller = new PlayController(wordsRepositoryMock.Object, gameLogicMock.Object, ghostPlayerMock.Object); }
// Use this for initialization void Start() { AudioSource[] audioSources = GetComponents <AudioSource>(); BGM = audioSources[0]; BGMonVoice = audioSources[1]; BGMonVoice.Play(); Invoke("PlayNoVoice", BGMonVoice.clip.length); // メインBGMを止める GameObject obj = GameObject.FindWithTag("MainBgmController"); if (obj != null) { GameObject.Destroy(obj); } buttonCloseMenuCol.enabled = false; // Playコントローラーがある場合は削除してからインスタンス生成する GameObject obj2 = GameObject.FindWithTag("PlayController"); if (obj2 != null) { GameObject.Destroy(obj2); } playController = (GameObject)Instantiate(playControllerPrefab); play = playController.GetComponent <PlayController>(); // お題表示 Invoke("ShowFab", 6.0f); }
public bool Init(GameObject model) { m_DeviceController = new DeviceCtrl(); m_PlayController = new PlayController(model); return(true); }
/// <summary> /// 结束游戏 /// </summary> public void EndGame(PlayController play) { if (playCtrl != null && playCtrl == play) { mapData = null; historyMap = new List <MapData>(); } }
private void playListBox_MouseDoubleClick(object sender, MouseButtonEventArgs e) { if (PlayController.PlayIndex != playListBox.SelectedIndex) { PlayController.PlayIndex = playListBox.SelectedIndex; PlayController.PlayMusic(); } }
public static void Dispose() { if (PlayController != null) { PlayController.Dispose(); PlayController = null; } }
void OnTriggerEnter(Collider col) { if (col.gameObject.name == "Player") { playController = GameObject.Find("Player").GetComponent <PlayController>(); // playController.Died(); StateKill(); } }
private GameObject SpawnCard(Vector3 position, Guid assetId) { Debug.Log("[CgsNet Manager] SpawnCard"); GameObject newCard = Instantiate(playController.cardModelPrefab, playController.playArea.transform); PlayController.SetPlayActions(newCard.GetComponent <CardModel>()); return(newCard); }
public void Interact(PlayController playController) { do { new PlayMenu(playController).execute(); } while (!playController.IsFinished()); playController.NextState(); }
// Use this for initialization void Start () { // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag ("PlayController"); if (playController == null) { SceneManager.LoadScene ("menu"); return; } play = playController.GetComponent<PlayController>(); }
const int LOWEST_DIFF = 1; //lowest diff level public PlayControllerTests() { _controller = new PlayController(); _image = new ImageDBRepository(); _map = new MapDBRepository(); _progress = new ProfileProgressDBRepository(); _minigame = new MiniGamesDBRepository(); _options = new OptionsDBRepository(); }
bool Init(GameObject modelRef, GameObject model, string strFileNameRef) { m_PlayControllerRef = new PlayController(modelRef); m_RecordController = model.GetComponent <ModelCtrl>(); m_DeviceController = new DeviceCtrl(); m_TrailCurveAppraise = new TrailCurveAppraiseCtrl(); m_ReaderRef = new FileReader(strFileNameRef); return(true); }
/// <summary> /// 立即结束游戏 /// </summary> private void ImmediatelyEndGame() { if (playCtrl != null) { playCtrl.EndGame(); playCtrl = null; mapData = null; historyMap = new List <MapData>(); } }
// Use this for initialization void Start() { AudioSource[] audioSources = GetComponents <AudioSource>(); BGM1 = audioSources[0]; BGM1onVoice = audioSources[1]; BGM2 = audioSources[2]; BGM2onVoice = audioSources[3]; BGM3 = audioSources[4]; BGM3onVoice = audioSources[5]; // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag("PlayController"); if (playController == null) { SceneManager.LoadScene("menu"); return; } play = playController.GetComponent <PlayController>(); // リザルト確認 int resultCnt = 0; if (play.fabFlag1) { resultCnt++; } if (play.fabFlag2) { resultCnt++; } if (play.fabFlag3) { resultCnt++; } if (resultCnt >= 2) { Instantiate(result1); BGM1onVoice.Play(); Invoke("PlayNoVoice1", BGM1onVoice.clip.length); } if (resultCnt == 1) { Instantiate(result2); BGM2onVoice.Play(); Invoke("PlayNoVoice2", BGM2onVoice.clip.length); } if (resultCnt == 0) { Instantiate(result3); BGM3onVoice.Play(); Invoke("PlayNoVoice3", BGM3onVoice.clip.length); } }
public void Interact(PlayController playController) { do { ProposedCombinationView proposedCombinationView = new ProposedCombinationView(playController); playController.AddProposedCombination(proposedCombinationView.Read()); new BoardView(playController).Write(); } while (!playController.IsFinished()); playController.Next(); }
void Awake() { if (Instance == null) { Instance = this; } else { Destroy(gameObject); } }
// Use this for initialization void Start() { // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag("PlayController"); if (playController == null) { SceneManager.LoadScene("menu"); return; } play = playController.GetComponent <PlayController>(); }
private void StateKill() { state = "kill"; playerAlive.GetComponent <PlayerAlive>().alive = false; playController.GetComponent <PlayController>().enabled = false; deathCam.SetActive(true); deathCam.transform.position = Camera.main.transform.position; deathCam.transform.rotation = Camera.main.transform.rotation; Camera.main.gameObject.SetActive(false); playController = GameObject.Find("Player").GetComponent <PlayController>(); playController.Died(); Invoke("reset", 3f); }
// ReSharper disable once MemberCanBeMadeStatic.Local private void CmdSpawnCard(string cardId, Vector3 position, Quaternion rotation, bool isFacedown) { var playController = CgsNetManager.Instance.playController; var newCardGameObject = Instantiate(playController.cardModelPrefab, playController.playMat.transform); var cardModel = newCardGameObject.GetComponent <CardModel>(); cardModel.Value = CardGameManager.Current.Cards[cardId]; cardModel.position = position; cardModel.rotation = rotation; cardModel.isFacedown = isFacedown; PlayController.SetPlayActions(cardModel); NetworkServer.Spawn(newCardGameObject); cardModel.RpcHideHighlight(); }
private void btnPlay_MouseDown(object sender, MouseButtonEventArgs e) { if (e.ChangedButton == MouseButton.Left) { if (btnPlay.ToolTip.ToString() != "播放") { PlayController.Pause(); } else { PlayController.Play(); } } }
public void PrivateBoardFilling_EqualTrue() { PlayController playController = new PlayController(); PrivateObject privateObject = new PrivateObject(playController); privateObject.Invoke("BoardClear"); privateObject.Invoke("BoardFilling", 2); IBoard board = (IBoard)(privateObject.GetFieldOrProperty("Board")); IPlayer whitePlayer = (IPlayer)(privateObject.GetFieldOrProperty("WhitePlayer")); IPlayer blackPlayer = (IPlayer)(privateObject.GetFieldOrProperty("BlackPlayer")); IPiece[] pieces = (IPiece[])(privateObject.GetFieldOrProperty("Pieces")); ICheckersCell checkersCellWhite = A.Fake <ICheckersCell>(); A.CallTo(() => checkersCellWhite.Player).Returns(whitePlayer); A.CallTo(() => checkersCellWhite.Piece).Returns(pieces[0]); ICheckersCell checkersCellBlack = A.Fake <ICheckersCell>(); A.CallTo(() => checkersCellBlack.Player).Returns(blackPlayer); A.CallTo(() => checkersCellBlack.Piece).Returns(pieces[0]); ICheckersCell[] checkersCell = new ICheckersCell[] { checkersCellWhite, checkersCellWhite, checkersCellWhite, checkersCellWhite, checkersCellWhite, checkersCellWhite, checkersCellWhite, checkersCellWhite, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, checkersCellBlack, checkersCellBlack, checkersCellBlack, checkersCellBlack, checkersCellBlack, checkersCellBlack, checkersCellBlack, checkersCellBlack, }; for (int i = 1; i <= board.Size; i++) { if (checkersCell[i - 1] == null || board[i] == null) { Assert.AreEqual(checkersCell[i - 1], board[i], $"\ni={i} \nnull "); } else { Assert.AreEqual(checkersCell[i - 1].Player.Name, board[i].Player.Name, $"\ni={i} \nPlayer "); Assert.AreEqual(checkersCell[i - 1].Piece.Name, board[i].Piece.Name, $"\ni={i} \nPiece "); } } }
void Start() { Screen.sleepTimeout = SleepTimeout.NeverSleep; Instance = this; if (cam == null) { cam = Camera.main; } playController = GetComponent<PlayController>(); cutsceneController = GetComponent<SpaceCutscene>(); gameOverController = GetComponent<GameOverController>(); InitLanguage(); GoToCutScene(); }
// Use this for initialization void Start () { AudioSource[] audioSources = GetComponents<AudioSource>(); BGM1 = audioSources[0]; BGM1onVoice = audioSources[1]; BGM2 = audioSources[2]; BGM2onVoice = audioSources[3]; BGM3 = audioSources[4]; BGM3onVoice = audioSources[5]; // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag ("PlayController"); if (playController == null) { SceneManager.LoadScene ("menu"); return; } play = playController.GetComponent<PlayController>(); // リザルト確認 int resultCnt = 0; if (play.fabFlag1) { resultCnt++; } if (play.fabFlag2) { resultCnt++; } if (play.fabFlag3) { resultCnt++; } if (resultCnt >= 2) { Instantiate (result1); BGM1onVoice.Play (); Invoke ("PlayNoVoice1", BGM1onVoice.clip.length); } if (resultCnt == 1) { Instantiate (result2); BGM2onVoice.Play (); Invoke ("PlayNoVoice2", BGM2onVoice.clip.length); } if (resultCnt == 0) { Instantiate (result3); BGM3onVoice.Play (); Invoke ("PlayNoVoice3", BGM3onVoice.clip.length); } }
void Start() { Screen.sleepTimeout = SleepTimeout.NeverSleep; if(cam == null) { cam = Camera.main; } playController = GetComponent<PlayController>(); cutsceneController = GetComponent<CutsceneController>(); gameOverController = GetComponent<GameOverController>(); InitLanguage(); if (SceneManager.GetActiveScene().name == "MelonScene") { GotoTitleScreen(); } else { GoToCutScene(); } }
// Use this for initialization void Start () { AudioSource[] audioSources = GetComponents<AudioSource>(); BGM = audioSources[0]; BGMonVoice = audioSources[1]; voiceFinish = audioSources[2]; BGMonVoice.Play (); Invoke ("PlayNoVoice", BGMonVoice.clip.length); buttonYesCol.enabled = false; buttonNoCol.enabled = false; // Playコントローラーがない場合は無条件でメニュー画面に戻る GameObject playController = GameObject.FindWithTag ("PlayController"); if (playController == null) { SceneManager.LoadScene ("menu"); return; } play = playController.GetComponent<PlayController>(); // 表示 play.InitObj(); play.Show (-1); }
public Player(Fort fort) { _fort = fort; _cardControllerInstance = GameObject.FindObjectOfType<CardController>(); _playControllerInstance = GameObject.FindObjectOfType<PlayController>(); }
void Build() { playController_ = new PlayController(); playController_.Build(); UniqueGameController.Instance.AddGameBehaviour(playController_); }