new packets for serialize inventory..

Page 1 of 2 12 LastLast
Results 1 to 25 of 46
  1. #1
    are you ******* kidding!! capostrike93 is offline
    MemberRank
    Jan 2011 Join Date
    366Posts

    new packets for serialize inventory..

    new packets for serialize inventory..

    RELEASE63-31860-31851-201102281426_0591ca57de662cfc25987433ce0080be
    PHP Code:
    public void Serialize(ServerMessage Message)
            {
                
    Item Item GetBaseItem();
                if (
    Item == null) return;
                
    Message.AppendUInt32(Id);
                
    Message.AppendStringWithBreak(Item.Type.ToUpper());
                
    Message.AppendString("qpzZIB");
                
    Message.AppendInt32(Item.SpriteId);
                
    Message.AppendInt32(1);
                
    Message.AppendStringWithBreak(ExtraData);
                
    Message.AppendBoolean(Item.AllowRecycle);
                
    Message.AppendBoolean(Item.AllowTrade);
                
    Message.AppendBoolean(Item.AllowInventoryStack);
                
    Message.AppendBoolean(UberEnvironment.GetGame().GetCatalog().GetMarketplace().CanSellItem(this));
                
    Message.AppendInt32(-1);

                if (
    GetBaseItem().Type.ToLower() == "s")
                {
                    
    Message.AppendStringWithBreak("");
                    
    Message.AppendInt32(0);
                }
            } 
    qpzZIB is category item
    Last edited by capostrike93; 03-03-11 at 04:57 PM.


  2. #2

    Re: new packets for serialize inventory..

    Thanks!

  3. #3
    :joy: Jonteh is offline
    MemberRank
    Apr 2007 Join Date
    New York, USALocation
    3,372Posts

    Re: new packets for serialize inventory..

    Thanks.

  4. #4
    Valued Member vicancer is offline
    MemberRank
    Mar 2010 Join Date
    133Posts

    Re: new packets for serialize inventory..

    where is the code or line

  5. #5
    are you ******* kidding!! capostrike93 is offline
    MemberRank
    Jan 2011 Join Date
    366Posts

    Re: new packets for serialize inventory..

    Useritems.cs

  6. #6
    :joy: Jonteh is offline
    MemberRank
    Apr 2007 Join Date
    New York, USALocation
    3,372Posts

    Re: new packets for serialize inventory..

    Did you code this yourself or..?

  7. #7
    are you ******* kidding!! capostrike93 is offline
    MemberRank
    Jan 2011 Join Date
    366Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by Jontycat View Post
    Did you code this yourself or..?
    course -.-

  8. #8
    Valued Member vicancer is offline
    MemberRank
    Mar 2010 Join Date
    133Posts

    Re: new packets for serialize inventory..

    please help me,as is the code?

    Code:
     public void Serialize(ServerMessage Message, Boolean Inventory)
            {
                Message.AppendUInt(Id);
                Message.AppendInt32(0);
                if (GetBaseItem() == null)
                    Logging.LogException("Unknown base: " + BaseItem);
                Message.AppendStringWithBreak(GetBaseItem().Type.ToUpper());
                Message.AppendUInt(Id);
                Message.AppendInt32(GetBaseItem().SpriteId);
    
                if (GetBaseItem().Name.Contains("a2"))
                {
                    Message.AppendInt32(3);
                }
                else if (GetBaseItem().Name.Contains("wallpaper"))
                {
                    Message.AppendInt32(2);
                }
                else if (GetBaseItem().Name.Contains("landscape"))
                {
                    Message.AppendInt32(4);
                }
                else
                {
                    Message.AppendInt32(0);
                }
    
                Message.AppendStringWithBreak(ExtraData);
                Message.AppendBoolean(GetBaseItem().AllowRecycle);
                Message.AppendBoolean(GetBaseItem().AllowTrade);
                Message.AppendBoolean(GetBaseItem().AllowInventoryStack);
                Message.AppendBoolean(UberEnvironment.GetGame().GetCatalog().GetMarketplace().CanSellItem(this));
                Message.AppendInt32(-1);
    
                if (GetBaseItem().Type.ToLower() == "s")
                {
                    Message.AppendStringWithBreak("");
                    Message.AppendInt32(-1);
                }
            }

  9. #9
    are you ******* kidding!! capostrike93 is offline
    MemberRank
    Jan 2011 Join Date
    366Posts

    Re: new packets for serialize inventory..

    copy the code and replace -.-"
    ..


    almost forgot

    also ..
    Code:
            public ServerMessage SerializeItemInventory()
            {
                ServerMessage Message = new ServerMessage(140);
                Message.AppendStringWithBreak("S");
                Message.AppendInt32(1);
                Message.AppendInt32(1);
                Message.AppendInt32(ItemCount);
                List<UserItem> List;
                lock (InventoryItems)
                {
                    List = InventoryItems;
                }
                List<UserItem>.Enumerator eItems = List.GetEnumerator();
                while (eItems.MoveNext())
                {
                    eItems.Current.Serialize(Message);
                }
                return Message;
            }

  10. #10
    You can call me Monty :D GuikBretas is offline
    MemberRank
    Apr 2009 Join Date
    NorwayLocation
    332Posts

    Re: new packets for serialize inventory..

    Error:

    Error 14 The best overloaded method match for 'XD.Messages.ServerMessage.AppendInt32(int)' has some invalid arguments D:\Usar esse emulador\* r3\HabboHotel\Items\UserItem.cs 51 13 *

    Error 15 Argument 1: cannot convert from 'uint' to 'int' D:\Usar esse emulador\* r3\HabboHotel\Items\UserItem.cs 51 33 *

    Line:
    Message.AppendInt32(Id);

  11. #11
    Otaku Sojobo is offline
    MemberRank
    Nov 2006 Join Date
    ScotlandLocation
    1,279Posts

    Re: new packets for serialize inventory..

    You've done this wrong, jus' saying.

    For starters the inventory is now in 2 packets, BLS for flooritems and BLI for wallitems. You can use BLS to update wallitems like you have done, however if you don't have any flooritems then your wall items won't update properly.
    Also what's with the "qpzZIB", that looks like an item ID, that's not meant to be there.

  12. #12
    Apprentice YabMeernl is offline
    MemberRank
    Jan 2011 Join Date
    23Posts

    Re: new packets for serialize inventory..

    Thankyou.

  13. #13
    Retired maritnmine is offline
    MemberRank
    May 2007 Join Date
    North KoreaLocation
    1,103Posts

    Re: new packets for serialize inventory..

    Does not work. Would be nice if someone posted a code that works with the new inventory.

    - Martin
    Last edited by maritnmine; 03-03-11 at 01:21 PM.

  14. #14
    You can call me Monty :D GuikBretas is offline
    MemberRank
    Apr 2009 Join Date
    NorwayLocation
    332Posts

    Re: new packets for serialize inventory..

    when i click on inventory i receive D/C :(

  15. #15
    C# | C++ Emerica is offline
    MemberRank
    Oct 2010 Join Date
    GermanyLocation
    437Posts

    Re: new packets for serialize inventory..

    Yeah thanks, nice release

  16. #16
    Banned PEjump2 is offline
    BannedRank
    Jan 2010 Join Date
    The NetherlandsLocation
    2,838Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by maritnmine View Post
    Does not work. Would be nice if someone posted a code that works with the new inventory.

    - Martin
    I thought you where the L33T coder here? Can't you code a simple packet change yourself? :o

  17. #17
    Otaku Sojobo is offline
    MemberRank
    Nov 2006 Join Date
    ScotlandLocation
    1,279Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by Sojobo View Post
    You've done this wrong, jus' saying.

    For starters the inventory is now in 2 packets, BLS for flooritems and BLI for wallitems. You can use BLS to update wallitems like you have done, however if you don't have any flooritems then your wall items won't update properly.
    Also what's with the "qpzZIB", that looks like an item ID, that's not meant to be there.
    Quote Originally Posted by maritnmine View Post
    Does not work. Would be nice if someone posted a code that works with the new inventory.

    - Martin
    BLS.IIKu{LVECS.q{LVECXzNI.HIIHM.HtF]S~BS.pF]S~B[_MI.HHIHM.Hw_a]@BS.s_a]@BZ.EI.HHIHM.PA.
    BLI.IIIh]M_YI.h]M_YX_PQA16.HHHHM.

    You're welcome.

  18. #18
    You can call me Monty :D GuikBretas is offline
    MemberRank
    Apr 2009 Join Date
    NorwayLocation
    332Posts

    Re: new packets for serialize inventory..

    WOW! My inventory back to works on magic :O without code.

  19. #19
    are you ******* kidding!! capostrike93 is offline
    MemberRank
    Jan 2011 Join Date
    366Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by GuikBretas View Post
    Error:

    Error 14 The best overloaded method match for 'XD.Messages.ServerMessage.AppendInt32(int)' has some invalid arguments D:\Usar esse emulador\* r3\HabboHotel\Items\UserItem.cs 51 13 *

    Error 15 Argument 1: cannot convert from 'uint' to 'int' D:\Usar esse emulador\* r3\HabboHotel\Items\UserItem.cs 51 33 *

    Line:
    Message.AppendInt32(Id);


    sorry in my emulator not used unsigned ints, your use this Message.AppendUInt32(Id)

    now update the code..

  20. #20
    What about no. Davidaap is offline
    MemberRank
    Nov 2009 Join Date
    773Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by PEjump2 View Post
    I thought you where the L33T coder here? Can't you code a simple packet change yourself? :o
    I thought you were Banned, shame that you are back :(

  21. #21
    Retired maritnmine is offline
    MemberRank
    May 2007 Join Date
    North KoreaLocation
    1,103Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by PEjump2 View Post
    I thought you where the L33T coder here? Can't you code a simple packet change yourself? :o
    For your information, I never spesialized myself in packets. And what the heck is your problem?

    - Martin

  22. #22
    Banned PEjump2 is offline
    BannedRank
    Jan 2010 Join Date
    The NetherlandsLocation
    2,838Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by maritnmine View Post
    For your information, I never spesialized myself in packets. And what the heck is your problem?

    - Martin
    LOL, So you'r recoding uberEmu almost totally but you don't have any idea actually how the packets structure even works? ROFL.

  23. #23
    are you ******* kidding!! capostrike93 is offline
    MemberRank
    Jan 2011 Join Date
    366Posts

    Re: new packets for serialize inventory..

    Stop spamming in MY topic -.-

  24. #24
    Retired maritnmine is offline
    MemberRank
    May 2007 Join Date
    North KoreaLocation
    1,103Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by PEjump2 View Post
    LOL, So you'r recoding uberEmu almost totally but you don't have any idea actually how the packets structure even works? ROFL.
    Yeah, I get help from other ppl. And if you think that is mad, I think you should go and do it better yourself.

    - Martin

  25. #25
    Banned PEjump2 is offline
    BannedRank
    Jan 2010 Join Date
    The NetherlandsLocation
    2,838Posts

    Re: new packets for serialize inventory..

    Quote Originally Posted by maritnmine View Post
    Yeah, I get help from other ppl. And if you think that is mad, I think you should go and do it better yourself.

    - Martin
    Already did it myself, pretty easy, just split Wall & Floor items and send them each as a seperate packet.



Page 1 of 2 12 LastLast

Advertisement