Testing Brian Walker NPC

This commit is contained in:
Rafal Swierczek 2024-05-13 16:27:48 +01:00
parent 528e317961
commit 6fed85d705
12 changed files with 28 additions and 10 deletions

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:7022e27e25fda8ba4a23532e859892230abd46e20d24649cfc8da021e30c098f oid sha256:011ecbcd4df831b26edee3e1b440096c2c60eb574371821b39e80c6fcab58f2b
size 45628665 size 45629656

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5a101c3c9bfab060172001002e86dda86ba1014498de7778bd4810711488df11
size 42784

View File

@ -16,7 +16,7 @@ FVector ANPC_WalkerClass::UpdateWalkingTarget()
int BoundsCheck = WalkingSpotIndex + Polarity; int BoundsCheck = WalkingSpotIndex + Polarity;
if (BoundsCheck < 0 || BoundsCheck >= WalkingSpots.Num()) Polarity *= -1; if (BoundsCheck < 0 || BoundsCheck >= WalkingSpots.Num()) Polarity *= -1;
WalkingSpotIndex += Polarity; WalkingSpotIndex += Polarity;
return WalkingSpots[WalkingSpotIndex]; return WalkingSpots[WalkingSpotIndex] + SpawnTransform.GetLocation();
} }
void ANPC_WalkerClass::EnableNPC() void ANPC_WalkerClass::EnableNPC()

View File

@ -16,7 +16,7 @@ class ENDLESSVENDETTA_API ANPC_WalkerClass : public ACharacter
bool bIsEnabled = true; bool bIsEnabled = true;
protected: protected:
UPROPERTY(VisibleAnywhere, Category = "NPC", meta = (MakeEditWidget = "true")) UPROPERTY(EditAnywhere, Category = "NPC", meta = (MakeEditWidget = "true"))
TArray<FVector> WalkingSpots; TArray<FVector> WalkingSpots;
public: public: