-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPathfinder.h
More file actions
37 lines (27 loc) · 1.01 KB
/
Copy pathPathfinder.h
File metadata and controls
37 lines (27 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
// Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "CoreMinimal.h"
#include "Components/ActorComponent.h"
#include <vector>
#include <unordered_map>
#include "Pathfinder.generated.h"
UCLASS( ClassGroup=(Custom), meta=(BlueprintSpawnableComponent) )
class BONENSOUL_API UPathfinder : public UActorComponent
{
GENERATED_BODY()
public:
// Sets default values for this component's properties
UPathfinder();
protected:
// Called when the game starts
virtual void BeginPlay() override;
public:
// Called every frame
virtual void TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction) override;
void UpdatePlatformMap(TArray<class APlatform*> _RoomPlatforms);
TArray<int> FindPath(int From, int To);
// TArray<class APlatform*> RoomPlatforms;
std::unordered_map<int, class APlatform*> RoomPlatforms;
//Distance from platforms
std::vector<std::vector<float>> PlatformDistanceToPlatform;
};