Today i ran into a problem, my catalogue was not updating after someone bought an LTD. So i started to find where the buying method for LTD's is located. I found it and then looked for the refresh cata command.
I simply added some code of the Refresh cata to the buy LTD part.
Ok, so now i will be explain how to do this.
Look for catalog.cs in Butterfly > HabboHotel > Catalogs. Open the file and search for:
After that line of code add this:
Voila! Now it updates the catalogue when someone buys an LTD item. (it will not directly update for the current user, maybe someone else knows how to do this?)
Hope this helped
I simply added some code of the Refresh cata to the buy LTD part.
Ok, so now i will be explain how to do this.
Look for catalog.cs in Butterfly > HabboHotel > Catalogs. Open the file and search for:
Code:
adapter.runFastQuery(string.Concat(new object[] { "UPDATE catalog_items_copy SET limited_sells = ", item.LimitedSelled, " WHERE id = ", item.Id }));
After that line of code add this:
Code:
using (IQueryAdapter adaptr = ButterflyEnvironment.GetDatabaseManager().getQueryreactor())
{
ButterflyEnvironment.GetGame().GetCatalog().Initialize(adaptr);
}
ButterflyEnvironment.GetGame().GetCatalog().InitCache();
Voila! Now it updates the catalogue when someone buys an LTD item. (it will not directly update for the current user, maybe someone else knows how to do this?)
Hope this helped