I tested in Freya L2jServer, and nothing happen, the guard stay normal :S. When i compile it i dont have any error.
Can u give us a normal datapack whit this script please?, a lot of us don't know how to compile successfully a datapack.
I'll w8 ur answer.
PD: Sry 4 my broken english D:.