Unreal Engine/GAS

GameplayEffect

SB_J00N 2024. 3. 13. 17:20

참고 강의 및 문서

https://www.udemy.com/course/unreal-engine-5-gas-top-down-rpg/?couponCode=ST15MT31224

https://github.com/tranek/GASDocumentation

 

GitHub - tranek/GASDocumentation: My understanding of Unreal Engine 5's GameplayAbilitySystem plugin with a simple multiplayer s

My understanding of Unreal Engine 5's GameplayAbilitySystem plugin with a simple multiplayer sample project. - tranek/GASDocumentation

github.com

https://docs.unrealengine.com/5.1/en-US/gameplay-ability-system-for-unreal-engine/

 

Gameplay Ability System

High-level view of the Gameplay Ability System

docs.unrealengine.com

 

주의

틀린 내용이 있을 수 있음.

 

Gameplay Effects(GE)를 통해 GAS에서자기 자신, 다른 플레이어, 적 엑터등이 보유한  Attribute와 Tag를 변경할 수 있다. 

예시 :

데미지를 받은 액터의 HP를 깎는 등의 Attribute의 base value를 직접적으로 변경한다. 

몇초 동안 이동 속도를 높히는 등의 일시적인 변화(버프, 디퍼드)를 일으킨다. 

몇 초에 걸쳐(또는 무기한) 초당 특정 양의 마나를 재생등의 시간이 지남에 따라 적용되는 지속적인 변경등.

 

-UGameplayEffect

UGameplayEffect class는 데이터 전용 클래스로서 단 하나의 GE를 정의한다.

GE에는 추가적인 로직이 추가되면 안되며, UGameplayEffect의 자식 클래스로 다수의 GE를 만든다.

 

GE는 'Modifiers'와 'Executions'를 통해 Attributes를 변경한다.

 

GE는 Instant, Duration, Infinite라는 3개의 지속 시간 유형이 있다.

Duration Type
(지속 시간 유형)
GameplayCue Event When to use
Instant Execute Attribute의 BaseValue를 즉시 영구적으로 변경한다.
GameplayTag는 단 한 프레임도 적용되지 않는다.
Duration Add & Remove Attribute의 CurrentValue를 일시적으로 변경한다. 
GameplayTag를 적용하며 GE가 만료되거나 수동으로 제거할 때 제거된다.
지속시간은 블루프린트/UGameplayEffect 클래스에서 정할 수 있다.
Infinite Add & Remove Attribute의 CurrentValue를 일시적으로 변경한다. 
GameplayTag를 적용하며 GE가 제거될 때 제거된다.
Ability 또는  ASC에 의해 수동으로 제거되지 않는 한 만료되지 않는다.

GE GameplayCue를 추가/실행할 수 있다.

Instant GE는 GameplayTag, GameplayCue의  Execute를 호출 할 수 있지만,

Duration, Infinite GameplayEffect Add / Remove를 호출할 수 있다.

 

 

- Periodic

 

- Applying Gameplay Effects

 

- Removing Gameplay EFfects

 

- Gameplay Effect Modifiers

 

... 작성중