Table of Contents

Class EffectSystem

Namespace
Framework.Systems.Effect
Assembly
Assembly-CSharp.dll

IEffectSystem 구현체. ObjectPool<EffectView> 기반 이펙트 재사용.

public class EffectSystem : IEffectSystem
Inheritance
object
EffectSystem
Implements

Remarks

이펙트 키별 Pool은 Scope 구성 시 RegisterPool로 등록해야 한다. Play 시 활성 목록(_active)에 추가하고, 완료/ForceStop 시 자동 제거. Dispose(씬 언로드)시 StopAll로 활성 이펙트 전체 정리.

Constructors

EffectSystem(ILogSystem)

public EffectSystem(ILogSystem log)

Parameters

log ILogSystem

Methods

Dispose()

public void Dispose()

Play(string, Vector3, Quaternion)

지정 위치에 이펙트 재생. Pool에서 EffectView를 꺼내 활성화.

public void Play(string key, Vector3 position, Quaternion rotation = default)

Parameters

key string

이펙트 키 (EffectKeys 상수 사용).

position Vector3

재생 월드 위치.

rotation Quaternion

재생 회전. 기본값은 Quaternion.identity.

RegisterPool(string, IObjectPool<EffectView>)

이펙트 키별 Pool 등록. Scope의 RegisterBuildCallback에서 호출.

public void RegisterPool(string key, IObjectPool<EffectView> pool)

Parameters

key string

이펙트 식별 키.

pool IObjectPool<EffectView>

해당 키의 ObjectPool.

Stop(string)

해당 키의 활성 이펙트 중단.

public void Stop(string key)

Parameters

key string

중단할 이펙트 키.

StopAll()

모든 활성 이펙트 강제 중단 및 Pool 반환.

public void StopAll()