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.
hm? The players gamemode and inventory gets restored to exactly the state before sleeping. If not, please create a ticket with a detailed description of what is happening.
Exactly. Everything worked. Or what do you mean ?
Minecraft players fill up there inventory with diamonds and ores different items they need. Go to sleep in creative mode. Then they will end up in the dreamworld. Then spawn to the main world and end up with the Creative inventory. Any ideas????
Maybe to reach a certain spot to leave the dream world eralier? I thought: maybe players have to find a bet to leave :) But as they always spawn at the same spot currently (world spawn) it would always be the same .. :/
A mission in the dreamworld would be perfect ;)