Courier
Courier
A player to player mail system for Bukkit Minecraft servers
by defxor
Allows creation of text note items and sending of letters to players no matter if they're online or offline. The letters are delivered by postmen at intervals specified in the config file, and letters can be stored and handled as any other item for later reading. We wanted something that not only allowed us to pass notes to each other, but also felt like it was part of the regular Minecraft environment.
We believe we succeeded.
- - -=< Latest version >=-=< Videos >=-=< Tickets >=-=< Forum >=-=< Source >=- - -
Usage
- /letter [text]
- Creates a Courier Letter with the supplied text. Hold the Letter in your hands and write /letter [text] again to add more text to the Letter. Use &nl or \n to insert newlines. Multiple page Letters are supported, use right-click and left-click to turn the page.
- /post [playername]
- Sends the Letter held in your hands to another player, name verified to be a player on the server. Depending on the config, the received Letter will be privacy-locked to that player (can be unlocked by simply adding text to it with /letter).
- /courier fees
- Lists the fees, if any, that apply for sending mail or creating letters
- /courier unread
- Requests re-delivery of all unread mail, even if they have been delivered to you before. Courier knows the difference between a mail having been delivered and actually read, and this is meant to be used in the cases where you've managed to misplace the Letter without having read it first.
- /postman
- Intended for OPs only, if postman delivery happens seldom and you want to force one to appear. NOT NEEDED in actual gameplay.
To receive messages, simply poke the friendly postman when he appears or right-click him to receive the message directly into your hands or inventory.
The strings "%loc" and "%pos" will be replaced with the current X,Y,Z position in any Letters written, if surrounded by spaces.
Permissions
Quick version: Give your players courier.write, courier.send and courier.list
Long version:
- courier.write
- Allows players to create Letters (default: op)
- courier.send
- Allows players to send Letters to other players (default: op)
- courier.list
- Allow players to see name suggestions if there's more than one match when sending (default: op)
- courier.info
- Allows seeing command help, fee structure and requesting of re-delivery (default: true)
- courier.theonepercent
- Allows posting of mail even if you have no credits and Economy support has been activated (default: false)
- courier.privacyoverride
- Allows the player to read privacy locked Letters (default: false)
- courier.useitemframes
- Allows the player to put Letters into ItemFrames (default: true)
(For anything but the defaults a Superperms compatible permissions plugin needs to be installed)
Configuration options
- Privacy.SealedEnvelope
- Whether Letters that have been Posted to another player should only be possible to read by that player. If you want to change this option, please read this forum thread. (default: true)
- UseFees
- Whether Courier should activate and require Economy support through Vault. (default: false)
- Fee.Send
- The postal fee withdrawn from the player if UseFees is set to true (default: 10)
- Fee.BankAccount
- The Bank or Player account fees will be deposited into (default: none)
- UpdateInterval
- The interval between checks towards dev.bukkit.org to see if there's a new version of Courier available. A value of 0 disables. (default: 18000 seconds)
- Route.InitialWait
- How long will Courier wait until sending out the first postman after players have started joining the server (default: 10 seconds)
- Route.NextRoute
- How long between rounds. This is the maximum amount of time a delivery can take between two online players (default: 60 seconds)
- Route.WalkToPlayer
- Currently not functioning due to changes in Minecraft.
If friendly postmen (Villager) should walk up to players or not. Unfriendly mobs (Enderman) ignore this setting and never do. (default: true)
- Postman.Type
- Which Minecraft Creature to use as Postman. Courier will accept all valid Creatures but only 'Enderman' and 'Villager' are supported. (default: 'Enderman'). Note: This setting is case sensitive! 'villager' does not work, 'Villager' does.
- Postman.QuickDespawn
- How quickly will a postman despawn after having taken damage or delivered the mail (default: 3 seconds)
- Postman.Despawn
- For how long will a postman stay around each round waiting for the player to take his mail (default: 20 seconds)
- Postman.SpawnDistance
- What's the maximum line of sight distance a postman will spawn in front of a player (default: 10 blocks)
- Postman.BreakSpawnProtection
- Whether Courier should try to override mobspawn protection in order to spawn its Postman (default: true)
- Postman.VanishDistance
- The distance a Postman will check to see if a vanished player would be betrayed by appearing within (default: 20 blocks square)
- Postman.CreativeDelivery
- Whether Postmen should deliver mail to Players who are in Creative mode (default: true)
- Letter.ShowDate
- Whether to display the date a Letter was sent or not (default: true)
- Letter.FreeLetter
- If players should receive free Letters or if they need to have the necessary resources (default: true)
- Letter.Resources
- List of resources needed if FreeLetter is set to false. Example: [CobbleStone, Paper, CobbleStone] (default: [Coal, Paper])
- Letter.RequiresCrafting
- Whether Courier should just deduct the resources or if players need to manually craft letters (default: false)
- Letter.Frameable
- Should it be possible to put Courier Letters into ItemFrames - in effect creating posters/flyers (default: true)
In addition to the above all user visible strings can be edited. Some translated configs are available in the translations folder as well in the plugin data folder. Move and rename them to 'config.yml' to use.
Trivia
As you've understood (and seen if you've looked at the in-game images) I use Maps to render Courier Letters. If you're a plugin developer and your plugin handles maps and you either want to make sure your map system isn't screwed up by Courier Letters, or maybe if you want to handle Courier Letters in a special way, you can easily identify them:
The actual Maps used by Courier to render Letters ALWAYS have their X coordinate set to 2147087904 (or INT_MAX - 395743, if you want).
The ItemStacks(Material.MAP) that point to those Maps are Enchanted with DURABILITY and the enchantment level is used as a database key to find the matching text.
Release history
- 2015-05-14: v1.2.1 uploaded
- 2015-05-09: v1.2.0 uploaded
- 2013-01-16: v1.1.9 uploaded
- 2012-12-30: v1.1.8 uploaded
- 2012-12-20: v1.1.7 uploaded
- 2012-03-04: v1.1.6 uploaded
- 2012-02-25: v1.1.5 uploaded
- 2012-02-13: v1.1.1 uploaded
- 2012-01-31: v1.1.0 uploaded
- 2012-01-15: v1.0.0 uploaded
- 2012-01-02: v0.9.6 uploaded
- 2011-12-30: v0.9.5 uploaded
- 2011-12-27: v0.9.2 uploaded
- 2011-12-26: v0.9.1 uploaded
- 2011-12-23: v0.9.0 uploaded. This page created.
(see the Changelog for detailed information)
Known issues
- Moving Letters between slots in creative mode (/gamemode 1) causes them to become empty later (eg. after logout/login)
- This seems to be a Bukkit issue, please do not handle Courier Letters in creative mode until this is better understood.
- Courier does not support extended character sets, it will skip such input when writing Letters.
- This is due to Bukkit Maps only supporting the 'old' standard Minecraft Font. If support is extended in Bukkit I will implement it into Courier as well.
- ... and all open tickets and issues, of course.
Future development
This plugin is looking for a new maintainer. The original author does not play Minecraft any longer. The update to Minecraft v1.8 could only be made thanks to a pull request having been made at Github. Do not expect any future development until a new maintainer can be found.
Wow it looks awesome.
@defxor
Well you don't need commands to do that... You can still move while holding a map so if a person decides to write a message (by typing /post in chat) it just opens a menu (in your map) and instead of moving while holding the map you move trough the menu. When you want to write something you go to the writing and when its finished you just hit enter. And it gives you some other stuff to chose (like send to ...)
@roelmb
Hi and thanks for your comments! It's likely there will be additional NPC choices - I've tried to start a forum discussion around it.
Regarding menus in maps I really want to stay away from commands as much as possible, since I think it ruins the immersion of the game. Currently it's needed for letter creation (if I don't go the enter-text-via-signs approach) but not for reading, and it's the only way for me to "detect" a player action when holding a map. It's also not needed to solve the MapID issue, I think (but I want to verify with code before claiming so) that there will be a one map id solution for v1.0.0, but still as many individual map items as there are messages (or more .. )
@Montpelier
"Uh... Players... I hate this. Do they want to share what they got or take what you got? Do you say 'hi' or do you blow them away?" - The Postman
Isn't it possible to let Notch his Npc's deliver the mail? Looks more realistic no?
And can't you make it so it only uses 1 map id (displaying diffrent stuff depending on player name?) ? Or 1 map id per player?
Where it links a player to a map where he can scroll a menu in the map (dunno if thats possible) to choose which message he want to read?
Bukkit can't add anything that isn't already in the game without a client mod, so the mailman is actually an Enderman who teleports near to you carrying a bookcase (your mail), which you can take from him. It makes sense considering they're the only NPCs in the game that are neutral and can teleport naturally.
Actually... the postman should have a hardcore difficulty setting that retains his normal behaviour so you have to pick up your mail without looking straight at him. Or he kills you.
https://github.com/Bukkit/CraftBukkit/commit/83d12512b4150a38a30aca6f503e163e2730f2c2 Fixed.
I know this is probably a stupid question, seeing as someone asked if they could change the mailman's skin, but is this "mailman" an actual NPC? Or is it just a virtual message proclaiming the arrival of a "mailman"? And if there is one, could someone put up a video or a handful of picture? I'm curious about the order this plugin would take out (I.E from sender to receiver, and the whole process in between) :P
All: I've realized that what I thought to be the easiest for you who are interesting in commenting on Courier, a simple comment page here, might not be the best both for comment visibility and the possibility for you to discuss.
So, I've opened up a Forum for Courier here. Feel free to start new threads for your favorite ideas if they don't fit with the ones I just created.
Update on 0.9.6: I've had one user report back that it indeed works for him with breaking through WorldGuard spawn protection. I'll wait for a few other confirmations and then it'll go live. If you don't want to wait or just want to help in testing its regular stability, it's still downloadable here.
@Axol96
Please if you could add those thoughts to this ticket it'll make sure I have them in mind when going through that code :) (After v1.0.0)
It would be cool if u added a option in settings so other players can read a mail that someone send to a certain person , im hosting a pvp/war server and would be cool if ppl are able to steal mails and read about secret plans and stuff :D
@nicquehen
If you want, could you please test this tentative 0.9.6 build and see if Postmen spawn even in WorldGuard protected areas now? (And still works as it should otherwise of course). If it does, I'll release it as a proper version on this page.
@Gnintendo
I'll look into the selection of different kinds of Postmen after v1.0.0 which is when I'll fix the MapID problem and separate the creation of Letters from Posting them.
Can you please add support to set a custom skin for the mailman?
@dadaemon
Hi, and thanks for coming over offering your support! :) At first I was going to reply with how I've looked through the various possibilities, and that I already use the contextual map setting etc - but then I remembered (and this might be exactly what you're doing) already using the entity unique id to track my Postmen and I should be able to use the same unique id for (Map) Items. If so, I could use those as keys into the message db instead of actual Map IDs and then - as you - use a single Map for its canvas when rendering.
I'll branch off and test this right after New Years :)
@defxor I was send here by someone because I use maps in my plugin too. He wanted to know if I have the same problems as you are getting (limit of maps.)
I haven't tested your plugin just yet and don't know how you've implemented the maps but you can adjust it so that different people see different stuff on a map with the same id.
I just use map id 0 for all my map stuff so I can't run out of maps. If you need help with this or this just give me a reply and I can send you my code.
@dunem666
Thanks for the comment, I've added a ticket that Courier should not display that message if the spawn has been cancelled by other plugins. I suspect you have Worldguard or similar blocking mob spawns? Courier uses pacified Endermen as postmen.
See http://dev.bukkit.org/server-mods/courier/tickets/9-override-mobspawn-deniers/
(If I find an easy override this will probably warrant a dot release in a few days)
hi there, great plugin here and installed on server. all my perms are correct also
are we supposed to see an NPC postman? and is he supposed to give me a map to read?
i get a message a postman arrive but i dont see anything or receive anything
please help!
0.9.5 released, brings the Economy support I know a lot of you wanted. My main focus will now be on v1.0 which will likely consist of separating the creation of Letters and Posting them, as well as solving mail recycling. New minor releases will be made if I messed something up just now or if high priority bugs appear. Currently there's one ticket indicating a possible problem with the latest Bukkit devbuilds, which I haven't verified yet.
@nicquehen
Of course :) I guess I can assume that any server owner who's installed Courier would want the (pacified) Postmen to appear even in zones where mob spawning is denied. I'll look into overriding it.
Love the plugin.
little bug: When you are in a mob-spawning deny (worldguard) the postman don't appear.
@JoeGandy1
I guess that would be as simple as changing default permission for courier.send from 'false' to 'op' - I'm assuming you meant for OPs to be able to use the plugin and no one else if no Permissions plugin is installed?
Sounds reasonable, I'll change it for the next version. (Which I expect to release in a day or so, with Economy support as well).
@anotherfahlman
Yeah I will most likely separate Letter creation and Posting, and then you should be able to send the Letters just as any other item together with other plugins etc if you want.
@Montpelier
Thx - ticket created :)
@martinherrmann
Standard permissions won't work with this plugin atm, i was just trying it on my server