[Help] How do I add effects such as Wither to weapons for AoD maps?

Natsu

The Flaming Dragon Op
Joined
Nov 4, 2012
Messages
321
Reaction score
293
Points
63
I'm making a map with some other players, and I'd like to know how to add wither effects/poison effects to weapons, if it's possible. All help will be much appreciated! :D

Guinessis


Sorry for tagging you Guin, I just thought you might know something on this.
 

LISTINGS09

Ain't afraid of no ghost
Joined
Aug 6, 2011
Messages
366
Reaction score
606
Points
93
Website
www.4thdp.com
  • Agree
Reactions: Guinessis

Jivvi

Member
Mafia Host
Joined
Jun 9, 2012
Messages
2,769
Reaction score
4,596
Points
138
I don't think you can; those are potion effects.
This.
I don't think you can; those are potion effects.
It's been done before on a different server - I am sure of the effects.
Though, it may require extra coding, so, we may not be able to do this.
This is done on many a HG server; kits may include a Viper, and when they hit someone with their swor, the target is poisoned. Likewise, some kits can throw fire charges as ghast fireballs. The thing is, the items aren't actually affected; the kits are. Someone who grabs a Pirate's firecharges can't blast them, nor poison with a viper's sword. More evidence is that the Thor kit (which entails hitting the ground with an axe to spawn lightning) still works of your axe breaks and you craft another. This setup works nicely for the little Hunger Games servers that they're used on, as they're simple, and cater for the simple needs of the game.

Edit: Ninja'd by Listings, who better explained it in less loopy literature, and even has a solution. I completely forgot about the OnAttack and OnDefend effects
:roflmao:
 

Guinessis

Member
Joined
Aug 6, 2011
Messages
367
Reaction score
594
Points
93
If you're fine with all hunters/all survivors having the weapon ability, you can use the OnAttack or OnDefend potion effects as described by LISTINGS - they may be expanding the options for enchanted weapons in the future, but right now you'll need another plugin to do what you're describing.
 
Joined
May 8, 2012
Messages
85
Reaction score
55
Points
18
If command blocks are enabled you could use them to check if someone is given fire damage (this would require making only one source of fire damage though), and giving someone wither instead of fire. You could also have it check for a specific potion effect (waterbreathing? Night vision? haste?) and give someone wither if they have that effect. Then you could give hunters/survivors/chests a waterbreathing splash, and let them use it to poison people :p
 

Rytheria

Member
Joined
Sep 1, 2013
Messages
84
Reaction score
119
Points
33
You can however set 'on hit' potion effects, which will occur when a player is hit... You can't however restrict this to a weapon, or anything fancy like that.

Is it possible to restrict this to a certain kit..?
Or... Is it only possible to give every player on the server this ability?
 

Jivvi

Member
Mafia Host
Joined
Jun 9, 2012
Messages
2,769
Reaction score
4,596
Points
138
You can however set 'on hit' potion effects, which will occur when a player is hit... You can't however restrict this to a weapon, or anything fancy like that.

Is it possible to restrict this to a certain kit..?
Or... Is it only possible to give every player on the server this ability?
Nop, sadly
(I tried :()
 

LISTINGS09

Ain't afraid of no ghost
Joined
Aug 6, 2011
Messages
366
Reaction score
606
Points
93
Website
www.4thdp.com
You can however set 'on hit' potion effects, which will occur when a player is hit... You can't however restrict this to a weapon, or anything fancy like that.

Is it possible to restrict this to a certain kit..?
Or... Is it only possible to give every player on the server this ability?
Only per side on the server. Either all hunters have it, or all survivors have it.
 

S_swimmer

The Speedo
Joined
Mar 24, 2012
Messages
958
Reaction score
1,107
Points
93
The new commands on Buildbox would most likely allow this. They're only for Op+ for the time being, but seeing as you ARE Op on Buildbox, I don't think that matters. :p
 

Fiestaguy

The man with 8 fingers.
Joined
Sep 11, 2013
Messages
2,197
Reaction score
1,643
Points
138
Website
thebes.openshells.net
This is not possible, With 2 exceptions only for the HOLDER of the weapon,
These 2 are:
Swiftness (generic.movementSpeed)
And Health Boost (generic.maxHealth)
These can be applied by using 3rd party tools like NBTedit, In-game NBTedit (Recommended) And NBTExplorer.
These are the Attribute System from 1.6. Tough currently it is impossible to add potion effects to weapons that affect the enemy "On-Hit" As you describe it.
Other 2 attributes are:
Knockback resistance (Decides how much you negate knock back) (generic.knockbackResistance)
and Following Range, (Decides from how far away hostile mobs can spot you) (generic.followingRange)
These can be applied using NBTedit, Unless you're an OP/Administrator on BuildBox these need to be applied in SinglePlayer, You can always PM me to do this for you tough.


You might want to check out mcedit, maybe you can find there what you require
MCedit just includes a cheap NBTedit spin-off.
It does come down to using NBTedit again.