From 1b443223257b4315ecba03c102bdef1e3ac6d75e Mon Sep 17 00:00:00 2001 From: wonkyhonky2024 Date: Tue, 13 May 2025 21:22:31 +0100 Subject: [PATCH] wrestle with writing to sim --- Content/LinacLab/MyMyUserWidget.uasset | 4 ++-- Content/LinacLab/vt100_Blueprint.uasset | 4 ++-- .../Private/TheracAdapterComponent.cpp | 18 ++++++++++++++++++ .../hstherac25/Public/TheracAdapterComponent.h | 8 ++++++++ 4 files changed, 30 insertions(+), 4 deletions(-) diff --git a/Content/LinacLab/MyMyUserWidget.uasset b/Content/LinacLab/MyMyUserWidget.uasset index 4971e04..e056ba3 100644 --- a/Content/LinacLab/MyMyUserWidget.uasset +++ b/Content/LinacLab/MyMyUserWidget.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a08265d772d9ca487e5d2fe73ce684e19eb7da597b36fffd7e35e9b087c9722c -size 144396 +oid sha256:eb52982872141a34f03496b36f5502683c0d3c6aa5a7af2ecc72eefcfffc557a +size 156573 diff --git a/Content/LinacLab/vt100_Blueprint.uasset b/Content/LinacLab/vt100_Blueprint.uasset index c46ad70..6dc2d00 100644 --- a/Content/LinacLab/vt100_Blueprint.uasset +++ b/Content/LinacLab/vt100_Blueprint.uasset @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:72110e989b287b621f5e039512f74904695d6a75efadacacf6ebce43e12085a3 -size 106703 +oid sha256:8805e9a37b46bc5f899a2bc385afd1f98a47f8d92d3ddac42fb77c5165eb6efb +size 158294 diff --git a/Plugins/hstherac25/Source/hstherac25/Private/TheracAdapterComponent.cpp b/Plugins/hstherac25/Source/hstherac25/Private/TheracAdapterComponent.cpp index d1c9b96..aa09e05 100644 --- a/Plugins/hstherac25/Source/hstherac25/Private/TheracAdapterComponent.cpp +++ b/Plugins/hstherac25/Source/hstherac25/Private/TheracAdapterComponent.cpp @@ -23,6 +23,24 @@ UTheracAdapterComponent::UTheracAdapterComponent() { // ... } +void UTheracAdapterComponent::UpdateSimulator( + ExtCallType ect, + HsStablePtr wrapped_comms, + BeamType beam_type, + CollimatorPosition collimator_position, + HsInt beam_energy +) { + if (wrapped_comms == nullptr) + wrapped_comms = wrappedComms; + wrap_external_call( + wrapped_comms, + ect, + beam_type, + collimator_position, + beam_energy + ); +} + // Called when the game starts void UTheracAdapterComponent::BeginPlay() { /* diff --git a/Plugins/hstherac25/Source/hstherac25/Public/TheracAdapterComponent.h b/Plugins/hstherac25/Source/hstherac25/Public/TheracAdapterComponent.h index f3725a2..f565948 100644 --- a/Plugins/hstherac25/Source/hstherac25/Public/TheracAdapterComponent.h +++ b/Plugins/hstherac25/Source/hstherac25/Public/TheracAdapterComponent.h @@ -46,6 +46,14 @@ public: UPROPERTY(BlueprintReadOnly, VisibleAnywhere) FText BeamEnergy; + void UpdateSimulator( + ExtCallType ect, + HsStablePtr wrapped_comms = nullptr, + BeamType beam_type = BeamTypeUndefined, + CollimatorPosition collimator_position = CollimatorPositionUndefined, + HsInt beam_energy = 25000 + ); + protected: // Called when the game starts virtual void BeginPlay() override;