Esempio n. 1
0
 protected virtual void Awake()
 {
     player              = FindObjectOfType <Player>();
     ship                = FindObjectOfType <Ship>();
     creditManager       = CreditManager.Instance();
     soundEffectsManager = SoundEffectsManager.Instance();
 }
Esempio n. 2
0
 // Start is called before the first frame update
 void Start()
 {
     CreditManagerInstance          = GameObject.Find("Main Camera").GetComponent <CreditManager>();
     BallEntranceControllerInstance = GameObject.Find("BallEntrance").GetComponent <BallEntranceController>();
     DefaultGeneratePos             = new Vector3(POS_DEFAULT_X, POS_DEFAULT_Y, POS_DEFAULT_Z);
     IsPermitGenerate = true;
 }
Esempio n. 3
0
 private void Start()
 {
     if (GameObject.Find("CreditManager").GetComponent <CreditManager>())
     {
         creditManager = GameObject.Find("CreditManager").GetComponent <CreditManager>();
     }
 }
Esempio n. 4
0
    void Awake()
    {
        playerGameObject          = GameObject.FindGameObjectWithTag("Player");
        primaryWeaponGameObject   = GameObject.FindGameObjectWithTag("Primary Weapon");
        secondaryWeaponGameObject = GameObject.FindGameObjectWithTag("Secondary Weapon");

        lightningBoltGameObject = GameObject.FindGameObjectWithTag("Lightning");
        laserBeamGameObject     = GameObject.FindGameObjectWithTag("Laser Beam");

        displayManager = DisplayManager.Instance();
        creditManager  = CreditManager.Instance();

        myConfirmAction1 = new UnityAction(UpgradeLightningBolt);
        myConfirmAction2 = new UnityAction(UpgradeChainLightning);
        myConfirmAction3 = new UnityAction(UpgradeCyclonePrimaryWeapon);
        myConfirmAction4 = new UnityAction(UpgradeCycloneSpeed);
        myConfirmAction5 = new UnityAction(UpgradeShipWeapon);
        myConfirmAction6 = new UnityAction(UpgradeEnergyRegeneration);

        originalColor = nextUpgradeCostText.color;

        upgradeButtonCostText(1, maxUpgrade);

        //nextUpgradeCostText.text = upgradeCost.ToString();
    }
Esempio n. 5
0
    // Start is called before the first frame update
    void Start()
    {
        this.rewardedAd = new RewardedAd(adUnitId);        //インスタンス生成

        // Create an empty ad request.
        AdRequest request = new AdRequest.Builder().Build();

        // Load the rewarded ad with the request.
        this.rewardedAd.LoadAd(request);

        // Called when an ad request has successfully loaded.
        this.rewardedAd.OnAdLoaded += HandleRewardedAdLoaded;
        // Called when an ad request failed to load.
        this.rewardedAd.OnAdFailedToLoad += HandleRewardedAdFailedToLoad;
        // Called when an ad is shown.
        this.rewardedAd.OnAdOpening += HandleRewardedAdOpening;
        // Called when an ad request failed to show.
        this.rewardedAd.OnAdFailedToShow += HandleRewardedAdFailedToShow;
        // Called when the user should be rewarded for interacting with the ad.
        this.rewardedAd.OnUserEarnedReward += HandleUserEarnedReward;
        // Called when the ad is closed.
        this.rewardedAd.OnAdClosed += HandleRewardedAdClosed;

        CreditManagerInsatance = GameObject.Find("EnterCoinGate").GetComponent <CreditManager>();
        UIControllerInstance   = GameObject.Find("Main Camera").GetComponent <UIController>();
    }
Esempio n. 6
0
 public void toApply(CreditManager cm, List <LoggerService> loggerServices)
 {
     cm.Calculate();
     foreach (var log in loggerServices)
     {
         log.Log();
     }
 }
 public PaymentForm(decimal amount = 0, int orderId = 0)
 {
     _amount  = amount;
     _orderId = orderId;
     InitializeComponent();
     _creditManager = CreditManager.CreateAsSingleton(PathHelper.CreditPathModel);
     _cashManager   = CashManager.CreateAsSingleton(PathHelper.CashPathModel);
     _checkManager  = CheckManager.CreateAsSingleton(PathHelper.CheckPathModel);
 }
Esempio n. 8
0
    // Start is called before the first frame update
    void Start()
    {
        initPayout();

        CreditManagerInstance       = GameObject.Find("Main Camera").GetComponent <CreditManager>();
        BingoMasuControllerInstance = GameObject.Find("BingoMasu").GetComponent <BingoMasuController>();
        StopperManagerInstance      = GameObject.Find("Stopper").GetComponent <StopperManager>();
        StockSensorManagerInstance  = GameObject.Find("StockSensor").GetComponent <StockSensorManager>();
    }
 public override int Calculate()
 {
     if (_creditManager == null)
     {
         _creditManager = new CreditManager();
         _cachedValue   = _creditManager.Calculate();
     }
     return(_cachedValue);
 }
