Lets users with the permission toggle between spectator mode and their previous gamemode. Great for if you want to allow spectating but not creative.
Use the command
/spec to toggle spectate status.
spectastic.spec - Lets you use the above command
I have encountered a small problem… it tends to be a bit lethal when changing back from spectator to survival mode, unless you hover over water. Going for a short fly in spectator mode, followed by attempting to land on a rooftop, ended with a resounding SPLAT. Is there something you can do to make for a less lethal landing?
<Also, add more FLARD>
There absolutely is! Possibilities:
- Find a safe place and teleport the user there.
- Give a few ticks of invulnerability.
The safe place search is a tricky idea to pull off, because there’s several situations where things wouldn’t play well:
- If the user ends up in a completely filled chunk, the search would take some time. Bring them to the top, regardless of height?
- If the user is hanging out near lava, either a lot of careful searching would have to happen or they might end up burning.
Maybe make an attempt within 20 blocks of the user’s current location and then do something else? (Spawn, bed location, nearest player?)
I can’t see many use-cases for reappearing inside a column of stone, so one would hope the user chooses a reasonable place to attempt to reappear. I’m not sure how you’d want to handle players who appear to want to become embedded in a bridge support, swim in a sea of lava, or plummet from the sky. Mayhap some options for admins to choose from.
I think the thing that killed me was that it regarded my flight as a sudden drop when I changed gamemode, so a block or so became a hundred or more. I’ve had the same issue with creative → survival before, and I’m not sure if a plugin is the root of the problem.
How does Minecraft handle this when changing from spectator to creative mode?
EDIT: Badly, it would seem
Ohhhhhhhh I know. It does something like record the highest height you’ve been to since you last touched ground, and then calculates the difference between that and the height at which you landed to determine fall damage. So if you were flying up high… dead.
I do like the idea of providing options now that you’ve mentioned it. Either way I’ll look into preventing fall damage.
One suggestion to switching modes.
When you switch to spectator remember cords when that happened, and when switching back tp player there.
You can make that configurable as one of the options what happens when switching modes.
This works perfectly, even on Spongeforge 1136, so it has no incompatibilities with API 3.0.0 as of yet!
I like this idea, so then it could be an “Out of body” kind of experience, and prevent users from using this system as a way to find things underground that they shouldn’t and immediately being able to access them.
Well the API doesn’t break completely between builds, so if a plugin uses API parts which didn’t break, then you can use said plugin on an older API version
However that’s not guaranteed and that’s why the API got a new major version.
Oh, okay. I understand, I say this only because I’ve tried a couple new 4.0+ plugins on my older API build, and as of yet nothing has worked. Just wanted other API 3.0 users to know that this will be compatible with their servers if they deem it useful
Actually, it uses the distance you’ve travelled downwards. You can see it in action with a leash “yo-yo” (leash an animal to a floating fence post, wait a few minutes, and unleash them).
I like this idea the most, it seems logical and easy to implement. This should be the default way of handleing things with more (optionally) be added later.
Indeed, it’s my plan to play with a bunch of feature additions starting soon, into the weekend.
Not really your issue, as it’s caused by a conflict between two plugins, but one of my staff was in /spectate mode and had also execute /fly. This caused them to fall immediately through the world into the void. I’m not asking that you fix this, just that it made me laugh when I found out and I thought I would share
That is pretty fantastic. So they were spectating, and started flying, and just… fell? That’s… interesting.
To clarify, this /fly command sets them immediately as flying, or just able to double-space to fly?
It’s the one from essentialCmds, so it’s a double-space mode, but they were spectating, and as soon as they typed /fly they started falling. I’m assuming since spectator mode has flying locked on, this forced the flying to immediately be locked off.
I tried it myself and I nearly was to tears laughing about it.
you should probably file a bug report to EssCmds, as it should check wether a player is in spectator mode or not when en- or disabling fly
Could we get an update to API 5 or 6 for this? Sorry to necro the crap out of this, but it no longer allows my server to start when I have it installed when using the latest API :c
I suppose I could do that!