Exemplo n.º 1
0
 void OnTalentOpened(CarInsanityProductInfo car)
 {
     Debug.Log("NGUITalentLock.OnTalentOpened");
     if(lockIcon.enabled) {
         lockIcon.enabled = false;
     }
 }
Exemplo n.º 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;
            }
        }
    }
Exemplo n.º 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;

        }
    }
Exemplo n.º 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;

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

        lockIcon.enabled = !car.isTalentOpened;
    }
Exemplo n.º 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);
        }
    }
Exemplo n.º 10
0
 void OnProductViewChanged(CarInsanityProductInfo car)
 {
     alreadyPurchased.enabled = car.purchased;
 }
Exemplo n.º 11
0
 void OnCarPurchased(CarInsanityProductInfo car)
 {
     alreadyPurchased.enabled = car.purchased;
 }
Exemplo n.º 12
0
 void OnTalentInfoOpened(CarInsanityProductInfo car)
 {
     icon.enabled = !car.purchased;
 }
Exemplo n.º 13
0
 void OnProductViewChanged(CarInsanityProductInfo car)
 {
     //		Debug.Log ("NGUICarGold.OnProductViewChanged:"+car.goldPrice.ToString());
     goldLabel.text = car.goldPrice;
 }
Exemplo n.º 14
0
 void OnCarPurchased(CarInsanityProductInfo car)
 {
     animation[animationName].time = animation[animationName].length;
     animation[animationName].speed = -1.0f;
     animation.Play();
 }
Exemplo n.º 15
0
 void OnTalentOpened(CarInsanityProductInfo car)
 {
     talentOpenSummitButton.SetActiveRecursively(false);
 }
Exemplo n.º 16
0
 void OnCarPurchased(CarInsanityProductInfo car)
 {
     talentOpenSummitButtonBoxCollider.enabled = true;
 }