Ejemplo n.º 1
0
    // Use this for initialization
    void Start()
    {
        StoreController.Initialize(new MuffinRushAssets());
        handler = new ExampleEventHandler();

        // Initialization of 'ExampleLocalStoreInfo' and some example usages in ExampleEventHandler.onStoreControllerInitialized
    }
Ejemplo n.º 2
0
    // Use this for initialization
    void Start()
    {
        StoreController.Initialize(new MuffinRushAssets());
        handler = new ExampleEventHandler();
        ExampleLocalStoreInfo.Init();

        // some examples
        try {
            Debug.Log("start currency: " + StoreInventory.GetItemBalance("currency_muffin"));
            StoreInventory.TakeItem("currency_muffin", 50);
            Debug.Log("middle currency: " + StoreInventory.GetItemBalance("currency_muffin"));
            StoreInventory.GiveItem("currency_muffin", 4000);
            Debug.Log("end currency:" + StoreInventory.GetItemBalance("currency_muffin"));
        } catch (VirtualItemNotFoundException ex) {
            Debug.Log(ex.Message);
        }
    }
Ejemplo n.º 3
0
    // Use this for initialization
    void Start()
    {
        StoreController.Initialize(new MuffinRushAssets());
        handler = new ExampleEventHandler();
        ExampleLocalStoreInfo.Init();

        // some examples
        Debug.Log("start currency: " + StoreInventory.GetCurrencyBalance("currency_muffin"));
        Debug.Log("remove currency: " + StoreInventory.RemoveCurrencyAmount("currency_muffin",50));
        Debug.Log("middle currency: " + StoreInventory.GetCurrencyBalance("currency_muffin"));
        Debug.Log("add currency: " + StoreInventory.AddCurrencyAmount("currency_muffin",4000));
        Debug.Log("end currency:" + StoreInventory.GetCurrencyBalance("currency_muffin"));
    }
Ejemplo n.º 4
0
    // Use this for initialization
    void Start()
    {
        handler = new ExampleEventHandler();

        StoreController.Initialize(new MuffinRushAssets());

        // Initialization of 'ExampleLocalStoreInfo' and some example usages in ExampleEventHandler.onStoreControllerInitialized
    }
Ejemplo n.º 5
0
    // Use this for initialization
    void Start()
    {
        StoreController.Initialize(new MuffinRushAssets());
        handler = new ExampleEventHandler();
        ExampleLocalStoreInfo.Init();

        // some examples
        try {
        Debug.Log("start currency: " + StoreInventory.GetItemBalance("currency_muffin"));
        StoreInventory.TakeItem("currency_muffin",50);
        Debug.Log("middle currency: " + StoreInventory.GetItemBalance("currency_muffin"));
        StoreInventory.GiveItem("currency_muffin",4000);
        Debug.Log("end currency:" + StoreInventory.GetItemBalance("currency_muffin"));
        } catch (VirtualItemNotFoundException ex){
            Debug.Log (ex.Message);
        }
    }