MemoryStone
Memorize and teleport to special Memory Stone structures in game using your compass.
This is a great for exploration: You can head in a direction and explore the depths of caves, but when you want to go home it's a simple teleport out. Also, because you have to find the Memory Stones first, it makes exploration of existing servers with pre-setup Memory Stones a little more rewarding.
I would find that I would build myself a little home and maybe explore a little bit, but not too far in case I get lost.. I'd also find very interesting parts of my world, but would never return there because it's too far or I just can't find it again. Now it's a matter of building Memory Stones where significant marking points are. Have a castle in the sky? No need for ladders..
Changes in 1.1.0 & 1.0.9
- Interaction with other sign based plugins sometimes throws NPE's onSignChange event.
- pointCompassOnly config option if you don't want teleportation, but just set compass to destination.
- Fixed small quirk where memorizing a stone would select that stone to teleport to instead of leaving it as it was before.
- Fixed a pretty show-stopping bug where the compass totally didn't work. Whoops.
Changes in 1.0.8
- Fixed up an NPE when only one location is memorized and you try teleport stone to stone from it
- Fixed a small bug if you use lava buckets in water to create your memory stones.
Changes in 1.0.7
- Set the default distanceLimit in structureTypes.yml to infinite on all default structure types. This was tripping a lot of people up.
- Replaced lightningEffect config option with effects.lightningOnCreate and effects.lightningOnBreak
- Added effects.lightningOnTeleportSource and effects.lightningOnTeleportDestination for effects when teleporting
- Allow for teleportItem to be set to NONE, which disabled teleporting with an item.
- Added stonetostone.enabled, to enable teleporting directly from a Memory Stone (without compass)
- Added stonetostone.item and stonetostone.maxUses if you want to have people pay for stonetostone teleporting
- Remove 'already memorized' message if stonetostone.enabled
- Fixed up a charges left bug (was rolling over to 3 charges regardless of max uses)
- Default language refers to <material> now instead of compass (lang.chargesleft, lang.consumed, lang.teleportitemnotfound)
Download
If you are upgrading from older than 1.0.5, you need to remove the structuretypes.yml to so that it can regenerate and include the new teleportation, memorization and build costs..
Installation
Simply put the memory-stone.jar into your plugins folder. Upon first run, you'll see MemoryStone/structuretypes.yml that you could play around with if you'd like to customize the memory stone structure on your server.
When you start creating and memorizing Memory Stones, you will also see locations.yml and structures.yml files - they are for storing the extra player and physical structure data for your worlds.
There's also a configuration.yml file generated, scroll down to the bottom to see the configuration options available.
Setup
Create a 3x3 Stone slab with a 3 high Obsidian pillar in the middle like so :
Put a sign somewhere on it and enter the first line of the sign as the name you'd like to give the memory stone :
And if all is well, you'll get a green 'Memory Stone' sign :
Structure Types
Please see the image library here to see all the different structure setups
There are a few different structures, basically :
- Local: Teleport from your location to a Local Memory stone in your current world within distance
- Global: Teleport from where you are to a larger range in the current world, but doesn't need to be memorized first
- Crossworld: Teleport from any world to any crossworld stone. Distance doesn't matter.
- Global Crossworld: Same as a crossworld teleport, but you don't need to find and memorize it first.
- NoTeleport: Players can't teleport out while within a certain distance of these.
Economy Support
As of 1.0.5 with economy support, when setting up a sign, you can enter a memorization cost / teleportation cost like so :
When you complete that, it will add the preconfigured base costs and display that on the sign :
Usage
All of the following needs to be done with a compass in hand:
Left click on the *sign* of a memory stone. You'll get a confirmation to say that you have successfully memorized the location.
If you have Spout installed (and Spoutcraft client), you can right click to bring up the following screen - select destination and it'll teleport you there:
Similarly, you can hit a shortkey key (default 'C') to show that screen as long as you have a compass in your inventory somewhere. If you have Spout on the server and running Spoutcraft :)
If you don't have Spout installed, you can right click to teleport back to the stone you've just memorized. You need to stand still for 3 seconds after you've activated teleporting, and if you have multiple memory stones memorized, you can left click to cycle to your destination.
As of 1.0.7, if you have glowstone dust in your inventory (configurable) you can left click on a memory stone sign to cycle through destinations and right click to teleport without the use of a compass. If you have Spout & Spoutcraft, you only need to right click on the sign.
Configuration Options
In the configuration.yml file, you can change these options to customize MemoryStone for your server:
- lang.* - This is all the text the players will see from this plugin.
- teleportItem - Configure to use something different to a compass if you like. Accepts names or typeId's
- castingTime - The time the player (and target if teleporting another player) needs to stand still for until teleport happens.
- cooldownTime - The cooldown after teleporting successfully, in seconds.
- fizzleCooldownTime - The cooldown after fizzling (player cancelled teleportation somehow), in seconds.
- maxUsesPerItem - How many charges an item has before it is consumed. If this is set to zero, it will be unlimited.
lightningEffect - Whether to show the lightning effect when a Memory Stone structure is setup correctly.No longer supported as of 1.0.7, see effects.*- sortByDistance - If true, sorts the location list by distance instead of alphabetically
- economy.enabled - Enable economy support. You may have economy plugged in but don't want to use it for memory stones
- economy.ownerGetsPaid - The person who setup this memory stone will get paid whatever anyone spends on this memory stone
- economy.addCustomValue - Allows a person setting up a memory stone to specify extra costs (above base costs) on placing the sign.
Added in 1.0.7:
- effects.lightningOnCreate - Lightning effect on creation of memory stones
- effects.lightningOnBreak - Lightning effect on breaking of memory stones
- effects.lightningOnTeleportSource - Lightning effect when teleporting (player source location)
- effects.lightningOnTeleportDestination - Lightning effect when teleporting (player destination location)
- stonetostone.enabled - Enable stone to stone teleportation
- stonetostone.item - Item to consume on stone to stone teleporting - set to NONE if you don't want it to consume anything
- stonetostone.maxuses - Maximum number of uses on the item to consume before destroying it - set to zero for infinite or to 1 for a single use.
Permissions
- memorystone.*: Gives access to all normal MemoryStone permissions
- memorystone.op: Allows free, zero casting time and no cooldown to user, default: false
- memorystone.build: Allows user to build Memory Stones, default: true
- memorystone.break: Allows user to break Memory Stones, default: true
- memorystone.use: Allows user to teleport to Memory Stones, default: true
- memorystone.usestonetostone: Allows user to use stone to stone teleportation
- memorystone.usefree: Allows user to teleport without costing charges (if applicable), default: false
- memorystone.useonothers: Allows user to teleport others, default: true
- memorystone.usewithoutcooldown: Allows user to teleport without cooldowns, default: false
- memorystone.useinstantly: Allows user to teleport without casting time, default: false
- memorystone.allmemorized : User will doesn't need to memorize stones.
- memorystone.create.*: Can create any structure
- memorystone.create.local: Can create local memory stones
- memorystone.create.global: Can create global memory stones
- memorystone.create.crossworld: Can create crossworld memory stones
- memorystone.create.crossworldglobal: Can create crossworld global memory stones
- memorystone.create.noteleport: Can create noteleport zone stones
Known Plugin Incompatibilities
- SpoutTrade: Because of using the right-click on players, it requests a trade and teleports.. Not sure how to stop SpoutTrade from firing.
Credits
Some shout out to some awesome devs out there!
- The Bukkit team
- The Spout team - Go install Spout and Spoutcraft. Now. Believe me, it's a better place.
- tprk77 for HealingTotem - I used his awesome structure code - this should really be in the Core Bukkit code.
- krinsdeath for ChestSync - I used some of his coding ideas and signage code.
- The guys who built BlueTelepads - Their code helped me get the yaw and pitch correct.
- Nijikokun for Register - Awesome work!
Also, credit goes to the following people for their fantastic input:
Tylui, PhantomX, Kaiemi, hammerKlavier and SirMonsterSlayer
New update tested and it still doesn't work ;(
@SirMonsterSlayer
Oh dear, i'll look into it asap
This plugin needs to be updated now. It seems that spoutcraft update broke the "menu" ;(
Could you please add the possibility to use different prices ? I want different "categories" of stones the one to the nether portal should be pricier :P
MemoryStone appears to be functioning properly now. Now I just need to install spout on my test server and check that out.
Thanks for the quick update. ^^
@lawdac
Whoops - thanks lawdac.. A total showstopping oversight on my part! The stone-to-stone work I did completely broke the normal functionality of the mod. I've uploaded 1.0.9 to fix it. As soon as it's approved you'll see it up
Following up on hammerklavier's work in 1.8.1.
I am not using Spout at the moment, but it would appear that regular teleporting is not functioning in 1.8.1 SB 1152. I created 2 memory stones, "treetop" and "treetop 2." Both stones are identified when swapping using the left click, but when I try to teleport between the two using a compass it does not work. When I try right clicking the compass on a stone, I suddenly teleport to my target destination.
I have not played with regional stones yet, but I look forward to testing that feature in the morning.
@hammerklavier
Cool, I know exactly where that little quirk is and have surgically removed it and uploaded 1.0.8a :) It doesn't trigger "switch to next" now though - it just doesn't change your selection :P
Haha, sounds pretty neat - the discovery part plays right to what I imagined the plugin to be used for :) We've got about 10 memory stones fairly close to one another and burning through compasses even at 50 charges per compass! Just loving the convenience. And it's nice to be able to say 'Meet me at WizardIsland' and you both teleport to exactly the same place.
@CmdrDats
I always use stone-to-stone mode exclusively, of course; I mention it because you may need that context ;)
It does appear that after you memorize a new memorystone, if you immediately try to teleport it'll default to teleporting to that memorystone. Once you start to switch destinations, it does not show the current memorystone in the list as it cycles through, of course. Just that very first time. Not even a bug, more like a quirk. If you could trigger the "switch to next" thing silently when someone memorizes a new stone, so it will default to the very next one in the player's list, that would solve it.
This is the only goof I've found :P Otherwise, "completely perfect plugin" pretty much covers it. I'm already annoying my players by placing the obelisks very sparingly, and refusing to let them build more. You're supposed to kinda "discover" them by walking there, guys!
@hammerklavier
Thanks for picking up that exception - that was due to the fact that you only had one stone memorized and were trying to teleport from that stone :) It removes that stone from the list to cycle from (since you don't want to be teleporting there anyhow)
I've also fixed up the obsidian form lava bucket problem - a simple fix really, it checks if there's a memory stone structure behind the sign when you place it, quite simple :) So you won't get lightning as you place the last lava bucket, but you will get lightning when you place the sign on it.
Let me know if you pick up any other issues or if there's something else I can do to make the plugin work better for you :)
@CmdrDats
That's *exactly* what happened - that's why it didn't recognize the stone! I built mine that way. Might wanna warn people, because it's natural to build from the bottom up - if you make the smoothstone "base" then the obsidian "pillar" bottom to top, simply miss out one block on the base and place it last.
@hammerklavier
Whoops, I actually forgot that debug code in there.. i guess it doesn't make too much difference as sign changes aren't extremely common and this helps getting to the problem :)
Darn, I'm forever forgetting to update the version number. I'll get it fixed in the next version.
No worries - I learnt about the dynmap's awesome ability to make sign based map markers.. that's pretty neat :) I'm glad you managed to get it working! I wonder why it forgot the structure in the first place? :/
I've also noticed a bit of a bug when we make memory stones while exploring - we tend to find lakes of lava, ready a flow of water from the ceiling and plop buckets of lava underneath the stream. That turns it into instant obsidian, and the floor is already stone. Problem is that it gets placed as lava, so the mod doesn't pick up when it turns to obsidian, so you need to break out a stone corner and replace it for it to work..
I'm not sure that I'll be fixing this bug as I don't think it's that big a deal though :)
@CmdrDats
I've been a bit of a fool, I think. I was assuming it'd work on the new 1.8.1 bukkit even though your plugin description plain as day states 1060 (1.7.3). That's why it's not working, I'm pretty sure. I actually unloaded every plugin except for memorystone, and still no success creating a stone.
02:10:29 [INFO] [MemoryStone] Received sign change event 02:10:29 [INFO] [MemoryStone] Processing sign change event 02:10:36 [INFO] [MemoryStone] Received sign change event 02:10:36 [INFO] [MemoryStone] Processing sign change event
If I put a sign anywhere. I suspect this is debug code. But I like it, because it helps me test, too. :D
Am I doing something wrong with... actual usage of the plugin? I make a 3x3 square of smoothstone on the ground, and put a 3-high pillar of obsidian, then put a sign on the pillar? It's seeing me put signs up, the message confirms that it's catching the event. It just doesn't seem to want to make a memorystone out of the whole thing. Is it because of 1.8.1?
EDIT: Thanks for the shout out. :D Also, the plugin still identifies as 1.0.6a (FYI). Still fiddling with it, seeing if it's just not gonna work or if I'm messing something up...
EDIT2: OK, I destroyed two of the smoothstone at the base, then built them back on, and LIGHTNING! Built MemoryStone. *facepalm* Put sign on "Lighthouse", sign gets green bit on top, MEMORY STONE Lighthouse. Dangit, CmdrDats, I hope you didn't waste time trying to track this down. I'll actually, you know, get to testing it now. :x (But if that ever comes up again, with a very obviously perfect memorystone, a troubleshooting tip would be to have the user make sure the plugin's loaded, then destroy and replace a block on the stone to get the plugin's attention.)
EDIT3: I punch the sign on the stone the first time and it says it's memorized. I punch it again and I get: 03:23:26 [SEVERE] Could not pass event PLAYER_INTERACT to MemoryStone java.util.NoSuchElementException at java.util.TreeMap$PrivateEntryIterator.nextEntry(TreeMap.java:1098) at java.util.TreeMap$KeyIterator.next(TreeMap.java:1154) at za.dats.bukkit.memorystone.CompassManager.cycleTeleport(CompassManager.java:774) at za.dats.bukkit.memorystone.CompassManager.onPlayerInteract(CompassManager.java:703) at org.bukkit.plugin.java.JavaPluginLoader$11.execute(JavaPluginLoader.java:314) at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58) at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:338) at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:164) at net.minecraft.server.ItemInWorldManager.dig(ItemInWorldManager.java:86) at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:496) at net.minecraft.server.Packet14BlockDig.a(SourceFile:43) at net.minecraft.server.NetworkManager.b(NetworkManager.java:226) at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:91) at net.minecraft.server.NetworkListenThread.a(SourceFile:108) at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:464) at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:374) at net.minecraft.server.ThreadServerApplication.run(SourceFile:417)
Currently there are no other stones (yet), just making sure the nuts and bolts are present.
@hammerklavier
Good news - 1.0.7 is on its way with stone to stone teleporting :) File just needs approval, then you can try it out. Let me know if you manage to narrow down that bug of yours, if it's just a small fix, I'll release a 1.0.7a to fix it.
Ooh.. We didnt see the distancelimit. Will give that a go, and see what happens.
I'm new to all of this and my server host has been doing all my Mod management, so I'm not exactly sure how to replicate everything. If this doesnt work, then I'm going to have to explore my options for doing it myself, since he is relatively new to this himself.
Again, I do appreciate your help. This is an amazing mod.
@CmdrDats
Agreed - the way I describe it, it sounds like something you could do on accident or while not understanding how to use a memorystone. I don't have any good ideas for stone-to-stone + teleporting others :P
Hmm, I'll check on the troubleshooting after I get off work. Thanks a bunch.
@Eymberness
Oh dear - maybe check that you're not outside the distanceLimit defined in the structureTypes.yml, even with all memorized distanceLimit is still applied (you can set that to zero to make the distance infinite) - If that's not the problem, what exactly are you seeing happening, does it not work even on a totally fresh server? I need some help to reproduce the problem on my side, else I can't look into it :)
the distanceLimit is turning out to be quite a pain.. perhaps I need to make everything infinite distance by default..
@hammerklavier
Cool, thanks - fantastic feedback :) I'm kinda agreeing with you on the part where stone-to-stone mode isn't really compatible with teleporting others.. Your suggestions could work, but feels a bit too fickle - I think for now I'll just not implement teleporting others in stone-to-stone mode.
And yes, I avoid commands like the plague because I don't feel like it provides a very good playing experience. I find that if you just think about it more carefully, you can almost always come up with a more in-game kind of solution that feels right. Of course, some plugins are more admin oriented so commands are ok. I might add some commands, but they'll be very admin-natured.. like /destroyallstones or something..
One more thing, I've been trying to reproduce your sign creating issue with dynmap - they seem to work fine together.. Check the github issue - Could you try trim everything off your server and add plugins one by one till you see the problem again. I need to try isolate why this is a problem for you. You could even zip up your server setup and send it over to me if you like.
Hi.
memorystone.allmemorized : True
Isn't working for us.
I'm not sure why, but it's not.
Any tips?
@CmdrDats
Heh, at first I read through the comment and thought "Eh, the author doesn't like me thanklessly proposing major damn surgery on his cool plugin" - then I read it through two more times, and realized that you just very carefully wanted to quantify exactly how it would work. And you've totally done it. It's perfect.
Yes, this is perfect. The "teleport within vicinity" suggestion was, in retrospect, kind of half-ass on my part. It was just the only way I had it imagined. Yes: this stone-to-stone thing, combined with the possibility of removal of arbitrary teleportation, would make it perfect for my purposes.
With the stone-to-stone mode, it seems to me like maybe lightning should strike the stones rather than the person. Since the stone-to-stone mode kinda makes the memory stones themselves the important part, like they do all the "magic." Kinda thinking at random there, but that's just how I imagine it.
I've got to thank you. Thanks for thinking up my idea better than I did. :o Way to kick butt, seriously.
EDIT: I forgot about your question at the end! Truthfully it's not an option I intend to use, each teleport would be self-serve for my purposes so I hadn't thought about it. But I'm still thinking about it.
I'm actually not sure stone-to-stone mode is really compatible with teleporting others. Maybe you could just have it so if you struck a memorystone sign within the last 20 seconds, as though memorizing it, you have a temporary power to teleport someone to that stone as well? You'd have to use a /command unless you have an elegant way of picking out players the same way you pick teleport destinations. And it seems like you're avoiding /commands.
But maybe that's how you do it with stone-to-stone: You "memorize" a stone you've *already* memorized, and then you get a list of players instead (with spout) or cycle through all players with the click (without spout)... right-click again? Some kind of trigger. And bam, player is teleported there?
@hammerklavier
Cool - I've added a ticket for the sign fix with dynmap and the lightning effects :)
On the "teleporting only within a certain distance" suggestion - My feeling is that it just needs to be looked at from a broader perspective than just plopping in a quicky to avoid having the plugin shard from its purpose.
That said, it seems that it will be a good option to have so - so here's my suggestion:
How does that sound? Remember, don't think 'oh dear, that might be lot of work' - rather think 'how would I ideally like this to work, and does that fit the feel of this mod'. The reason I push back is not because I don't want to do the work, but because I want the idea fleshed out so it can be implemented well :)
The one hole this does have is that I can't think of a clean way to teleport another person to a location that I've memorized, but my friend hasn't - Ideas?