Bananaprotect [Craftbukkit Plugin]
#11
When you place the dirt operators and admins can see the name off the person who placed it
Reply
Thanks given by:
#12
@ThuGie: I think we need a plugin that's smarter than that - checking all the stored blocks for each placement will be ineffective very soon. When there are thousands of stored blocks, you need something better. For each player, load a list of all protected blocks within a 32x32x32 area around them; reload the list every time when they leave the 16x16x16 subarea of that big area. As for storage, store a hash of both the chunk coords for all the blocks and index on that.
Reply
Thanks given by:
#13
@xoft, thats the point off bananaprotect, it doesnt create "Protected area's" if people grief against other buildings you can check their name and Jail/Ban them for it.

People cant destroy blocks placed by other, admins/operators can.
Admins/operators can check the name who placed a block.

This way you can keep control who is not following the rulez
Reply
Thanks given by:
#14
What xoft means it that it only loads the protected blocks in a 32x32x32 area around the player. That way the RAM usage is reduced.
Reply
Thanks given by:
#15
Actually correct me if im wrong,

It only has to load when:
* Player try to destroy block
* Admin/operator requests the block information
Reply
Thanks given by:
#16
@ambushed01 If the plugin checked the entire list every time the player places or breaks a block, the performance would be terrible:
- When the player connects, the server has to load all the blocks that they aren't allowed to modify
- Each time the plugin has to check this entire list of blocks
Now, suppose there have been 50 players on a server who built something; each player placed about 10.000 blocks (20*10*50 cube - clearly a mid estimate) that would mean loading and checking a list of 500.000 items *each time*. There's no way a plugin can manage that.

STR_Warrior is right, what I meant is to keep track of the protected blocks only in a small area around the player, and update that list when the player moves out of that area. It is still block based, but this time you're not checking 500k blocks, but only 32*32*32 = 32k blocks at most; much less if the plugin is smarter. But you still need a way for the DB to quickly be able to spit out the correct list of blocks rather fast, that's where the chunk coords may come in handy.
Reply
Thanks given by:
#17
SQLite is very fast, so a select in a table of 500k blocks in a table with indexes will be perfectly fine (< 100 ms at least).

Splitting it up would be a bit better, and good index choices really make a difference.

The thing you really have to worry about is database size (CoreProtect a rollback plugin has databases that regularly go up to 5 gigs for small servers).
Reply
Thanks given by:
#18
I have started work on this plugin, I will provide a working base that someone else can then take over to implement the advanced stuff.
Reply
Thanks given by:
#19
The working base is finished: https://github.com/madmaxoft/PrivateBlocks
It provides the auto-protection for blocks. It doesn't have the friends support yet.
Reply
Thanks given by:




Users browsing this thread: 1 Guest(s)