mirror of
https://github.com/OpenMW/openmw.git
synced 2025-12-25 05:53:09 +00:00
make it possible to remove anonymous vfx
This commit is contained in:
parent
9524906768
commit
647d655f2e
2 changed files with 1 additions and 3 deletions
|
|
@ -294,8 +294,6 @@ namespace MWLua
|
|||
api["remove"] = [context](std::string vfxId) {
|
||||
context.mLuaManager->addAction(
|
||||
[vfxId = std::move(vfxId)] {
|
||||
if (vfxId.empty())
|
||||
throw std::runtime_error("vfxId is empty");
|
||||
MWBase::Environment::get().getWorld()->removeEffect(vfxId);
|
||||
},
|
||||
"openmw.vfx.remove");
|
||||
|
|
|
|||
|
|
@ -210,7 +210,7 @@
|
|||
---
|
||||
-- Remove all VFX with the given vfxId. Best invoked through the RemoveVfx global event
|
||||
-- @function [parent=#VFX] remove
|
||||
-- @param #string vfxId the vfxId of the VFX to remove.
|
||||
-- @param #string vfxId the vfxId of the VFX to remove. Passing an empty string removes all VFX that don't have a vfxId
|
||||
--
|
||||
-- @usage -- Remove all VFX with vfxId "myvfx"
|
||||
-- core.sendGlobalEvent('RemoveVfx', "myvfx")
|
||||
|
|
|
|||
Loading…
Reference in a new issue