GetEffectDensity: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
mNo edit summary |
||
(One intermediate revision by one other user not shown) | |||
Line 15: | Line 15: | ||
===Example=== | ===Example=== | ||
<syntaxhighlight lang="lua"> | |||
<syntaxhighlight lang="lua"> | |||
addCommandHandler("ses", | addCommandHandler("ses", | ||
function (cmd) | function (cmd) | ||
Line 26: | Line 25: | ||
end) | end) | ||
</syntaxhighlight> | </syntaxhighlight> | ||
==See also== | ==See also== | ||
{{Client_Effects_functions}} | {{Client_Effects_functions}} | ||
[[ru:getEffectDensity]] | [[ru:getEffectDensity]] |
Latest revision as of 13:55, 7 May 2017
This function gets the density of certain effect.
Syntax
float getEffectDensity ( effect theEffect )
OOP Syntax Help! I don't understand this!
- Method: effect:getDensity(...)
- Variable: .density
- Counterpart: setEffectDensity
Required Arguments
- theEffect: The effect to get density of.
Example
addCommandHandler("ses", function (cmd) local density = 4 local x, y, z = getElementPosition (localPlayer) local effect = createEffect ("cement", x, y, z) setEffectDensity (effect, density) getEffectDensity (effect) end)