Add a damage parameter to Lua OnDamage callback

This commit is contained in:
Curtis Shmyr
2020-06-22 12:25:21 -06:00
committed by abcdefg30
parent fea35923f0
commit 3c7f119bb1
2 changed files with 3 additions and 2 deletions

View File

@@ -118,7 +118,8 @@ namespace OpenRA.Mods.Common.Scripting
try
{
using (var b = e.Attacker.ToLuaValue(f.Context))
f.Function.Call(f.Self, b).Dispose();
using (var c = e.Damage.Value.ToLuaValue(f.Context))
f.Function.Call(f.Self, b, c).Dispose();
}
catch (Exception ex)
{