Client Side
addEventHandler("onClientPlayerDamage",getRootElement(),function(attacker) if attacker then cancelEvent() end end)
Server Side
addEventHandler("onPlayerDamage",getRootElement(),function(attacker) if attacker then cancelEvent() end end)
Meta
<meta>
<script src="client.Lua" type="client" />
<script src="server.Lua" type="server" />
</meta>