StrangeWeapons
StrangeWeapons
History
When the ability to give items custom names and descriptions was added to the 1.4 snapshot, the Minecraft subreddit was flooded with various mockups of weapons from other games, such as Borderlands 2 brought into Minecraft. I saw this as an opportunity to make strange weapons from TF2.
Features
- Strange Weapons!
- Can be created out of any item or block.
- Can have custom names.
- Can have custom descriptions.
- Can track any number of statistics.
- Steve Co. Supply Crates
- Opened with Steve Co. Supply Crate Keys
- Customize crate contents
- Give a user a random item (from what you specified) when uncrated
- Strange Parts
- Craft these with strange weapons to make them track additional statistics!
- Name Tags
- Use the /tag command to pick a name, and then craft it with a strange weapon!
- Description tags
- Use the /tag command to pick a description, and then craft it with a strange weapon!
How This Plugin Works
Read this if you are confused This plugin aims to duplicate the item and drop systems that are built into TF2. This plugin has nearly all of the same items, strange weapons, name tags, description tags, crates, and keys as TF2 does. It also has a random drop system to go along with it.
What are all these items?
- Strange Weapons is a weapon that tracks a number of statistics, changes it's name based on the value of the primary (first) statistic, and can have a custom name or description.
- Name Tags can be crafted together with a strange weapon to apply the name set with the /tag command.
- Description Tags can be crafted together with a strange weapon to apply the description set with the /tag command.
- Strange Parts are items that can be crafted with a strange weapon to track additional statistics.
- Steve Co. Supply Crates are specially designated crates which contain an item. Crafting this with a Steve Co. Supply Crate Key will open the crate and reveal the item inside. The contents of all crates must be customized with items and their drop weights.
- Steve Co. Supply Crate Keys are specially designated blaze rods which are crafted with Steve Co. Supply Crates to open the crates. Initially, the crafting will only show a "Mystery Item" in the result slot, but as soon as you click on it to uncrate it will change to the real result. See this image for more details.
Suggested Uses
- Reward players for spending time playing on your server.
- Put strange weapons into crates and let crates drop for players. Then sell keys in an admin store, give them as rewards for voting for your server, or as gifts for donations.
- Competitions to see who can kill the most cows, do the most damage, etc in a set period.
The Random Drop System
- By default, players are limited to 9 item drops every week. When a player joins the server for the first time (or after any scheduled drop), the plugin will roll to determine when they should receive a drop. By default, drops happen every 30 to 70 minutes if the player has not hit the drop limit.. Just like TF2 though, if a player does not claim all of one week's drops, those drops will rollover to the next week. (This makes the limit actually 18 items every two weeks.) The items which drop can be configured with custom weight. (See the
/drops
command.) If a player has a full inventory, they will not receive a drop, instead they will be reminded that they need to have an open space in their inventory and the drop will be rescheduled. If you have admins on your server who are frequently vanished doing secret admin stuff, you can give them the permissionstrangeweapons.drop.announceexempt
and their drops will only be announced to them personally. Should you not want a player to receive drops at all, you can revoke thestrangeweapons.drop.dropitems
andstrangeweapons.drop.dropcrates
permissions. Speaking of crates, the crate drop system works exactly like the item drop system, except that it runs on a seperate timer with separate limits. (Default 3 crates per week.)
REMINDER: If you want support, have found a bug, etc, FILE A TICKET. I cannot properly give support in the comments section.
@PlantAssassin
Super-duper awesome plugin!
Strong Suggestion: add ability to change the descriptions on chests and keys.
(I want it to say you can get Steve co supply crate keys blah blah blah, instead of the Steve co store.)
@Rhinoceros_0123
thanks!
@jitasi
I found that deleting and redoing all the config helps to fix this
Please Help
2013-01-27 21:21:37 [WARNING] [StrangeWeapons] Task #2072 for StrangeWeapons v0.5.2 generated an exception
java.lang.IllegalArgumentException: n must be positive
at java.util.Random.nextInt(Unknown Source)
at to.joe.strangeweapons.datastorage.PlayerDropData.rollItem(PlayerDropData.java:84)
at to.joe.strangeweapons.datastorage.PlayerDropData.<init>(PlayerDropData.java:31)
at to.joe.strangeweapons.datastorage.YamlDataStorage.getPlayerDropData(YamlDataStorage.java:156)
at to.joe.strangeweapons.StrangeWeapons$1.run(StrangeWeapons.java:164)
at org.bukkit.craftbukkit.v1_4_R1.scheduler.CraftTask.run(CraftTask.java:53)
at org.bukkit.craftbukkit.v1_4_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:345)
at net.minecraft.server.v1_4_R1.MinecraftServer.r(MinecraftServer.java:530)
at net.minecraft.server.v1_4_R1.DedicatedServer.r(DedicatedServer.java:224)
at net.minecraft.server.v1_4_R1.MinecraftServer.q(MinecraftServer.java:494)
at net.minecraft.server.v1_4_R1.MinecraftServer.run(MinecraftServer.java:427)
at net.minecraft.server.v1_4_R1.ThreadServerApplication.run(SourceFile:849)
Hi! Amazing plugin! One request:
Could you by any chance add potion effects to the weapons if possible? Such as, holding a certain strange weapon applies Strength to you?
Is that by any means possible?
Not to spam you some more, but Im also getting a warning that says Task #9 generated an exception in your strange weapons class on line 172. (map.put(i.getItemStack("item"), i.getDouble("weight"));) I dont see anything wrong with your code in the run method, but it has something to do with the scheduler and the exception is generated every minute on the dot.
Hey Plant, could you add Scrap, Reclaimed and Refined metal to the plugin? And make a random gear using 3 Refined metal just like TF2. That would be great :D
Hi, I've also found that once you unbox an item, you can continually unbox items if you keep on clicking on it with the item sill being held. I haven't found this to be exploitable in any way, but it just overloads the database full of stuff that is quite hard to pick out and delete.
EDIT: This seems to be bugging out when I usethis plugin as well. It makes an AI quit the game which throws up some interesting errors
Great Plugin, Just A Question & 2 requests!
What does leveling up a sword do?
Can you please do the following, they are essential to being able to sell these
1. Add a command that allows me to do something like
/newkey <amount> <player> /newcrate <amount> <player>
2. Please allow me to type these commands from the server side, it is essential for using this on buycraft
If these things could happen, my mouse may somehow fall upon the donate button
Hi plant.
The auto spawning do not seem to be working.
would you please have a look in my configs to see what have happened?
the only way for me to use this plugin right now, is spawning in the crates and giving out the drops.. :-/
http://thelegendofminecraft.com/strange/config.yml http://thelegendofminecraft.com/strange/drops.yml http://thelegendofminecraft.com/strange/weapons.yml
@beyonddead
Very odd. I'll go poking around in the code. I know there was an issue where if you changed the strange item that went into a crate, it would affect items created later, but I'm pretty sure that was fixed.
Hey Plant,
I also tested it with crates and one player unboxed a Strange Diamond Sword, renamed it to "Muramasa" with a name tag.
After a short while, someone unboxed the Muramasa as well.
A video tutorial with this would be great!
@_creeperdude_
/crates newcrate doesn't take any arguments. You can't pick what series of crate to make, you just get the next in line.
@Rhinoceros_0123
You need to set crateDropRollMaxTime and crateDropRollMinTime. It picks a random number of minutes in between those two values for the next drop.
I might be able to make some default configs.
Kills on bows seem to work, damage does not. I will fix this shortly.
@PlantAssassin Hey, would it be possible for you to add a way to change how often the crates are dropped? I couldn't find a way to edit it in the config. And, any chance of throwing in some premade configs because I would have really liked something to work off of instead of having to enchant and edit all the tools myself. Also, can you add any way for it to detect damage or kills with a bow? I'd really like to add a Strange Bow to some crates
Hey! I`m Making This Comment Beacause, i Type /crates newcrate 5 and it just puts up the help menu for crates Please Help
- Creeper
@PlantAssassin
Plant, do you think you could do something like this? Every blaze rod with a certain damage value (IE, 1337, so the item ID would be 369:1337. By the way, hopefully this is configurable) is turned into a key? This would allow you to create shop signs and sell them, allow donators to obtain them by spawning them, etc. I don't think it is really possible to obtain a blaze rod with a different damage value, so you couldn't cheat for keys. Also, you could do the same with crates; 54:11 could be crate series 1, (because I believe damage value 1 is default? If I'm wrong, then you could have 54:1 for series 1) and 54:12 for series 2, and so on. It would basically be if an item of either chest or blaze rod is spawned with that damage value, it is turned into a key or the correct series chest? Thanks for reading my suggestion!
EDIT === : Just did some testing in my server; when a chest with a different damage value is spawned, it is quickly reverted back to the default damage value. However, this could still be used because as soon as a chest with the plugin-specific damage value is spawned, then you could have it change to the crate. Blaze Rods are persistent, as in they keep their damage value. A 369:2 and 369:1 blaze rod look the same, are named the same, but do not stack due to their different damage values. I hope this information is useful to you, and perhaps allows you to implement my suggestion.
I just uploaded v0.5.2 for approval. I fixed a whole bunch of bugs that have been occurring, and added an option for strange items to be unbreakable. Set
durability
to false and all strange items will no longer take damage when they are used. Keep in mind though that people will be able to enchant these weapons to have invincible god swords, so don't screw up gameplay on your server.@Overthetop413
99% chance this plugin doesn't like reload. Restart your server.
@beyonddead
To get the probability of any drop, divide the weight for that drop by the total of all weights. Here is an example. Let's say you have 3 items in your crate. A block of dirt that you want to drop frequently. An iron ingot that you want to drop infrequently. And a diamond that you want to be super rare. We can set the weight of the diamond to 1, the weight of the iron to 5, and the weight of the dirt to 20. This means that the diamond will drop about 1/(1+5+20)=3% of the time, the iron will drop about 5/(1+5+20)=19% of the time, and the dirt will drop about 20/(1+5+20)=76% of the time. Higher numbers mean a bigger chance to drop, but it's all relative.
As for the not being able to add parts, I just fixed that so it will be in the next version.
@beyonddead
If you want to make a video explaining all of this, send me a pm and we'll talk.
@diannetea
Unless they are messing around in the internals (which they shouldn't be doing) and they don't have some unique identifier attached (like my weapon ids), there is no reason that you can't add other special items to the crates. The will come out exactly as you put them in.
@beyonddead
See the ticket, but items will come out exactly as you put them in. So if you add a weapon to the crate with kills already recorded, they will come out that way.