Nucleus icon indicating copy to clipboard operation
Nucleus copied to clipboard

/unclear after /clear

Open MorbiusStorm opened this issue 7 years ago • 4 comments

Is your feature request related to a problem? Please describe. /clear by accident or the wrong target is a problem.

Describe the solution you'd like Give an undo function like /restore or /unclear.

Describe alternatives you've considered Give a warning of what will happen and retype the command a second time to confirm.

MorbiusStorm avatar Aug 07 '18 21:08 MorbiusStorm

Not completely against it, but there are bigger fish to fry and so not likely going to make it soon if I'm left to do it. If someone wants to PR this, I can work with them.

dualspiral avatar Aug 14 '18 17:08 dualspiral

I can take on this task if you'd like, just let me know how you'd want it structured.

NickImpact avatar Aug 22 '18 20:08 NickImpact

I think the main thing to think about is just how to temporarily store a cleared inventory. A handler containing a cache that holds UUID to List<ItemStack> will probably suffice, or some way to hold where things were (that'll be the hardest part), ensuring that they expire quickly.

If you're happy to give it a go, please do. I'm somewhat busy at the moment but I can help with pointers on PRs at the very least.

dualspiral avatar Aug 22 '18 21:08 dualspiral

Hey!

I'm going to give this a little bump to see if there are any new faces who could bring this wholesome idea into reality :heart:

+1 for /unclear

TheFlash787 avatar Jun 15 '20 12:06 TheFlash787