Compare commits
No commits in common. "cb5ac1cd589071e43c69e6cd41e951ad86c1f03f" and "6abe8a1c5f6e379586baa1a44fe7627ef6fbe0d3" have entirely different histories.
cb5ac1cd58
...
6abe8a1c5f
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -40,7 +40,6 @@ public class Dialogue : ModuleRules
|
|||||||
"Slate",
|
"Slate",
|
||||||
"SlateCore",
|
"SlateCore",
|
||||||
// ... add private dependencies that you statically link with here ...
|
// ... add private dependencies that you statically link with here ...
|
||||||
"UMG"
|
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
|
|
||||||
#include "DialogueAsset.h"
|
#include "DialogueAsset.h"
|
||||||
#include "Runtime/UMG/Public/Blueprint/UserWidget.h"
|
|
||||||
#include "UObject/ObjectSaveContext.h"
|
#include "UObject/ObjectSaveContext.h"
|
||||||
|
|
||||||
|
|
||||||
@ -11,12 +11,6 @@ bool UDialogueConditions::IsConditionMet_Implementation()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
UDialogueAsset::UDialogueAsset()
|
|
||||||
{
|
|
||||||
UClass* WidgetClass = LoadClass<UUserWidget>(this, TEXT("/Game/UI/Dialogue/UMG_DialogueWindow.UMG_DialogueWindow_C"));
|
|
||||||
DialogueWidget = WidgetClass;
|
|
||||||
}
|
|
||||||
|
|
||||||
void UDialogueAsset::BeginDialogue()
|
void UDialogueAsset::BeginDialogue()
|
||||||
{
|
{
|
||||||
CurrentNode = NodeDatas[0];
|
CurrentNode = NodeDatas[0];
|
||||||
|
|||||||
@ -102,7 +102,6 @@ class DIALOGUE_API UDialogueAsset : public UDataAsset
|
|||||||
{
|
{
|
||||||
GENERATED_BODY()
|
GENERATED_BODY()
|
||||||
public:
|
public:
|
||||||
UDialogueAsset();
|
|
||||||
UFUNCTION(BlueprintCallable, Category = Dialogue)
|
UFUNCTION(BlueprintCallable, Category = Dialogue)
|
||||||
void BeginDialogue();
|
void BeginDialogue();
|
||||||
UFUNCTION(BlueprintPure, Category = Dialogue)
|
UFUNCTION(BlueprintPure, Category = Dialogue)
|
||||||
@ -120,10 +119,7 @@ public:
|
|||||||
UPROPERTY(BlueprintAssignable, Category=Dialogue)
|
UPROPERTY(BlueprintAssignable, Category=Dialogue)
|
||||||
FOnDialogueComplete OnDialogueComplete;
|
FOnDialogueComplete OnDialogueComplete;
|
||||||
|
|
||||||
UPROPERTY(BlueprintReadOnly, EditAnywhere, Category = DialogueAsset)
|
UPROPERTY(EditAnywhere, BlueprintReadOnly, Category = Dialogue)
|
||||||
TSubclassOf<UUserWidget> DialogueWidget;
|
|
||||||
|
|
||||||
UPROPERTY(BlueprintReadOnly, Category = Dialogue)
|
|
||||||
TArray<UDialogueRuntimeNode*> NodeDatas;
|
TArray<UDialogueRuntimeNode*> NodeDatas;
|
||||||
private:
|
private:
|
||||||
UDialogueRuntimeNode* CurrentNode = nullptr;
|
UDialogueRuntimeNode* CurrentNode = nullptr;
|
||||||
|
|||||||
@ -34,23 +34,11 @@ TSharedRef<SWidget> FDialogueDetailsTabSummoner::CreateTabBody(const FWorkflowTa
|
|||||||
DetailsViewArgs.bShowModifiedPropertiesOption = false;
|
DetailsViewArgs.bShowModifiedPropertiesOption = false;
|
||||||
DetailsViewArgs.bShowScrollBar = false;
|
DetailsViewArgs.bShowScrollBar = false;
|
||||||
|
|
||||||
//node节点详情面板
|
|
||||||
TSharedPtr<IDetailsView> DetailsView = PropertyEditorModule.CreateDetailView(DetailsViewArgs);
|
TSharedPtr<IDetailsView> DetailsView = PropertyEditorModule.CreateDetailView(DetailsViewArgs);
|
||||||
DetailsView->SetObject(nullptr);
|
DetailsView->SetObject(nullptr);
|
||||||
Editor->SetDetailsView(DetailsView);
|
Editor->SetDetailsView(DetailsView);
|
||||||
|
|
||||||
//资源的详情面板
|
|
||||||
TSharedPtr<IDetailsView> DialogueAssetDetailView = PropertyEditorModule.CreateDetailView(DetailsViewArgs);
|
|
||||||
DialogueAssetDetailView->SetObject(Editor->GetDialogueBeingEdited());
|
|
||||||
|
|
||||||
|
|
||||||
return SNew(SVerticalBox)
|
return SNew(SVerticalBox)
|
||||||
+ SVerticalBox::Slot()
|
|
||||||
.AutoHeight()
|
|
||||||
.HAlign(HAlign_Fill)
|
|
||||||
[
|
|
||||||
DialogueAssetDetailView.ToSharedRef()
|
|
||||||
]
|
|
||||||
+ SVerticalBox::Slot()
|
+ SVerticalBox::Slot()
|
||||||
.FillHeight(1.0f)
|
.FillHeight(1.0f)
|
||||||
.HAlign(HAlign_Fill)
|
.HAlign(HAlign_Fill)
|
||||||
|
|||||||
@ -44,7 +44,6 @@ public:
|
|||||||
// 图表选择改变回调,传递属性页需要显示的内容
|
// 图表选择改变回调,传递属性页需要显示的内容
|
||||||
void OnGraphSelectionChanged(const FGraphPanelSelectionSet& Selection);
|
void OnGraphSelectionChanged(const FGraphPanelSelectionSet& Selection);
|
||||||
|
|
||||||
TObjectPtr<UDialogueAsset> GetDialogueBeingEdited() {return DialogueBeingEdited;}
|
|
||||||
protected:
|
protected:
|
||||||
void SaveGraphData();
|
void SaveGraphData();
|
||||||
void LoadGraphData();
|
void LoadGraphData();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user