Code: Select all
ping = OnObjectDamage(function(object, damager)
if GetObjectLastHitWeaponClass(object) == "cis_weap_inf_wrist_rocket" then
CreateEntity("com_item_null", CreateMatrix(3.14159,0,1,0,0,0,1,GetEntityMatrix(GetCharacterUnit(object))), "ping")
MapAddEntityMarker(ping, "hud_objective_icon", 5.0, 1, "BLUE", true, true, true)
end
end)
Code: Select all
Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LuaHelper.cpp(312)
CallProc failed: bad argument #1 to `GetCharacterUnit' (number expected, got userdata)
stack traceback:
[C]: in function `GetCharacterUnit'
(none): in function <(none):25>






