Random Chitchat 2012-2016
Big change!
I have refactored the cInventory code, it now uses three cItemGrids for the armor, the inventory and the hotbar, respectively. This brings a whole set of API changes, I believe they're for the better, since now the API is more balanced, more orthogonal. And there's a lot of helper functions to make your life easier.
I have changed the internal plugins (Core, Debuggers), but if you have written a plugin that does anything with the inventory, you need to have a look at your code and change it.
I'll be updating the API in the wiki momentarily.

Btw, check out the Debuggers plugin, it has a "/wool" command that sets all your armor to blue wool. And all the other players can see that armor. Coooool! Smile
Thanks given by:
cInventory and cItemGrid API documentation in the wiki is now up to date.
Thanks given by:
Could you add some class to the API to save inventory on server and then recover it?
It would be useful to make a multi-inventories plugin.
Thanks given by:
You could use a for loop to save every slot of a player.
Thanks given by:
isn't this flyspray thread done?
Thanks given by:
Not exactly - it's missing some of the composition components, such as mushroom islands.

I've revisited some of the APIs for block entities, so now it's possible to interact with chests and dispensers by plugins. Have a look at the Debuggers plugin, rclk a dispenser with a redstone torch Smile
Thanks given by:
MCServer is so usefull. I now used to rename all the episodes of an anime i am watching Wink I was just too lazy to rename all 500 episodes by myself so i wrote a plugin for it Wink
Thanks given by:
:D
You're becoming a real programmer Smile

You could've used TotalCommander for it, it's the ultimate file manager and mass-renaming is one of its strongpoints.
Thanks given by:
(05-26-2013, 06:06 PM)xoft Wrote: You could've used TotalCommander for it, it's the ultimate file manager and mass-renaming is one of its strongpoints.

That would have taken the fun out of it Wink
Thanks given by:
I have implemented droppers in rev 1514. They are now fully functional and Lua-accessible. Also, since they share lots of their code with dispensers, I have created a common ancestor class for them, cDropSpenser; which is also Lua-accessible (so Lua plugins may use the same code for dispensers and droppers, if they wish).

The only thing they're missing is that when you put something in them, the chunk is not marked dirty, so it is not saved to disk (unless you modify the chunk otherwise). I'll be doing a more thorough solution for this issue, because I think it's the same with chests.

Chests, dispensers and droppers now correctly mark their chunk as unsaved.
Thanks given by:




Users browsing this thread: 11 Guest(s)