private void Start() { Vibration.Init(); GameUI.SetInitialDisplayedKnifeCount(knifeCount); SpawnKnife(); }
void Start() { Vibration.Init(); Debug.Log(proximity); StartCoroutine(VibrateWithProximity()); _material = new Material(Shader); }
private void Start() { m_startPosition = gameObject.transform.position; m_pointsText.text = "+" + point + ""; boid = gameObject; Vibration.Init(); }
void Start() { circle = GameObject.FindWithTag("Circle"); GameManag = GameObject.Find("GameManager"); hitsScript = GameManag.GetComponent <GameManagers>(); MCanvas = GameObject.Find("MainCanvas"); Vibration.Init(); }
private void Awake() { _rigidbody = GetComponent <Rigidbody>(); _boxCollider = GetComponent <BoxCollider>(); SetBoxCollider(true); Vibration.Init(); _moneyText = GameObject.FindWithTag("Money").GetComponent <SetText>(); _scoreText = GameObject.FindWithTag("Score").GetComponent <ScoreText>(); }
private void Start() { knifeOnStartScreen = Instantiate(knifePrefab); knifeOnStartScreen.transform.position = new Vector2(0, -1); SkinShop.S.SetCurrentSkin(); Vibration.Init(); }
// Start is called before the first frame update void Awake() { Vibration.Init(); recordKni = PlayerPrefs.GetInt("RK"); GetComponent <SpriteRenderer>().sprite = log.masterPiece; goal = log.knivesNeeded; allKnives = PlayerPrefs.GetInt("AK"); this.spriteRenderer = GetComponent <SpriteRenderer>(); this.circleCollider2D = GetComponent <CircleCollider2D>(); }
protected override void Initialize() { QualitySettings.vSyncCount = 0; Application.targetFrameRate = 60; LoadMainScene(); StageMax = sceneNames.Length; Vibration.Init(); // Bind(); }
public void KillEnemy() { Vibration.Init(); Vibration.VibratePop(); AudioSource.PlayClipAtPoint(deathSound, new Vector3(0, 0, -10), 0.7f); var splatter = Instantiate(enemySplatter, gameObject.transform.position, gameObject.transform.rotation); splatter.Play(); Destroy(gameObject); }
private void Awake() { Vibration.Init(); if (Instance == null) { Instance = this; } filePath = Application.persistentDataPath + "data.gamesave"; LoadGame(); }
private void Awake() { if (audioSource == null) { audioSource = Instantiate(GameObjects.gameObjects.Music); DontDestroyOnLoad(audioSource); }; Vibration.Init(); Levels.Stages(Data.CurrentStage); gameObject.SetActive(true); Data.Load(); }
private void Start() { isGameActive = true; knivesCount = Random.Range(minKnivesAtLevel, maxKnivesAtLevel); gameUI.SetKnivesCount(knivesCount); KnifeSpawn(); appleScore = Database.instance.LoadAppleScore(); gameScore = 0; levelIndex = 1; ScoresController.instance.RefreshScore(gameScore, appleScore); Vibration.Init(); //To perform vibrations. }
private void Awake() { if (_instance == null) { _instance = this; } else { Destroy(gameObject); } plane = new Plane(new Vector3(0.0f, -2f, 0.0f), new Vector3(-0.2f, 0.8f, 1f)); _sliceableAsync = GetComponent <IBzSliceableAsync> (); Vibration.Init(); }
// Start is called before the first frame update void Start() { debugScreen.SetActive(false); string path = Application.persistentDataPath + "/progress.bin"; if (File.Exists(path)) { stageMax = Save.LoadPlayer().stage; bonusAmount = Save.LoadPlayer().bonus; record = Save.LoadPlayer().record; } Vibration.Init(); enemy1.SetActive(false); enemy.SetActive(false); knifeCount = Random.Range(1, 5); boss.SetActive(false); }
private void Start() { float screenRatio = (float)Screen.height / Screen.width; //Adjust UI and camera view to fit screen size if (screenRatio < 1.7f) { Camera.main.GetComponent <CameraConstantWidth>().WidthOrHeight = 1f; } else if (screenRatio > 1.95f) { GameObject.Find("Canvas").GetComponent <CanvasScaler>().matchWidthOrHeight = .6f; } InitializeNotifications(); //Push notifications init and shedule in 8 hours CreateNotification("Hello!", "It's time to throw knives! ", System.DateTime.Now.AddSeconds(28800)); Vibration.Init(); }
public void DecreaseHealth() { Vibration.Init(); Vibration.VibrateNope(); AudioSource.PlayClipAtPoint(hitSound, new Vector3(0, 0, -10)); GetComponent <SpriteFlash>().Flash(); health--; GameObject.Find("HUD").GetComponent <HudManager>().setHealthbar(health); if (health <= 0) { ShowAd(); gameOverMoneyText.text = $" + {coins}"; gameOverScreen.GetComponent <GameOver>().ActivateGameOver(); gameProperties.GetComponent <GameProperties>().IncreaseMoney(coins); endScoreText.text = $"Score: {score}"; gameObject.SetActive(false); ES3AutoSaveMgr.Current.Save(); } }
private int vibrationOption; //переменная показывающая нужно включать вибрацию или нет private void Start() { vibrationOption = PlayerPrefs.GetInt("Vibration"); //Получаем значение опции вибрация Vibration.Init(); //инициализируем скрипт с методами вибрации }
private void Awake() { Vibration.Init(); knifeRigidbody = GetComponent <Rigidbody2D>(); knifeCollider = GetComponent <BoxCollider2D>(); }
private void Awake() { _automationType.Add(AutomationType.ClickAutomation, new ClickAutomation()); _automationType.Add(AutomationType.UsualAutomation, new UsualAutomation()); _skillType.Add(SkillType.AutomationPower, new AutomationPowerUpgrader()); _skillType.Add(SkillType.AutomationsPower, new AutomationsDamageUpgrader()); _skillType.Add(SkillType.ClickPower, new ClickPowerUpgrader()); _skillType.Add(SkillType.AutomationClickPower, new ClickPowerAutomationUpgrader()); if (_deleteExistingDataOnDevice) { DeleteData(); } if (FileOperations.IsFileExist(_settingsDataFileName) == false) { _playerData.Init(); _badgeData.Init(); _automationsData.Init(); SaveData(); } else { GetData(); } #if UNITY_EDITOR _godMode.Init(_playerData); #endif var builder = new AutomationBuilder(_playerData, _automationsData, _automationPrefab); foreach (var automationData in _automationData) { builder.InstantiateAutomation(_automationsParent, automationData.Data); builder.SetAutomationType(_automationType[automationData.AutomationType]); var skillsData = automationData.Data.UpgradeComponents; foreach (var skill in skillsData) { builder.AddSkill(_skillType[skill.Skill], skill); } } _tutorial.Init(_playerData); _audioService.Init(); _settings.Init(_settingsData); Vibration.Init(_settingsData); _farmLevelButton.Init(_playerData); _adsManager.Init(); _offlineProgress.Init(_playerData, _badgeData, _automationsData); _gameResetter.Init( _playerData, _automationsData, _badgeData, _defaultAutomationsData); _playerStatsPresentation.Init(_playerData); _badge.Init(_playerData, _automationsData, _badgeData); _automationsService = new AutomationsService(_playerData, _automationsData); //_automationsService.Init(_playerData, _automationsData); _playerData.IsReturningPlayer = true; }
private void Start() { InitializeObjects(); UploadData(); Vibration.Init(); }
// Start is called before the first frame update void Start() { Vibration.Init(); // scoreText.GetComponent<Text>().text = score.ToString(); }
private void Start() { Vibration.Init(); }
public void Start() { Vibration.Init(); }
// Use this for initialization void Start() { Vibration.Init(); Debug.Log("Application.isMobilePlatform: " + Application.isMobilePlatform); txtAndroidVersion.text = "Android Version: " + Vibration.AndroidVersion.ToString(); }
// Start is called before the first frame update void Start() { Vibration.Init(); PlayerPrefs.SetInt("Level", SceneManager.GetActiveScene().buildIndex); }
public void Equip() { Vibration.Init(); Vibration.VibrateNope(); gameManager.GetComponent <GameProperties>().SetPlayerSprite(playerSprite.GetComponent <Image>().sprite); }