diff --git a/UnrealProject/Lost_Edge/Content/Audio/Sounds/Clock.uasset b/UnrealProject/Lost_Edge/Content/Audio/Sounds/Clock.uasset deleted file mode 100644 index cb56cd1..0000000 --- a/UnrealProject/Lost_Edge/Content/Audio/Sounds/Clock.uasset +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:d93939331ddcf16c2e4f3bcfbda4dcfe86ae2f9b6735714949148f9070f1828d -size 44820 diff --git a/UnrealProject/Lost_Edge/Content/Audio/Sounds/Knock.uasset b/UnrealProject/Lost_Edge/Content/Audio/Sounds/Knock.uasset index 3d5bc73..9bac2eb 100644 --- a/UnrealProject/Lost_Edge/Content/Audio/Sounds/Knock.uasset +++ b/UnrealProject/Lost_Edge/Content/Audio/Sounds/Knock.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:765d214c97e7ea5d980099afa50801f62d7df95b40bfdd313a6de11ccd3fa17d -size 72552 +oid sha256:9fe1f29d2b08e8ab4a89d8fd9ca90fee07045422efc18103ceacd81e499a2e10 +size 1459 diff --git a/UnrealProject/Lost_Edge/Content/Audio/Sounds/SA_Default.uasset b/UnrealProject/Lost_Edge/Content/Audio/Sounds/SA_Default.uasset new file mode 100644 index 0000000..660e315 --- /dev/null +++ b/UnrealProject/Lost_Edge/Content/Audio/Sounds/SA_Default.uasset @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17ee2c21fb30f7c3d2406b3fde7f9ed671d2ccdfab64932c05efc444960a184c +size 1603 diff --git a/UnrealProject/Lost_Edge/Content/Audio/Sounds/SW_Clock.uasset b/UnrealProject/Lost_Edge/Content/Audio/Sounds/SW_Clock.uasset new file mode 100644 index 0000000..5d6bdc1 --- /dev/null +++ b/UnrealProject/Lost_Edge/Content/Audio/Sounds/SW_Clock.uasset @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3dc59acf3ca2bdc4c95e624f2133356742e664cd7f370b0eedb4914722c4f7f6 +size 45443 diff --git a/UnrealProject/Lost_Edge/Content/Audio/Sounds/SW_Knock.uasset b/UnrealProject/Lost_Edge/Content/Audio/Sounds/SW_Knock.uasset new file mode 100644 index 0000000..5341531 --- /dev/null +++ b/UnrealProject/Lost_Edge/Content/Audio/Sounds/SW_Knock.uasset @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8ee7fe7a9eded3f3ae318f1a30cb6feb3721e32334e6898530c388799f6de7ed +size 77786 diff --git a/UnrealProject/Lost_Edge/Content/Blueprints/Decorations/BP_Door.uasset b/UnrealProject/Lost_Edge/Content/Blueprints/Decorations/BP_Door.uasset index ad57b63..c71f885 100644 --- a/UnrealProject/Lost_Edge/Content/Blueprints/Decorations/BP_Door.uasset +++ b/UnrealProject/Lost_Edge/Content/Blueprints/Decorations/BP_Door.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1e67b45f27b6865288a21f0880ed30a0aa814e85991206095be1b30f0cf35705 -size 86796 +oid sha256:8132e943e2e104f176711a6484ebe5bc296b4df515b194db2fcae8c464f4548c +size 164713 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_1/Blueprints/BP_doorS.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_1/Blueprints/BP_doorS.uasset index 1fff9c8..cb8f75f 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_1/Blueprints/BP_doorS.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_1/Blueprints/BP_doorS.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0743fde364fc0924a40264c138ac4128b97109d4708d109e31ed6a5e490854e0 -size 121452 +oid sha256:ae06f77163414444b719ae2f5c15dde00238a136ae555b86eb435b684a33ac69 +size 122261 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_1/L_Level1.umap b/UnrealProject/Lost_Edge/Content/Levels/Level_1/L_Level1.umap index 364a077..2938b70 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_1/L_Level1.umap +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_1/L_Level1.umap @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:90f84a3040d4f98528876d543cfdbd94912887d83d7ea7e577ba0a7f577ce919 -size 388189142 +oid sha256:f69c6ed4bc6903242d58271db2900acf72bb727af25731f8c375b81d8f6b9aaa +size 388196375 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_BookSort.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_BookSort.uasset index 753aa8b..9e63bf3 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_BookSort.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_BookSort.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:19c9c7be8a57361ff6897ca895f885f733ccd1abf9bae77acabaeb3decc1b66f -size 47064 +oid sha256:60215db713acd3b39f4bf5216f2dcaa29dc525c283073ec2896997a98dcf5d6a +size 46752 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_MortisDoor.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_MortisDoor.uasset new file mode 100644 index 0000000..b3ad3e8 --- /dev/null +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_MortisDoor.uasset @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f4514e93eca7504218084d320288dac3ccf7de582b0dbe250e9e70f029c8bd72 +size 62315 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_Telescope.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_Telescope.uasset index ffdf57a..3657aed 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_Telescope.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/BP_Level2_Telescope.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:76fd609f2d8502945d84fde12165c594cad3e0e980104b74e8d9c331525bf1ef -size 45905 +oid sha256:d3fbf4b9b3b424546ad6d391b45d9e9270de215b1b9731794925a3ba28cdc396 +size 45891 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_CrossyRoad.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_CrossyRoad.uasset index 408ff18..bcd4278 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_CrossyRoad.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_CrossyRoad.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a18efd4b5c48d4387cd75001b1ab39875fe97c54ffec42da548d8d64b3958003 -size 54215 +oid sha256:ce578f24030af9ab631067d55df3bd32043cf8a7d74bc601898dd6c31266c2b8 +size 53937 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_Fishing.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_Fishing.uasset index 1e54374..ff340d3 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_Fishing.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_Fishing.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cc3e13282498f04add636bd8ed12f1cce03fbb835165cd6bcc1d151c0e1c532b -size 54517 +oid sha256:27ce61641b6292e91d59516e2cf509084c0943dde107054151365d2c82e62342 +size 54264 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_SubwaySurf.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_SubwaySurf.uasset index efd4a3c..66ab5e5 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_SubwaySurf.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Blueprints/SM_Level2_SubwaySurf.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bb6595d2f483510eadb98ee82635ea7c22e02646309b5c40b327f7eeb5bca9b3 -size 54029 +oid sha256:bd2f1d6b89b7526191ddb8df8a3e579b27de7888067d0b2f7b2dd2c884178307 +size 54517 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/E_Level2_Event.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/E_Level2_Event.uasset index 9a6cb3b..0c8262a 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/E_Level2_Event.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/E_Level2_Event.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c362815e3253fcd22edd22c6a74bbd3c762e79df40b1645cd062d80104c7e751 -size 2440 +oid sha256:d97b15b9282a8d98276da041882fafbac328e3026c1bc47b0ba68058871cebba +size 2815 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/L_Level2.umap b/UnrealProject/Lost_Edge/Content/Levels/Level_2/L_Level2.umap index 3201971..09802c1 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/L_Level2.umap +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/L_Level2.umap @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ab19e2efd469fc9ba1ce0d9285fc6bc84fdf2ce3d6d04f314428339b31251707 -size 43693759 +oid sha256:9ca36bd0e2816475a0b52be386237f124bcbf7d988e5f305c9bcb92fc8b43798 +size 43715802 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/OnBeginPlay/Seq_Level2_clock.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/OnBeginPlay/Seq_Level2_clock.uasset index f1ebc98..4780728 100644 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/OnBeginPlay/Seq_Level2_clock.uasset +++ b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/OnBeginPlay/Seq_Level2_clock.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:12c227e6ce700048a6340225d660a55a345a2dd89da68c517e43762c9ad890e4 -size 126468 +oid sha256:84d6730afa82823bdb24b965eb917a8ac81c8b4206b3c942f606db9e700a2c45 +size 64196 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/Seq_Level2_CarolRun.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/Seq_Level2_CarolRun.uasset deleted file mode 100644 index 8287d72..0000000 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/Seq_Level2_CarolRun.uasset +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:475a6ab757f62db8bede39d573a3f130e561b59f11653b688d86348534b92364 -size 137395 diff --git a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/Seq_Level2_FromField.uasset b/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/Seq_Level2_FromField.uasset deleted file mode 100644 index 6d16984..0000000 --- a/UnrealProject/Lost_Edge/Content/Levels/Level_2/Sequencers/Seq_Level2_FromField.uasset +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a2e568a6f1d590920191ef9863a034c4c98ad38d05fdf1ad8a1082d520fc7465 -size 142617 diff --git a/UnrealProject/Lost_Edge/Content/MaterialsLibrary/M_InvisibleBarrier.uasset b/UnrealProject/Lost_Edge/Content/MaterialsLibrary/M_InvisibleBarrier.uasset index 9b65d5f..ba97a98 100644 --- a/UnrealProject/Lost_Edge/Content/MaterialsLibrary/M_InvisibleBarrier.uasset +++ b/UnrealProject/Lost_Edge/Content/MaterialsLibrary/M_InvisibleBarrier.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c20d10d872664511609544d040f0c7d294fe2b4980bd379a8379043336c6ae7d -size 24594 +oid sha256:2606bcc3089c55bbdc92ab1b2d697e4cae4955639e5bfc41fd54ccf7b5bbd7a3 +size 24077 diff --git a/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.cpp b/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.cpp index f4054ca..748d9b2 100644 --- a/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.cpp +++ b/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.cpp @@ -107,9 +107,21 @@ void AInteractable::BeginPlay() } } - GetComponents(collisions, true); - for(auto collision : collisions) + GetComponents(collisions); + for(int32 i = 0; i < collisions.Num(); ++i) { + auto collision = collisions[i]; + switch(collision->GetCollisionResponseToChannel(GetCollisionChannel())) + { + case ECollisionResponse::ECR_Ignore: + case ECollisionResponse::ECR_Overlap: + collisions.RemoveAt(i, EAllowShrinking::No); + --i; + continue; + default: + break; + } + if(activatorTypes) { collision->SetCollisionProfileName(collisionProfile); @@ -128,9 +140,13 @@ void AInteractable::BeginPlay() collision->SetRenderCustomDepth(true); } } + collisions.Shrink(); if(auto PC = UGameplayStatics::GetPlayerController(GetWorld(), 0)) player = Cast(PC->GetPawn()); + + if(lockOnBeginPlay) + Lock(); } void AInteractable::EndPlay(const EEndPlayReason::Type EndPlayReason) diff --git a/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.h b/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.h index cea2af8..868cc8d 100644 --- a/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.h +++ b/UnrealProject/Lost_Edge/Source/Lost_Edge/Private/Interactable/Interactable.h @@ -87,6 +87,9 @@ protected: /** Mask of active activator types */ UPROPERTY(EditAnywhere, BlueprintReadWrite, meta = (Bitmask, BitmaskEnum = "EActivatorType")) int32 activated = 0; + UPROPERTY(EditAnywhere) + bool lockOnBeginPlay = false; + TArray collisions; /** TArray cannot be a value of a TMap */ struct FModificatorsArray @@ -96,8 +99,6 @@ protected: /** Map of modificators to activator types initialized on BeginPlay */ TMap modificators; - - TArray collisions; class APlayerBase* player = nullptr; };