Пример #1
0
 void OnTalentOpened(CarInsanityProductInfo car)
 {
     Debug.Log("NGUITalentLock.OnTalentOpened");
     if(lockIcon.enabled) {
         lockIcon.enabled = false;
     }
 }
Пример #2
0
    void OnTalentInfoOpened(CarInsanityProductInfo car)
    {
        currentCar = car;
        //		Debug.Log("NGUITalentOpenSummit.OnTalentInfoOpened.isTalentOpened:"+currentCar.isTalentOpened.ToString());

        if(!currentCar.purchased) {
            talentOpenSummitButton.SetActiveRecursively(true);
            talentOpenSummitButtonBoxCollider.enabled = false;
        }else{
            if(currentCar.isTalentOpened) {
                talentOpenSummitButton.SetActiveRecursively(false);
            }else{

                talentOpenSummitButton.SetActiveRecursively(true);
                talentOpenSummitButtonBoxCollider.enabled = true;
            }
        }
    }
Пример #3
0
    void OnProductViewChanged(CarInsanityProductInfo car)
    {
        //		Debug.Log ("NGUIGoldBuy.OnProductViewChanged:"+car.purchased.ToString());

        currentCar = car;

        if(!car.purchased) {

            animation[animationName].time = animationTime;
            animation[animationName].speed = 1.0f;
            animation.Play();
            animationTime = animation[animationName].length;

        }else{
            animation[animationName].time = animationTime;
            animation[animationName].speed = -1.0f;
            animation.Play();
            animationTime = 0.0f;

        }
    }
Пример #4
0
    void OnProductViewChanged(CarInsanityProductInfo car)
    {
        if(!isProductLoadedFromStore) {
            return;
        }

        if(!car.purchased) {

            animation[animationName].time = animationTime;
            animation[animationName].speed = 1.0f;
            animation.Play();
            animationTime = animation[animationName].length;

        }else{
            animation[animationName].time = animationTime;
            animation[animationName].speed = -1.0f;
            animation.Play();
            animationTime = 0.0f;

        }
    }
Пример #5
0
 void OnTalentInfoOpened(CarInsanityProductInfo car)
 {
     //		Debug.Log ("NGUITalentInfoIcon.OnProductViewChanged:"+((IconName)car.ID).ToString());
     icon.spriteName = ((IconName)car.ID).ToString();
     icon.MakePixelPerfect();
 }
Пример #6
0
 void OnTalentOpened(CarInsanityProductInfo car)
 {
     OKMessageSprite.spriteName = "purchasedSuccess";
     OKMessageSprite.MakePixelPerfect();
     okMessageBoard.SetActiveRecursively(true);
 }
Пример #7
0
 void OnTalentInfoOpened(CarInsanityProductInfo car)
 {
     currentCar = car;
     //		Debug.Log ("NGUITalentPrice.OnProductViewChanged:"+car.talentPrice.ToString());
     talentPriceLabel.text = car.talentPrice;
 }
Пример #8
0
    void OnProductViewChanged(CarInsanityProductInfo car)
    {
        //		Debug.Log ("NGUITalentLock.OnProductViewChanged-isTalentOpened:"+car.isTalentOpened.ToString());

        lockIcon.enabled = !car.isTalentOpened;
    }
Пример #9
0
    public void ReceiveByClientPortal_LoadProductList(int gupid, string productList, int p)
    {
        Definition.RPCProcessState resultState = (Definition.RPCProcessState)p;

        if(resultState == Definition.RPCProcessState.SUCCESS) {

            string[] productListArray = productList.Split(',');
            allCarInsanityProductInfo.Clear();

            foreach(string productInfo in productListArray) {

                if(productInfo != ""){
                    string[] productInfoArray = productInfo.Split(':');

                    CarInsanityProductInfo product = new CarInsanityProductInfo();
                    product.ID = System.Convert.ToInt32(productInfoArray[0]); //ID
                    product.productID = productInfoArray[1]; //productID
                    product.name = productInfoArray[2]; //name
                    product.talentPrice = productInfoArray[3];
                    product.goldPrice = productInfoArray[4];
                    product.purchased = System.Convert.ToBoolean(productInfoArray[5]); //purchased
                    product.isTalentOpened = System.Convert.ToBoolean(productInfoArray[6]); //isTalentOpened

                    allCarInsanityProductInfo.Add(product);
        //					Debug.Log("ID:"+product.ID+", productID:" +product.productID+ ", name:"+product.name+", TPrice:"+product.talentPrice+", GPrice:"+product.goldPrice+", purchased:"+product.purchased.ToString()+", talentOpen:"+product.isTalentOpened.ToString());
                }
            }

            if(OnProductLoadedFromLobby != null) {
                OnProductLoadedFromLobby();
            }

            GetProductData();

        }else if(resultState == Definition.RPCProcessState.UNAVAILABLE){
        //			Debug.Log("UNAVAILABLE");
        }else if(resultState == Definition.RPCProcessState.PLAYERNOTEXIST){
        //			Debug.Log("USERNOTEXIST");
        }else{
        //			Debug.Log(p);
        }
    }
Пример #10
0
 void OnProductViewChanged(CarInsanityProductInfo car)
 {
     alreadyPurchased.enabled = car.purchased;
 }
Пример #11
0
 void OnCarPurchased(CarInsanityProductInfo car)
 {
     alreadyPurchased.enabled = car.purchased;
 }
Пример #12
0
 void OnTalentInfoOpened(CarInsanityProductInfo car)
 {
     icon.enabled = !car.purchased;
 }
Пример #13
0
 void OnProductViewChanged(CarInsanityProductInfo car)
 {
     //		Debug.Log ("NGUICarGold.OnProductViewChanged:"+car.goldPrice.ToString());
     goldLabel.text = car.goldPrice;
 }
Пример #14
0
 void OnCarPurchased(CarInsanityProductInfo car)
 {
     animation[animationName].time = animation[animationName].length;
     animation[animationName].speed = -1.0f;
     animation.Play();
 }
Пример #15
0
 void OnTalentOpened(CarInsanityProductInfo car)
 {
     talentOpenSummitButton.SetActiveRecursively(false);
 }
Пример #16
0
 void OnCarPurchased(CarInsanityProductInfo car)
 {
     talentOpenSummitButtonBoxCollider.enabled = true;
 }