sm.melee
A melee attack represents a physical close-range attack performed by a Player or Unit.
An example of this is hitting something with the standard Sledgehammer tool that is available to the player by default.
Functions
meleeAttack
sm.melee.meleeAttack(name, damage, origin, directionRange, source, delay, power)
Launches a melee attack.
Parameters:
name(string/Uuid): The name or UUID of the attack. (nameis deprecated, use uuid instead)damage(int): The damage the attack will inflict.origin(Vec3): The position of the attack.directionRange(Vec3): The direction and range of the attack.source(Player/Unit): The source of the attack.delay(int): The number of ticks before launching the attack.power(number): The knockback power.