Phuket
This commit is contained in:
@ -9,6 +9,6 @@ public class MyProjectTarget : TargetRules
|
||||
Type = TargetType.Game;
|
||||
DefaultBuildSettings = BuildSettingsVersion.V5;
|
||||
|
||||
ExtraModuleNames.AddRange(new string[] { "MyProject", "hstherac25" });
|
||||
ExtraModuleNames.AddRange(new string[] { "MyProject", });
|
||||
}
|
||||
}
|
||||
|
@ -13,7 +13,7 @@ public class MyProject : ModuleRules
|
||||
PrivateDependencyModuleNames.AddRange(new string[] { });
|
||||
|
||||
// Uncomment if you are using Slate UI
|
||||
PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore", "hstherac25" });
|
||||
PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore" });
|
||||
|
||||
// Uncomment if you are using online features
|
||||
// PrivateDependencyModuleNames.Add("OnlineSubsystem");
|
||||
|
@ -1,37 +1,53 @@
|
||||
// Fill out your copyright notice in the Description page of Project Settings.
|
||||
|
||||
#include "ModeInputTextBox.h"
|
||||
#include <Logging/StructuredLog.h>
|
||||
|
||||
void UModeInputTextBox::HandleOnTextChanged(FText const & inText) {
|
||||
Text = Text.GetEmpty();
|
||||
auto & s = inText.ToString();
|
||||
auto lastChar = s.LeftChop(1);
|
||||
lastChar.ToUpperInline();
|
||||
// UE_LOGFMT(LogTemp, Warning, "kill me {inText}", s);
|
||||
|
||||
auto lastChar = s.ToUpper().Right(1);
|
||||
// UE_LOGFMT(LogTemp, Warning, "fucking {lastChar}", lastChar);
|
||||
SetText(FText::FromString(lastChar));
|
||||
if (!lastChar.IsEmpty()) {
|
||||
|
||||
switch (myTarget) {
|
||||
case THSModeTarget::Energy:
|
||||
switch (lastChar[0]) {
|
||||
switch (lastChar[lastChar.Len() - 1]) {
|
||||
case 'E':
|
||||
|
||||
break;
|
||||
case 'X':
|
||||
|
||||
break;
|
||||
default:
|
||||
lastChar[lastChar.Len() - 1] = '\0';
|
||||
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case THSModeTarget::OpMode:
|
||||
switch (lastChar[0]) {
|
||||
switch (lastChar[lastChar.Len() - 1]) {
|
||||
case 'T':
|
||||
|
||||
break;
|
||||
case 'R':
|
||||
|
||||
break;
|
||||
case 'P':
|
||||
|
||||
break;
|
||||
default:
|
||||
lastChar = "";
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
// UE_LOGFMT(LogTemp, Warning, "wat {lastChar}", lastChar);
|
||||
SetText(FText::FromString(lastChar));
|
||||
// SetText(FText::FromString(FString::Printf(TEXT("%c"), lastChar)));
|
||||
}
|
||||
|
@ -3,6 +3,25 @@
|
||||
#include "MyUserWidget.h"
|
||||
#include <MyPlayerState.h>
|
||||
|
||||
bool UMyUserWidget::AllVerified() {
|
||||
UTextBlock * myVerifiers[9] = {
|
||||
URM_Verifier,
|
||||
MU_Verifier,
|
||||
Time_Verifier,
|
||||
GR_Verifier,
|
||||
CR_Verifier,
|
||||
ColX_Verifier,
|
||||
ColY_Verifier,
|
||||
WN_Verifier,
|
||||
AN_Verifier
|
||||
};
|
||||
for (auto & v : myVerifiers) {
|
||||
if (v->GetText().IsEmpty())
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void UMyUserWidget::NativeOnInitialized() {
|
||||
auto ps = StaticCast<AMyPlayerState *>(GetOwningPlayerState());
|
||||
if (ps == nullptr)
|
||||
|
@ -45,5 +45,35 @@ class MYPROJECT_API UMyUserWidget : public UUserWidget {
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * AN_TextBlock;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * URM_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * MU_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * Time_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * GR_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * CR_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * ColX_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * ColY_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * WN_Verifier;
|
||||
|
||||
UPROPERTY(meta = (BindWidget))
|
||||
UTextBlock * AN_Verifier;
|
||||
|
||||
UFUNCTION(BlueprintCallable, BluePrintPure)
|
||||
bool AllVerified();
|
||||
|
||||
void NativeOnInitialized() override;
|
||||
};
|
||||
|
@ -9,6 +9,6 @@ public class MyProjectEditorTarget : TargetRules
|
||||
Type = TargetType.Editor;
|
||||
DefaultBuildSettings = BuildSettingsVersion.V5;
|
||||
|
||||
ExtraModuleNames.AddRange(new string[] { "MyProject", "hstherac25" });
|
||||
ExtraModuleNames.AddRange(new string[] { "MyProject", });
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user