MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / removeUniqueEffect

Method removeUniqueEffect

source/game/StarStatusController.cpp:742–755  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

740}
741
742void StatusController::removeUniqueEffect(UniqueStatusEffect const& effect) {
743 auto& uniqueEffect = m_uniqueEffects[effect];
744
745 uniqueEffect.script.invoke("onExpire");
746
747 uninitUniqueEffectScript(uniqueEffect);
748
749 m_uniqueEffectMetadata.removeNetElement(uniqueEffect.metadataId);
750
751 if (uniqueEffect.animatorId != EffectAnimatorGroup::NullElementId)
752 m_effectAnimators.removeNetElement(uniqueEffect.animatorId);
753
754 m_uniqueEffects.remove(effect);
755}
756
757void StatusController::initPrimaryScript() {
758 m_primaryScript.addCallbacks("status", LuaBindings::makeStatusControllerCallbacks(this));

Callers

nothing calls this directly

Calls 3

removeNetElementMethod · 0.80
invokeMethod · 0.45
removeMethod · 0.45

Tested by

no test coverage detected