Esempio n. 10
0
        // GET api/credit
        // Retrieve
        public IHttpActionResult Get()
        {
            apiResp = new ApiResponse();
            var mng = new CreditManager();

            apiResp.Data = mng.RetrieveAll();

            return(Ok(apiResp));
        }
Esempio n. 11
0
 /* On Awake, ensure that there is only 1 instance of this class
  * running. This will ensure that all things related to managin
  * the player's credits will run smoothly */
 private void Awake()
 {
     if (CreditInstance == null)
     {
         CreditInstance = this;
     }
     else
     {
         Destroy(this);
     }
 }
Esempio n. 12
0
        // Retrieve all
        public IHttpActionResult Get()
        {
            var           mng        = new CreditManager();
            List <Credit> creditList = mng.RetrieveAll();

            if (creditList == null)
            {
                return(Content(HttpStatusCode.NotFound, "Not found"));
            }
            return(Ok(creditList));
        }
Esempio n. 13
0
 private void Start()
 {
     tutHelpBool                  = true; // To help make the tutorial speech bubble for upgrades come up only once in the level
     creditManager                = CreditManager.Instance();
     cycloneLabelTime             = Time.time + 12f;
     shipHealthAndShieldLabelTime = cycloneLabelTime + 8f;
     tutHelpBool                  = true; // To help make the tutorial speech bubble for upgrades come up only once in the level
     cycloneActive                = true;
     upgradeAndCreditActive       = true;
     shipHealthAndShieldActive    = true;
 }
Esempio n. 14
0
 public static CreditManager Instance()
 {
     if (!creditManager)
     {
         creditManager = FindObjectOfType(typeof(CreditManager)) as CreditManager;
         if (!creditManager)
         {
             Debug.LogError("There needs to be one active CreditManager script on a GameObject in your scene.");
         }
     }
     return(creditManager);
 }
Esempio n. 15
0
        public IHttpActionResult Get(Credit credit)
        {
            var mng = new CreditManager();

            List <Credit> accounList = mng.RetrieveById(credit);

            if (accounList == null)
            {
                return(Content(HttpStatusCode.NotFound, "Not found"));
            }
            return(Ok(accounList));
        }
Esempio n. 16
0
 public IHttpActionResult Post(Credit credit)
 {
     try
     {
         var mng = new CreditManager();
         mng.Create(credit);
         return(Content(HttpStatusCode.OK, "CREDITO REGISTRADO"));
     }
     catch (Exception e)
     {
         Console.WriteLine(e.Message);
         return(Content(HttpStatusCode.BadRequest, "ERROR AL REGISTRAR"));
     }
 }
Esempio n. 17
0
 // DELETE ==
 public IHttpActionResult Delete(Credit credit)
 {
     try
     {
         var mng = new CreditManager();
         mng.Delete(credit);
         return(Content(HttpStatusCode.OK, "CREDITO ACTUALIZADO"));
     }
     catch (Exception e)
     {
         Console.WriteLine(e.Message);
         return(Content(HttpStatusCode.BadRequest, "ERROR AL ELIMINAR"));
     }
 }
Esempio n. 18
0
 public Game1()
 {
     graphics              = new GraphicsDeviceManager(this);
     displayManager        = new DisplayManager();
     spaceManager          = new SpaceManager();
     sunManager            = new SunManager();
     orbitManager          = new OrbitManager();
     planetManager         = new PlanetManager();
     asteroidManager       = new AsteroidManager();
     scoreManager          = new ScoreManager();
     audioManager          = new AudioManager();
     menuManager           = new MenuManager();
     creditManager         = new CreditManager();
     Content.RootDirectory = "Content";
 }
Esempio n. 19
0
        /// <summary>
        /// Initialize any systems or engines in the frontend that the save data requires to exist before it loads. for example, any achievements declared in the frontend (so, all of them)
        /// must be added to the achievement manager, or else they won't point to anything when the data is loaded and therefore be lost or ignored.
        /// </summary>
        public static void PreSaveInit()
        {
            BackendInitializer.PreSaveInit(() => new StandardDisplay(), DisplayManager.GetCurrentDisplay, DisplayManager.LoadDisplay, AreaManager.placeCollection, AreaManager.locationCollection,
                                           AreaManager.dungeonCollection, AreaManager.homeBaseCollection, DifficultyManager.difficultyCollection, DifficultyManager.defaultDifficultyIndex,
                                           PerkManager.conditionalPerks);

            GameplaySettingsManager.IncludeGameplaySetting(new HyperHappySettings());

            CreditManager.AddCreditCategory(new FrontendCredits());
            CreditManager.AddCreditCategory(new FrontendModCredits());

            AchievementManager.RegisterAchievement(new Achievements.StartTheGameINeedAnAchievementForDebugging());

#warning Parse global File Data accordingly. note it may be null if file does not exist.
        }
