글의 요약 설명 부분. 150자를 적어주세요. 글의 요약 설명 부분. 150자를 적어주세요. 글의 요약 설명 부분. 150자를 적어주세요. 글의 요약 설명 부분. 150자를 적어주세요. 글의 요약 설명 부분. 150자를 적어주세요. 글의 요약 설명 부분. 150자입니다

 

목차

     

     


     

    인프런 Rookiss님의 '언리얼 엔진 2D 게임' 강의를 기반으로 정리한 필기입니다. 
    😎[입문자를 위한 UE5] Part2. 언리얼 엔진 2D 게임 개발 입문 강의 들으러 가기!

     

     

     

    게임 콘텐츠

     

     


    Monster Spawn

     

    BP_Creature

    Set Destination

    • TileMap의 Y좌표값 = 0.0
    • Player/Monster Y좌표값 = 500.0
    • 따라서 Get Actor Location으로 Y값을 지정.
    • Capsule Component - Collision - Collision Presets - Pawn->No Collision으로 변경 = 플레이어와 몬스터 충돌x

     

    BP_TileMap

    GetRandomEmptyGrid, SpawnCreature 함수 생성

     

    GetRandomEmptyGrid

    • GetRandomEmptyGrid 함수 생성
    • EGridPos 타입의 Output - GridPos 생성

     

    SpawnCreature

    • SpawnCreature 함수 생성
    • BP_Creature - Class Reference 타입의 Input - Class 생성

     

    Event Graph

     

     

    실행화면


     

    Unit Collision

    타일맵 한칸 한칸 이동으로 수정한다.

     

    BP_Creature

    Process Attack 수정

     

     

    BP_TileMap

    Spawn Creature

     

    Get Creature at Grid Pos

     

    CanGo 수정

     

     

    실행화면

     


     

    몬스터 AI

     

    BP_Monster

    Event Graph

    • BP_Monster - Class Defaults - Pawn - Auto Process AI - Placed in World or Spawn 수정

     

     

    Update Destination

     

     

     

    BP_AIController 

    Event Graph 수정

     

     

    Update AI

    수정 전

    수정 후

     

     

     

    BP_Creature

    Get Tile Count Target

     

    Look at Target

     

    Update Destination

     

    실행화면

     

     


     

    Monster Despawn

     

    BP_TileMap

    Despawn Creature함수 생성

     

    Despawn Creature

     

     

     

    BP_Creature

    OnDead 함수 생성

     

    OnDead

     

    OnDamaged 수정

     

     

    실행화면

     

     


     

     

    Kill Count

     

    WBP_GameUI

    • User Interface - Widget Blueprint - WBP_GameUI 생성

    • KillCount 변수 생성

    • TextBlock 생성 - Content - Text - Bind 누른 후 Create Binding 클릭

     

     

     

     

     

    BP_TileMap

    Event Graph

     

     

     

    BP_Creature

    On Dead

     

    On Damaged

     

     

     

     

    실행화면