Dreamworld
Dreamworld
Looking for maintainer!
The plugin is quite outdated. Unfortunly I am too buisy with other projects currently. So if you want to help out by picking up this project and fixing its issues, let me know.
What is this?
Dreamworld gives players the chance to wake up in an other, specified "dream" world when they leave their bed.
The dream world has to be specified in the config. If the plugin does not find a world with the specified name, it will automatically attempt to load or even create this world at startup. The default worldname is "dreamworld".
If you want to use a custom world generator for your dream world, I suggest you to first create the world via one of the popular world management plugins (like for example Multiverse).
By default, when a player starts dreaming, their stuff (inventory and other player-state-information) is stored in memory, they are cleared, teleported to a random spawn location (or the dreamworld's spawn location, if you didn't set up random spawn locations yet) and they get assigned some potion effects (high jump, short view range, speed, confusion, etc..) to create some sort of dreaming-impression.
You can configure those potion effects in the config file by the way, together with a lot of other stuff. See below for a complete overview of the configurable features.
After a random time (specified by the config) they get teleported back and restored to their old state.
To handle quits or server restarts during dreams, the plugin ends the dream in those situations (the player gets teleported back and restored). But before that happens the plugin saves the player's current dream-state (his items, effects, location, remaining dream duration, etc.) to file for later continuation (when the player logs back in or the plugin gets enabled again).
In the config there is a option which determines after how many minutes the plugin shall purge those saved dream-states (default: after about 3 days).
If you want to edit the messages which are print to the normal users in certain situations, take a look at the messages.yml file.
What next?
This are the very first basic features for now. But the potential for additional features are endless for that dream scenario. Possible ideas are:
nightmares, dream escapes, treasures, scenarios, tasks, option to make dreaming players invisible for each other, blocking chat, etc..
If I get the time I might add some of them in future releases.
Or if you want to add something: the source code is on github and you are free to make pull requests.
Commands
Not needed in general but maybe helpful..
- /dw help - Command list.
- /dw setspawn - Sets the spawn location of your current world.
- /dw dspawn - Teleports you to the dream world.
- /dw spawn - Teleports you to the main world's spawn.
- /dw addspawn - Adds your current location to the list of random dream spawns.
- /dw clearspawns - Clears the list of random dream spawns.
Permissions
- dreamworld.dream: Ability to dream. default: true
- dreamworld.admin: Access to the admin commands. default: op
The default configuration file with explanations
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
#--------------------------------# # Dreamworld | #--------------------------------# # All dream settings: dream: # If no world with this name exists, it will create one. # If you want to use a custom generator, I suggest you to first generate the dream world with a plugin like Multiverse. world name: 'dreamworld' # Whether or not animals and monsters shall spawn: no animal spawning: true no monster spawning: false # The chance that leaving a bed leads to a dream (between 0 and 100): chance: 25 # The minimal and maximal durations for dreams in seconds: min duration in seconds: 25 max duration in seconds: 300 # Whether or not the player shall spawn at one of the random spawns when he starts dreaming, instead of the dream worlds spawn: spawn randomly each time: true random spawns: [] # The gamemode, health, hunger and potion effects a player starts with: gamemode: apply: true initial gamemode: 2 health: apply: true initial health: 20.0 hunger: apply: true initial hunger: 20 potion effects: apply: true initial potion effects: SLOW_DIGGING: duration: 2147483647 level: 20 JUMP: duration: 2147483647 level: 10 SPEED: duration: 2147483647 level: 2 CONFUSION: duration: 2147483647 level: 1 NIGHT_VISION: duration: 2147483647 level: 100 BLINDNESS: duration: 2147483647 level: 100 # Whether or not the player shall be completely cleared on enter and restored on exit: clear and restore player: true # Purge saved dream data after this amount of minutes (should be higher than the max dream duration): purge saved dream data after x minutes: 4320 # If the remaining dream seconds are less than those of this setting, the player will skips those remaining seconds if he disconnects or attempts to continue his dream on login: ignore if remaining seconds is lower than: 10 # Whether or not the player's personal visual time shall be modified: fake client time: enabled: true # The time to which the client will be set: time (in ticks): 12000 # Set the time randomly instead? These bounds determine how much the time will randomly differ from the time defined above: random bounds: 0 # The client's time will not change during the dream with this enabled: fixed time: true # Whether or not it shall rain for the dreaming player: fake client weather: raining: true # Whether or not it shall randomly pick one of the sounds from the list below and play it at dream start: dream start sound: enabled: true # format: "sound;volumn;pitch" random sounds list: - "AMBIENCE_CAVE;1.0;1.0;" - "WITHER_SPAWN;1.0;1.0" # Disable various stuff for the dreaming player: disabled: hunger: true # Damage settings: If the player dies, he leaves his dream. If the player falls into the void but all damage is disable, he will be respawned at some dream spawn. fall damage: true entity damage: true all damage: true item dropping: false item pickup: false weather: false block placing: false block breaking: false # A list of allowed commands. All other commands are blocked for non-admin players. Make sure to not put any kind of teleportation command in here: allowed commands: - '/list' - '/msg' - '/m' - '/r' - '/reply' - '/tell' - '/whisper' - '/login' - '/register' |
Bugs found? Or having an idea?
Then please create a ticket.
The Plugin bugs out when returning a player to the main world.
This is best plugin that Ive come across! I love the idea of "falling Asleep" and going to a dreamworld! I would probably make some crazy map where they can explore and have crazy fun with the potion effects.
Is there anymore support for this plugin? I'm going to give it a try and see if it runs without any errors :)
@NekoKalil
It should. However, saved dreams might not get restored if a player changes his name. Besides of that it shouldn't cause any issues though.
does this work on the most recent version?
Wow never had seen an awesome plugin like this O.o
@DiamondObsidian
You mean to other worlds? Yes, you can. It will even create an additional "dream" world.
Can you go to other dimentions with it?
Works great for now ;]. Thanks for quick patch.
@MikeGold
Hm, my guess is, that you die after you left the dream, because of the fall damage from falling into the void and then being teleported to your old position. But this problem should also occur in the older versions if you entered the dream in survival mode..
I uploaded a new file:
v1.4
Please let me know if that fixes the issue.
Hello, it's me again ;].
1.3 surely lets you die, but when I fell into the void in my drim, I woke up and died.
v1.3
@MikeGold
Between, I was just testing because of the inventory problem with LimitedCreative:
For me it seems to work: No matter if I am in creative or survival mode when I lay down in the bed and start dreaming, I get my inventory back afterwards..
Maybe you have another plugin which interferes?
Well, my players surely enjoyed a week of stress-less survival. No one even bothered to report it to me until I found it myself ;].
@MikeGold
whoops, yes. I forgot to check if the player is actually dreaming. Will be fixed in the next version, which I will try to upload today.
I've just discovered a curious little bug in your plugin. Everything works as it should, you won't die when you wake up, but... You can't die anyway. The health goes to the minimal stage with only a piece of one heart and then you can't die. When I remove your plugin from my server everything goes back to normal. When you fall, there is no damage, when you drown, HP goes down to a minimum and you won't die, and with mobs it's the same.
@blablubbabc
If that's what you can do, I'd like that, actually. You don't need to go further into it other than to trigger a sound at dream start. It's really all I'd need. Either way the plugin's pretty awesome, so it doesn't matter overall. I can't wait to see what else happens with this plugin.
@brandon4117
Theoretically, yes. I can trigger the sounds from this list (http://jd.bukkit.org/rb/apidocs/org/bukkit/Sound.html). If you replace those in your minecraft folder, a different sound is played.
If you replace one of those sounds, for each client..
However, I don't like the idea of having to constantly trigger some sound while the player is dreaming. What I can add, is to trigger a sound at dream start. Everything else would be to specific that I would not want to add it..
@blablubbabc
To be a little more specific, as I have a hard time explaining things;
I mean, is it possible to have background music play while you're in the dream world?
Like in regular minecraft, at random moments when certain songs play while you walk around in the usual world.
And as for the other part you didn't know I was talking about; I meant to ask if it was possible to play my own custom music for the dreamworld's background music, if playing ANY background music for the dreamworld was possible.
Sorry if it's still not that clear, I'm horrible at explaining.
@brandon4117
You mean for example triggering the cave sound when the dream starts?
Me neither, as I do not know what you are talking about..
Thanks!
Heyo, I'm wondering if it's possible to have specific music play inside of the dreamworld. I've got a few things I'd like to place inside of the world specifically for it, but I dunno if that's possible or not.
On another note, I really like this plugin. Nice job.