Esempio n. 20
0
    /*==============================================================================*/
    /* 初期化処理																		*/
    /*==============================================================================*/
    void Start()
    {
        generateStructInstance();
        initRequest();
        initBingoMasuInfo();
        for (int masu = 0; masu < BINGO_MASU_MAX; masu++)
        {
            updateBingoMasuObjectDisplayState(masu);            //DisplayStateの初期化をGameObjectのsetActiveにも反映させる
        }
        initBingoTable();
        initNotifyStock();

        PayoutManagerInstance = GameObject.Find("Main Camera").GetComponent <PayoutManager>();
        CreditManagerInstance = GameObject.Find("Main Camera").GetComponent <CreditManager>();
        BallGeneratorInstance = GameObject.Find("BallEntrance").GetComponent <BallGenerator>();
    }
Esempio n. 21
0
    // Start is called before the first frame update
    void Start()
    {
        CreditValueText = GameObject.Find("CreditValueText").GetComponent <Text>();
        PayoutValueText = GameObject.Find("PayoutValueText").GetComponent <Text>();
        GameOverCanvas  = GameObject.Find("GameOverCanvas");
        ContinueButton  = GameObject.Find("ContinueButton");
        Banner1         = GameObject.Find("Banner1");

        CreditManagerInstance      = GameObject.Find("Main Camera").GetComponent <CreditManager>();
        PayoutManagerInstance      = GameObject.Find("Main Camera").GetComponent <PayoutManager>();
        AdBannerControllerInstance = GameObject.Find("Banner1").GetComponent <AdBannerController>();

        CreditManagerInstance.InitCreditText();
        PayoutManagerInstance.InitPayoutText();

        InactivateGameOverCanvas();        //最初は非表示
    }
Esempio n. 22
0
        // DELETE ==
        public IHttpActionResult Delete(Credit credit)
        {
            try
            {
                var mng = new CreditManager();
                mng.Delete(credit);

                apiResp         = new ApiResponse();
                apiResp.Message = "Action was executed.";

                return(Ok(apiResp));
            }
            catch (BussinessException bex)
            {
                return(InternalServerError(new Exception(bex.ExceptionId + "-" + bex.AppMessage.Message)));
            }
        }
Esempio n. 23
0
        static void Main(string[] args)
        {
            int sayi1 = 10;
            int sayi2 = 20;

            sayi1 = sayi2;
            sayi2 = 100;
            Console.WriteLine(sayi1);

            int[] sayilar  = new[] { 1, 2, 3 };
            int[] sayilar2 = new[] { 10, 22, 33 };
            sayilar = sayilar2;

            sayilar2[0] = 100;

            Console.WriteLine(sayilar[1]);


            CreditManager creditManager = new CreditManager();
            Customer      customer      = new Customer();

            CustomerManager customerManager = new CustomerManager(customer); //örnek olusturma instance alma


            Compony compony = new Compony();

            compony.Id = 100;
            Person person = new Person();

            customer.Id             = 1;
            customer.FirstName      = "Kubilay";
            customer.LastName       = "Yazı";
            person.NationalIdentity = "11111111111";

            CustomerManager customerManager2 = new CustomerManager(new Compony());

            customerManager.Save();

            creditManager.Calculate();

            customerManager.Save();
            customerManager.Delete();
            Console.ReadKey();
        }
Esempio n. 24
0
        // GET api/credit/5
        // Retrieve by id
        public IHttpActionResult Get(int id)
        {
            try
            {
                var mng    = new CreditManager();
                var credit = new Credit
                {
                    Id = id
                };

                credit       = mng.RetrieveById(credit);
                apiResp      = new ApiResponse();
                apiResp.Data = credit;
                return(Ok(apiResp));
            }
            catch (BussinessException bex)
            {
                return(InternalServerError(new Exception(bex.ExceptionId + "-" + bex.AppMessage.Message)));
            }
        }
Esempio n. 25
0
 // Start is called before the first frame update
 void Start()
 {
     CreditManagerInsatance = GameObject.Find("EnterCoinGate").GetComponent <CreditManager>();
     SoundManagerInstance   = GameObject.Find("AudioPlayer").GetComponent <SoundManager>();
 }
 //Dependency Injection
 //Method Injection
 public void Apply(CreditManager creditManager, ILoggerService loggerService)
 {
     creditManager.Calculate();
     loggerService.Log();
 }
Esempio n. 27
0
 public FacadeCustomer()
 {
     _eftManager    = new EFTManager();
     _creditManager = new CreditManager();
 }
Esempio n. 28
0
    public int addCreditValue; // Set in the Inspector

    protected override void OnClick()
    {
        base.OnClick();
        CreditManager.AddCredits(addCreditValue);
    }
Esempio n. 29
0
 void Awake()
 {
     creditManager   = CreditManager.Instance();
     timeTillDestroy = Time.time + timeTillDestroy;
 }
Esempio n. 30
0
        /// <summary>
        /// Initialize any managers specific to the GUI layer that GUI save data may depend on in order to run correctly. For example, the language engine must exist, otherwise
        /// the game cannot properly deserialize the previously selected language.
        /// </summary>
        public static void PreSaveInit()
        {
            FrontendInitalizer.PreSaveInit();

            CreditManager.AddCreditCategory(new GUICredits());
        }