Buy new pets

Results 1 to 16 of 16
  1. #1
    Member xLiionel is offline
    MemberRank
    Sep 2010 Join Date
    36Posts

    thumbs up Buy new pets

    Well today I come to bring
    To purchase the pet to 100%
    Search in Messages/Request/Catalog.cs
    Code:
    private void CheckPetName()
            {
                Session.GetMessageHandler().GetResponse().Init(36);
                Session.GetMessageHandler().GetResponse().AppendInt32(UberEnvironment.GetGame().GetCatalog().CheckPetName(Request.PopFixedString()) ? 0 : 2);
                Session.GetMessageHandler().SendResponse();
            }
    Placed under
    Code:
    private void PetRaces()
            {
                /*
                 * Créditos a LittleJ
                 * Credits to Littlej
                 */
                string Type = Request.PopFixedString();
                Dictionary<int, string> Races = new Dictionary<int, string>();
                int Race = Convert.ToInt32(Type.Substring(6));
                //Console.WriteLine(Race);
                #region Races Info
                Races.Add(0, "QFHHIHHIIHHJIHHKIHHPAIHHQAIHHRAIHHSAIHHPBIHHQBIHHRBIHHSBIHHPCIHHQCIHHRCIHHSCIHHPDIHHQDIHHRDIHHSDIHHPEIHHQEIHHREIHHSEIHHPFIH");
                Races.Add(1, "QFIHIHIIIHIJIHIKIHIPAIHIQAIHIRAIHISAIHIPBIHIQBIHIRBIHISBIHIPCIHIQCIHIRCIHISCIHIPDIHIQDIHIRDIHISDIHIPEIHIQEIHIREIHISEIHIPFIH");
                Races.Add(2, "PCJHIHJIIHJJIHJKIHJPAIHJQAIHJRAIHJSAIHJPBIHJQBIHJRBIHJSBIH");
                Races.Add(3, "SAKHIHKIIHKJIHKKIHKPAIHKQAIHKRAIH");
                Races.Add(4, "PAPAHIHPAIIHPAJIHPAKIH");
                Races.Add(5, "SAQAHIHQAIIHQAJIHQAKIHQAQAIHQASAIHQAPBIH");
                Races.Add(6, "QCRAHIHRAIIHRAJIHRAKIHRAPAIHRAQAIHRARAHIRASAHIRAPBHIRAQBHIRARBHIRASBIHRAPCHI");
                Races.Add(7, "PBSAHIHSAIIHSAJIHSAKHISAPAIHSAQAIHSARAIHSASAIH");
                Races.Add(8, "QCPBHIHPBIIHPBJIHPBKIHPBPAIHPBQAIHPBRAIHPBSAIHPBPBIHPBQBIHPBRBIHPBSBIHPBRCIH");
                Races.Add(10, "IRBHIHIZMUPEHHI");
                Races.Add(11, "RCSBIIHSBJIHSBKIHSBPAIHSBQAIHSBRAIHSBPBHHSBQBIHSBRBIHSBSBIHSBPCIHSBQCIHSBSCIHSBRDIH");
               
                #endregion
    
                if (!Races.ContainsKey(Race))
                {
                    Session.SendNotif(Race + " Esta raza no está disponible");
                    Races.Clear();
                    return;
                }
    
                GetResponse().Init(827);
                GetResponse().AppendStringWithBreak(Type);
                GetResponse().AppendStringWithBreak(Races[Race]);
                SendResponse();
    
                Races.Clear();
            }
    Now Search
    Code:
    RequestHandlers[42] = new RequestHandler(CheckPetName);
    Placed Under
    Code:
    RequestHandlers[3007] = new RequestHandler(PetRaces);
    This is an alternative to code Vista4Life
    Search in Catalogs/Catalog.cs
    Code:
    case "5354":
                                            PetType = 7; // Rinoceronte
                                            break;
    Placed Under
    Code:
     case "6000":
                                            PetType = 8; // araña
                                            break;
    
                                        case "6001":
                                            PetType = 11;  // rana
                                            break;
    
                                        case "6002":
                                            PetType = 10;
                                            break;
    Otherwise it's your turn



    Credits to:
    LittleJ
    Me

    PD: I'm BobMarley of kekomundo.
    Sorry for my bad english I'm Mexican
    Last edited by xLiionel; 03-05-11 at 01:14 PM.


  2. #2
    I'm back! iJay is offline
    Grand MasterRank
    Nov 2008 Join Date
    Down Under ;)Location
    602Posts

    Re: Buy new pets

    Cheers for this release dude, would you be able to post the WHOLE code for all pets, seeing as I've just gotten back into dev and I don't have any of the codes anymore, cheers matey :)

    Just PM if you don't want to post on here..

  3. #3
    Elite Member cuperus is offline
    Member +Rank
    Aug 2009 Join Date
    108Posts

    Re: Buy new pets

    EN:
    Please i beg you, make/copy the sql codes and pm them to me or place them over here! PLEAS do this and this is 100% the best topic on rz!:$

    SP:
    Por favor, te ruego, hacer / copiar el código SQL y horas que me o ponerlos aquí! PRIMERA INSTANCIA hacer esto y esto es 100% el mejor tema en rz: $

  4. #4
    I'm back! iJay is offline
    Grand MasterRank
    Nov 2008 Join Date
    Down Under ;)Location
    602Posts

    Re: Buy new pets

    Copy of my pet code

    PHP Code:
                                case "pet":

                                    
    string[] PetData ExtraData.Split('\n');
                                    
    int PetType 0;

                                    switch (
    PetData[3])
                                    {
                                        
    // Valid ItemID's
                                        
    case "2349":
                                            
    PetType 5// Pig
                                            
    break;

                                        case 
    "2430":
                                            
    PetType 3// Terrier
                                            
    break;

                                        case 
    "2431":
                                            
    PetType 4// Bear
                                            
    break;

                                        case 
    "2432":
                                            
    PetType 1// Cat
                                            
    break;

                                        case 
    "2433":
                                            
    PetType 0// Dog
                                            
    break;

                                        case 
    "2434":
                                            
    PetType 2// Crocodile
                                            
    break;

                                        case 
    "7457":
                                            
    PetType 6// Lion 
                                            
    break;


                                        case 
    "5354":
                                            
    PetType 7// Rino
                                            
    break;

                                        case 
    "6000":
                                            
    PetType 8// araña
                                            
    break;

                                        case 
    "6001":
                                            
    PetType 11;  // rana
                                            
    break;

                                        case 
    "6002":
                                            
    PetType 10;
                                            break;

                                        default:
                                            
    PetType 9// Error
                                            
    Session.SendNotif("Something went wrong! The item type could not be processed. Please do not try to buy this item anymore, instead inform support as soon as possible.");
                                            break;
                                    }

                                    if (
    PetType != 8)
                                    {
                                        
    Pet GeneratedPet CreatePet(Session.GetHabbo().IdPetData[0], PetTypePetData[1], PetData[2]);

                                        
    Session.GetHabbo().GetInventoryComponent().AddPet(GeneratedPet); // now what? LOL
                                        
    Session.GetHabbo().GetInventoryComponent().AddItem(GeneratedId320"0"true);
                                    }
                                    else
                                    {
                                        
    UberEnvironment.GetLogging().WriteLine("Pet Error: " "Someone just tried to buy ItemID: " PetData[3] + " which is not a valid pet. (Catalog.cs)"Core.LogLevel.Error);
                                    }
                                    break; 

  5. #5
    Sorcerer Supreme GuikBretas is offline
    Member +Rank
    Apr 2009 Join Date
    NorwayLocation
    332Posts

    Re: Buy new pets

    When i put transforms on a croc ;X how to resolve?

  6. #6
    Brad Bradshly is offline
    Grand MasterRank
    Aug 2007 Join Date
    Ragezone :DLocation
    611Posts

    Re: Buy new pets

    I cant get this to work myself if i figure i will help! :)

  7. #7
    Member xLiionel is offline
    MemberRank
    Sep 2010 Join Date
    36Posts

    thumbs up Re: Buy new pets

    Sure glad to here this

    Code:
    INSERT INTO `catalog_pages` (`id`, `parent_id`, `caption`, `icon_image`, `order_num`, `page_layout`, `page_headline`, `page_text1`, `page_text_details`) VALUES ('169', '14', 'Spider', '95', '0', 'pets', 'catalog_pet_headline1', 'One of the most feared creatures in nature, and perhaps the most misunderstood. The majority of Spiders are predators with sharp fangs that inject venom into their prey- but dont worry, these spiders wont bite you! Maybe...', 'Name your pet:');
    INSERT INTO `catalog_items` (`id`, `page_id`, `item_ids`, `catalog_name`, `cost_credits`, `cost_pixels`, `amount`) VALUES ('6000', '169', '20600', 'a0 pet8', '20', '0', '1');
    INSERT INTO `furniture` (`id`, `public_name`, `item_name`, `sprite_id`, `allow_recycle`, `allow_trade`, `allow_marketplace_sell`, `allow_gift`, `allow_inventory_stack`, `interaction_type`, `interaction_modes_count`) VALUES ('20600', 'Spiders', 'a0 pet8', '3817', '0', '0', '0', '0', '0', 'pet', '0');
    
    INSERT INTO `catalog_pages` (`id`, `parent_id`, `caption`, `icon_image`, `order_num`, `page_layout`, `page_headline`, `page_text1`, `page_text_details`) VALUES ('170', '14', 'Frog', '97', '0', 'pets', 'catalog_pet_headline1', 'The Frog. Cute, green and slimy! Frogs come in a variety of weird colours and can be found all over the world. Frogs are great jumpers, and make great pets, but are harder to hold onto than a supermodel in a tornado', 'Name your frog:');
    INSERT INTO `catalog_items` (`id`, `page_id`, `item_ids`, `catalog_name`, `cost_credits`, `amount`) VALUES ('6001', '170', '20601', 'a0 pet11', '20', '1');
    INSERT INTO `furniture` (`id`, `public_name`, `item_name`, `sprite_id`, `allow_recycle`, `allow_trade`, `allow_marketplace_sell`, `allow_gift`, `allow_inventory_stack`, `interaction_type`, `interaction_modes_count`) VALUES ('20601', 'Frogs', 'a0 pet11', '1532', '0', '0', '0', '0', '0', 'pet', '0');
    
    INSERT INTO `catalog_pages` (`id`, `parent_id`, `caption`, `icon_image`, `order_num`, `page_layout`, `page_headline`, `page_text1`, `page_text_details`) VALUES ('171', '14', 'Chick', '107', '0', 'pets', 'catalog_pet_headline1', 'Habboon is full of chicks (the pet kind!) Adopt your new born chicklet now and start training it to perform the Chicken Dance for your friends... it will be a show to remember!', 'Name your chick:');
    INSERT INTO `catalog_items` (`id`, `page_id`, `item_ids`, `catalog_name`, `cost_credits`, `amount`) VALUES ('6002', '171', '20602', 'a0 pet10', '20', '1');
    INSERT INTO `furniture` (`id`, `public_name`, `item_name`, `sprite_id`, `allow_recycle`, `allow_trade`, `allow_marketplace_sell`, `allow_gift`, `allow_inventory_stack`, `interaction_type`, `interaction_modes_count`) VALUES ('20602', 'Chicks', 'a0 pet10', '1532', '0', '0', '0', '0', '0', 'pet', '0');

  8. #8
    Member EliteRoyal is offline
    MemberRank
    Mar 2011 Join Date
    Santo Domingo,Location
    55Posts

    Re: Buy new pets

    i have a problem i cant see it on my inventory, i am spanish to but you can put it to me 100% in teamviwer and add me on msn please!!!

  9. #9
    Sorcerer Supreme GuikBretas is offline
    Member +Rank
    Apr 2009 Join Date
    NorwayLocation
    332Posts

    Re: Buy new pets

    Quote Originally Posted by EliteRoyal View Post
    i have a problem i cant see it on my inventory, i am spanish to but you can put it to me 100% in teamviwer and add me on msn please!!!
    i have the same problem, i cant see on inventory, but i can see on catalog
    any pets don't work ;(
    Last edited by GuikBretas; 03-05-11 at 09:53 PM.

  10. #10
    Member xLiionel is offline
    MemberRank
    Sep 2010 Join Date
    36Posts

    Re: Buy new pets

    This code does not fit unless you fix blah pets in the

  11. #11
    Member EliteRoyal is offline
    MemberRank
    Mar 2011 Join Date
    Santo Domingo,Location
    55Posts

    Re: Buy new pets

    Quote Originally Posted by xLiionel View Post
    This code does not fit unless you fix blah pets in the
    i have uberemulator not blah emulator!!!

  12. #12
    Elite Member ITouchI is offline
    Member +Rank
    Feb 2011 Join Date
    229Posts

    Re: Buy new pets

    Can u gve me link 2 ur emulator

  13. #13
    Member EliteRoyal is offline
    MemberRank
    Mar 2011 Join Date
    Santo Domingo,Location
    55Posts

    Re: Buy new pets

    he emulator is Think Emulator but i see he coded pets!!!

  14. #14
    I'm back! iJay is offline
    Grand MasterRank
    Nov 2008 Join Date
    Down Under ;)Location
    602Posts

    Re: Buy new pets

    Anyone got the code you need for buying the actual pets?

    I've got everything in the catalog working, but I can't get the buying part working, When I click buy nothing happens, and it does not create the pet in user_pets so therefor obviously does not show up in my inventory.. ??

  15. #15
    Elite Member cuperus is offline
    Member +Rank
    Aug 2009 Join Date
    108Posts

    Re: Buy new pets

    pleas i need al SWFS PLEAS:$ Thats everything what i want

    ---------- Post added at 09:45 AM ---------- Previous post was at 09:41 AM ----------

    Pleas can somebody help me witht teamviewer if i press on my pet (chicken) then i see an dog

  16. #16
    Elite Member TenShie is offline
    Member +Rank
    Apr 2011 Join Date
    Frankfurt a. M.Location
    115Posts

    information Re: Buy new pets

    Quote Originally Posted by cuperus View Post
    pleas i need al SWFS PLEAS:$ Thats everything what i want

    ---------- Post added at 09:45 AM ---------- Previous post was at 09:41 AM ----------

    Pleas can somebody help me witht teamviewer if i press on my pet (chicken) then i see an dog
    >.>

    DCR-Project


    -TenShie



Advertisement