Created
November 11, 2017 14:01
-
-
Save lobotomiac/52312892a4b99438976d918a5d21a3c3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// nemozenitkodirnitovo | |
#pragma once | |
#include "CoreMinimal.h" | |
#include "Components/ActorComponent.h" | |
#include "Engine/TriggerVolume.h" | |
#include "CloseDoor.generated.h" | |
UCLASS( ClassGroup=(Custom), meta=(BlueprintSpawnableComponent) ) | |
class ESCAPEROOM_API UCloseDoor : public UActorComponent | |
{ | |
GENERATED_BODY() | |
public: | |
// Sets default values for this component's properties | |
UCloseDoor(); | |
protected: | |
// Called when the game starts | |
virtual void BeginPlay() override; | |
void CloseDoor(); | |
public: | |
// Called every frame | |
virtual void TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction) override; | |
private: | |
UPROPERTY(EditAnywhere) | |
ATriggerVolume *PressurePlate = NULL; | |
UPROPERTY(EditAnywhere) | |
AActor *ActorThatCloses = NULL; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment