Skip to content

Commit

Permalink
Add helper for abstracting FxResponseArgs
Browse files Browse the repository at this point in the history
  • Loading branch information
Exit-9B committed Nov 2, 2024
1 parent ab8f405 commit ed41cde
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions include/RE/F/FxDelegateArgs.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#pragma once

#include "RE/F/FxResponseArgs.h"
#include "RE/G/GFxValue.h"

namespace RE
Expand All @@ -19,6 +20,14 @@ namespace RE
[[nodiscard]] GFxMovieView* GetMovie() const;
[[nodiscard]] std::uint32_t GetArgCount() const;

template <std::convertible_to<GFxValue>... Args>
void Respond(Args&&... a_args) const
{
FxResponseArgs<sizeof...(Args)> response;
(response.Add(std::forward<Args>(a_args)), ...);
Respond(response);
}

protected:
// members
GFxValue _responseID; // 00
Expand Down

0 comments on commit ed41cde

Please sign in to comment.