I think setting a score for the ingredients item entity then execute on all of them to summon the weapon item and then kill the ingredients should work
You can also check other one command creation as they usually have floor crafting
Unless you want to use a lot of commands to select each mob, here is a simple(r) way to do it.
First, add a new dummy objective (in this case i name it Mob) (/scoreboard objectives add Mob dummy)
Then, put this in a repeating command block: scoreboard players set @e[type=!Player] Mob 1 {Attributes:[{Name:"generic.knockbackResistance",Base:0.0d}]}
Since only mobs and players have attributes and the default knockback resistance is 0 for all entity, this will track all mobs.
0
If you want more op stuff, i suggest adding attributes to them. Potion should have their damage tag being 0 to display texture properly.
Also, use levitation on your negative potion
e.g. of attributes on swords:
/give @p minecraft:diamond_sword 1 0 {display:{Name:Lucky Sword,Lore:[Made in Vietnam]},Unbreakable:1,ench:[{id:16,lvl:10},{id:17,lvl:10},{id:18,lvl:10},{id:19,lvl:10},{id:20,lvl:10},{id:21,lvl:10}], AttributeModifiers:[{Slot:"mainhand",AttributeName:"generic.attackDamage",Name:"generic. attackDamage",Amount:1000000000,Operation:0,UUIDLeast:1,UUIDMost:1},{Slot:" attackSpeed",AttributeName:"generic. attackSpeed",Name:"generic.armor",Amount:1000000000,Operation:0,UUIDLeast:1,UUIDMost:1},{Slot:"mainhand",AttributeName:"generic.armor",Name:"generic.armor",Amount:1000000000,Operation:0,UUIDLeast:1,UUIDMost:1},{Slot:"mainhand",AttributeName:"generic.maxHealth",Name:"generic.maxHealth",Amount:1000000000,Operation:0,UUIDLeast:1,UUIDMost:1}]}
p/s : works on 1.9 (this and your command)
0
/execute @a x y z spawnpoint to set their spawn with x, y and z being the coordinates
0
use this: testforblock 1675 53 -2 chest -1 {Items:[{Slot:0b}]} then invert the output signal
0
I think setting a score for the ingredients item entity then execute on all of them to summon the weapon item and then kill the ingredients should work
You can also check other one command creation as they usually have floor crafting
0
You're right, that does reduce the lag significantly. Thanks!
(I'm using this to make a snowman cannon (if you play terraria))
0
To make long story short, just use anything that only mobs have as a criteria.
Also, i don't think targeting to many entities is a big problem
1
Unless you want to use a lot of commands to select each mob, here is a simple(r) way to do it.
First, add a new dummy objective (in this case i name it Mob) (/scoreboard objectives add Mob dummy)
Then, put this in a repeating command block: scoreboard players set @e[type=!Player] Mob 1 {Attributes:[{Name:"generic.knockbackResistance",Base:0.0d}]}
Since only mobs and players have attributes and the default knockback resistance is 0 for all entity, this will track all mobs.
Hope this helped
0
In a mob data tag, there are attribute modifier. Players (and mobs) attributes can be modified by items. For example, a sword has a part that says:
"When on main hand:
N1 Attack damage.
N2 Attack speed
The AttributeModifier tags works like this:
AttributeModifier:[{A1},{A2},...,{AN}] where N is any number. N doesn't really matter.
the AN part has this format:
{Slot:"S1",AttributeName:"S2",Name:"S3",Amount:S4,Operation:S5,UUIDLeast:S6,UUIDMost:S7}
Where:
S1 is one of these: mainhand, offhand, head, chest, legs or feet. If not specified, will apply to all of those slot.
S2 doesn't exactly matters, but should be the same to S3
S3 is one of these:
generic.maxHealth : kind of obvious, modify max health (in half hearts). Not to be confused with your actual health
generic.followRange : on mobs only. How far mobs will track you in blocks
generic.knockbackResistance : chance to resist knockback, 1.0 = 100%
generic.movementSpeed: modify speed in unknown way
generic.attackDamage : also self explanatory, modify attack damage (like the stuff on swords)
generic.armor : modify armor point (in half armor)
generic.armorToughness : new in 1.9.1, with the new damage formula: damage = damage * ( 1 - max( defensePoints / 5, defensePoints - damage / ( 2 + toughness / 4 ) ) / 25 ), 2 on diamond, 0 on everything else by default
generic.attackSpeed: The attack speed on swords and weapons
generic.luck: Affects the loots in chests and fishing
horse.jumpStrength: Horse only. How high horses jump (in unknown way)
zombie.spawnReinforcements: Chance of spawning another zombie when attacked 1.0 = 100%
S4 is how much you want it to be, with S5 operation
S5: either 1, 2 or 0
0 is adding S4
1 is adding the original one with S4%
2 is multiplying the original one with S4%
S6 and S7:
Identifiers that basicly chose how modifiers stack.
different moddifiers (S3) doesn't get affected by this
same moddifiers and same range in S6 and S7 means that the highest modifier will kick in
same moddifiers and different range in S6 and S7 means that they will stack (like the armor point in normal armor)
Example:
/give @p minecraft:diamond_sword 1 0 {AttributeModifiers:[{Slot:"mainhand",AttributeName:"generic.attackDamage",Name:"generic. attackDamage",Amount:1000000000,Operation:0,UUIDLeast:1,UUIDMost:1},{Slot:" attackSpeed",AttributeName:"generic. attackSpeed",Name:"generic.armor",Amount:100000000000,Operation:0,UUIDLeast:1,UUIDMost:1},{Slot:"mainhand",AttributeName:"generic.armor",Name:"generic.armor",Amount:1000000000,Operation:0,UUIDLeast:1,UUIDMost:1},{Slot:"mainhand",AttributeName:"generic.maxHealth",Name:"generic.maxHealth",Amount:1000000000,Operation:1,UUIDLeast:1,UUIDMost:1}]}
This sword will give you +1000000000 damage, +100000000000 attack speed, +1000000000, and +1000000000% health (in half hearts)
0
Tip: you can remove the "when on" part with the slot tag in Attributes