[2.0.5] Entity damage has weird parameters
Posted: Fri Oct 18, 2024 8:19 am
/doc-html/classes/LuaEntity.html#damage
This indicates type is optional and has a default, yet can't be nil?
I'm assuming this was intended to make `type` optional in the parameter list though it is somewhat unclear on that. Also if type is optional, the following should still be valid:
`p.damage(1, "player", "electric", p, p)` however this results in the error: Expected between 2 and 4 argument but 5 were given.
This could use some clarification on valid parameters.
This indicates type is optional and has a default, yet can't be nil?
I'm assuming this was intended to make `type` optional in the parameter list though it is somewhat unclear on that. Also if type is optional, the following should still be valid:
`p.damage(1, "player", "electric", p, p)` however this results in the error: Expected between 2 and 4 argument but 5 were given.
This could use some clarification on valid parameters.