event:-unit is attacked
condition:unit type of attackING unit equal to (...)
action:if then else:
if:random number between 1 and 100 less or equal to 10
then:-create 1 dummy for owner of attacking unit at psition of attacking unit
-add 3 sec generic experation timer
-create 1 item illution(wand of illution)
-give last create item to last created unit
(give the dummy unit the ability hero inventory before)
-order last created unit to use last created item on attacking unit.
A dummy unit is a unit with no model or attack
you can give item to dummy or ability (make sure to make the ability unit ability, and mana cost 0, if you want to give the dummy item, make sure he can carry items and dont drop them and can use them)