//Scripts void Awake() { _findSpawner = GameObject.Find("Spawner"); _scoreController = GameObject.Find("ScoreController"); _checkCoins = _scoreController.GetComponent<CoinsController>(); _checkWaveRunning = _findSpawner.GetComponent<UnitSpawner>(); }
void Start() { _scoreController = GameObject.Find("ScoreController"); _checkCoins = _scoreController.GetComponent<CoinsController>(); _EnemyHpScaler = (_Enemyhealth / 2); }
void Start() { _scoreController = GameObject.Find("ScoreController"); _checkCoins = _scoreController.GetComponent <CoinsController>(); _EnemyHpScaler = (_Enemyhealth / 2); }
private void Awake() { InGamePanel.SetActive(true); _coinsController = FindObjectOfType <CoinsController>(); CoinsText.text = _coinsController.GetCoinsAmount().ToString(); SetGradientsAlpha(1, 1); }
// Use this for initialization void Start() { cameraDest = this.transform.position; CoinsController cc = GameObject.FindObjectOfType <CoinsController>(); Instantiate(cc.characters[PlayerPrefs.GetInt("Character", 0)]); }
public App05Game() { graphicsManager = new GraphicsDeviceManager(this); Content.RootDirectory = "Content"; IsMouseVisible = true; coinsController = new CoinsController(); }
public CoinsControllerTests() { var mockCoinsService = new Mock <ICoinsService>(); mockCoinsService.Setup(x => x.GetCoins()).Returns(TestData.Coins.Take(2)); coinsController = new CoinsController(mockCoinsService.Object); }
//Scripts void Awake() { _findSpawner = GameObject.Find("Spawner"); _checkWaveRunning = _findSpawner.GetComponent <UnitSpawner>(); _scoreController = GameObject.Find("ScoreController"); _checkCoins = _scoreController.GetComponent <CoinsController>(); _messagesController = GameObject.Find("MessageController"); _checkMessage = _messagesController.GetComponent <Messages>(); }
void Start() { _hover = GameObject.Find("Hover"); _placeScript = _hover.GetComponent<PlacementMouse>(); _scoreController = GameObject.Find("ScoreController"); _checkCoins = _scoreController.GetComponent<CoinsController>(); _removeBuilding = GameObject.Find("RemoveButton"); _removeBuilding.GetComponent<Button>().onClick.AddListener(removeBool); }
void Start() { _hover = GameObject.Find("Hover"); _placeScript = _hover.GetComponent <PlacementMouse>(); _scoreController = GameObject.Find("ScoreController"); _checkCoins = _scoreController.GetComponent <CoinsController>(); _removeBuilding = GameObject.Find("RemoveButton"); _removeBuilding.GetComponent <Button>().onClick.AddListener(removeBool); }
public async Task TestGetIDSuccessfully() { using (var context = new CryptoCognizantContext(options)) { CoinsController coinsController = new CoinsController(context, _mapper); ActionResult <Coin> result = await coinsController.GetCoin(0); Assert.IsNotNull(result); } }
private void Awake() { if (instance == null) { instance = this; } else { Destroy(this); } }
private void Awake() { Time.timeScale = 1f; _playerMovement = FindObjectOfType <PlayerMovement>(); _artController = FindObjectOfType <ArtController>(); _uiController = FindObjectOfType <UIController>(); _lvlBuilder = FindObjectOfType <LVLBuilder>(); _saveController = FindObjectOfType <SaveController>(); _coinsController = FindObjectOfType <CoinsController>(); _healthController = FindObjectOfType <HealthController>(); StartLvl(); }
/// <summary> /// Setup the game window size to 720P 800 x 1400 pixels /// Simple fixed playing area with no camera or scrolling /// </summary> protected override void Initialize() { graphicsManager.PreferredBackBufferWidth = HD_Width; graphicsManager.PreferredBackBufferHeight = HD_Height; graphicsManager.ApplyChanges(); graphicsDevice = graphicsManager.GraphicsDevice; coinsController = new CoinsController(); base.Initialize(); }
public async Task TestPutCoinNoContentStatusCode() { using (var context = new CryptoCognizantContext(options)) { Boolean newFav = false; Coin coin1 = context.Coin.Where(x => x.IsFavourite == coins[0].IsFavourite).Single(); coin1.IsFavourite = newFav; CoinsController coinsController = new CoinsController(context, _mapper); IActionResult result = await coinsController.PutCoin(coin1.CoinId, coin1) as IActionResult; Assert.IsNotNull(result); Assert.IsInstanceOfType(result, typeof(NoContentResult)); } }
public async Task TestDeleteSuccessfully() { using (var context = new CryptoCognizantContext(options)) { CoinsController coinsController = new CoinsController(context, _mapper); ActionResult <IEnumerable <Coin> > result1 = await coinsController.GetCoin(); ActionResult <Coin> delete = await coinsController.DeleteCoin(0); ActionResult <IEnumerable <Coin> > result2 = await coinsController.GetCoin(); // Assert that coin list changes after coin is deleted Assert.AreNotEqual(result1, result2); } }
public Facade(Form1 playerBoard, Player boardPlayer, CreatorOfPictureBox creator, Timer a, Timer b, Timer c) { state = new StartGame(); gameTimer = a; moveTimer = b; requestTimer = c; coinsController = new CoinsController(); creatorOfPictureBox = creator; this.playerBoard = playerBoard; this.player = boardPlayer; connectionHandler = new ConnectionHandler(boardPlayer); enemyList = new List <Enemy>(); h1 = new YouWon(); h2 = new YouLost(); h1.SetSuccessor(h2); gameAction(); }
public CoinsControllerTests() { _mockCoinService = new Mock <ICoinService>(); _mockCountryService = new Mock <ICountryService>(); _mockCollectorValueService = new Mock <ICollectorValueService>(); _mockCoinService.Setup(c => c.Save()).ReturnsAsync(true); _mockCountryService.Setup(c => c.CountryExists(It.IsAny <Guid>())).ReturnsAsync(true); _mockCollectorValueService .Setup(c => c.FindCollectorValueByValues(It.IsAny <CollectorValue>())) .ReturnsAsync(new CollectorValue()); _controller = new CoinsController(_mockCoinService.Object, _mockCountryService.Object, _mockCollectorValueService.Object, _mapper); SetupTestController(_controller); _builder = new CoinTestBuilder(); resourceParameters = new CurrenciesResourceParameters(); resourceParameters.Fields = "Id, Type"; }
/** * Initialization */ void Start() { groundMaterial = LayerMask.GetMask("Ground"); groundDetection = GameObject.Find("GroundCollision").GetComponent <Transform>(); game = GameObject.Find("GameManager").GetComponent <GameController>(); coinsManager = GameObject.Find("CoinManager").GetComponent <CoinsController>(); maxSpeed = 7.5f; switch (PlayerPrefs.GetInt("Speed")) { case 1: startSpeed += (maxSpeed - startSpeed) / 2; break; case 2: startSpeed = maxSpeed; break; default: break; } playerBody = GetComponent <Rigidbody2D>(); playerAnimator = GetComponent <Animator>(); groundDetectionRadius = GetComponent <BoxCollider2D>().size.x / 2; lastCharacterPosition = transform.position.x; onGround = false; isBendDown = false; leftArm = false; rightArm = false; playerFalling = false; startTime = Time.time; runSound.Play(); }
// Use this for initialization void Start() { iceCollider = GameObject.Find("IceCollider").transform; comboHolder = GameObject.Find("ComboHolder"); forceImage = GameObject.Find("PowerBar").GetComponent <Image>(); scoreText = GameObject.Find("Score").GetComponent <Text>(); camController = GameObject.Find("Main Camera Container").GetComponent <CameraController>(); bgController = GameObject.Find("Main Camera").GetComponent <BackgroundColorController>(); coinsController = GameObject.FindObjectOfType <CoinsController>(); playerParticles = this.GetComponent <EllipsoidParticleEmitter>(); Time.timeScale = 3.67f; rb = this.GetComponent <Rigidbody>(); spotPrefab.GetComponent <SpriteRenderer>().sprite = spotSprites[0]; currentSpot = (GameObject)Instantiate(spotPrefab, new Vector2(this.transform.position.x, this.transform.position.y + 5.925f - ((float)Random.Range(0, 450) / 100)), Quaternion.identity); iceCollider.transform.rotation = Quaternion.Euler(new Vector3(90, 0, 0)); this.transform.rotation = Quaternion.identity; scoreText.text = score.ToString(); }
/** * Initialization */ void Start() { deathMenu = GameObject.Find("DeathMenu").gameObject; deathMenuScore = GameObject.Find("DeathMenuScore").GetComponent <Text>(); deathMenuHighScore = GameObject.Find("DeathMenuHighScore").GetComponent <Text>(); caloriesGoalText = GameObject.Find("CaloriesGoalText").GetComponent <Text>(); gameManager = FindObjectOfType <GameController>(); scoreManager = FindObjectOfType <ScoreController>(); coinsManager = FindObjectOfType <CoinsController>(); caloriesManager = FindObjectOfType <CaloriesController>(); timeManager = FindObjectOfType <TimeController>(); timer = PlayerPrefs.GetInt("Timer"); if (timer > 0) { timeManager.SetIsDead(true); timeManager.FixPreviousTime(); } DisplayScoring(); }
IEnumerator UpdatePointsCoroutine(int points) { CoinsController cc = CoinsController.instance; string textPoints = LANG.GetText(12); string textCoins = LANG.GetText(34); int temp = 0; int temp2 = 0; int pointsTotal = points; float time = 0.2f; if (pointsTotal >= 30) { time = 0.1f; } while (temp <= points) { yield return(new WaitForSeconds(time)); temp++; temp2++; if (temp2 == 10) { cc.coinsOnRun++; pointTextAnim.SetTrigger("OnePlusTrigger"); coinsTakenTXT.text = textCoins + ": " + cc.coinsOnRun; temp2 = 0; } pointsText.text = textPoints + ": " + temp; } cc.SetCoins(cc.coinsOnRun); isPoints = true; Debug.Log("isPoints"); if (isPoints && isLevel) { goBackButton.SetActive(true); } }
void Awake() { current = this; }
// Start is called before the first frame update void Start() { Instance = this; }
//Scripts void Awake() { _scoreController = GameObject.Find("ScoreController"); _checkCoins = _scoreController.GetComponent<CoinsController>(); }
public CoinsControllerTests() { _coinsController = new CoinsController(_mediator.Object); }
/// <summary> /// Create a controller for coins with one coin /// </summary> private void SetupCoins() { coinsController = new CoinsController(game); }
// Use this for initialization void Start() { sharedInstance = this; coinsCount = Constants.Tool_Price - GameManager.sharedInstance.litRoomsNumber; coinsCounterLabel.text = coinsCount.ToString(); }
void Awake() { controller = this; }
void Start() { I = this; coins = PlayerPrefs.GetInt("coins", 2); }