Documentation for the Unreal C++ Library
Loading...
Searching...
No Matches
MultiplayerManagerComponent.h
Go to the documentation of this file.
1// Copyright(c) 2023 PixoVR, LLC. All Rights Reserved.
2
3#pragma once
4
5#include "CoreMinimal.h"
6#include "Components/ActorComponent.h"
7#include "AgonesComponent.h"
8#include "MultiplayerManagerComponent.generated.h"
9
10
11UCLASS( ClassGroup=(Custom), meta=(BlueprintSpawnableComponent) )
12class PIXOVRMULTIPLAYER_API UMultiplayerManagerComponent : public UActorComponent
13{
14 GENERATED_BODY()
15
16public:
17 // Sets default values for this component's properties
19
20protected:
21 // Called when the game starts
22 virtual void BeginPlay() override;
23
24 UAgonesComponent* AgonesSDK;
25public:
26 // Called every frame
27 virtual void TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction) override;
28
29 UPROPERTY(EditAnywhere, BlueprintReadWrite)
30 FGameServerDelegate GameServerDelegate;
31
32 UPROPERTY(BlueprintReadOnly)
33 bool bWasMetaDataSet;
34
35 UFUNCTION(BlueprintCallable, Category = "Multiplayer | Manager")
36 virtual void OnGameServerChanged(const FGameServerResponse& Response);
37
38 UFUNCTION(BlueprintCallable, Category = "Multiplayer | Manager")
39 virtual void OnSessionCreated(FName SessionName, bool bSuccessful);
40
41 UFUNCTION(BlueprintCallable, Category = "Multiplayer | Manager")
42 void SetUserInfo(FString InUserName, int InUserOrgId);
43
44 UFUNCTION(BlueprintCallable, Category = "Multiplayer | Manager")
45 void SetModuleInfo(int InModuleId, FString InModuleVersion);
46
47 UFUNCTION(BlueprintCallable, Category = "Multiplayer | Manager")
48 bool FindSessions(float InTimeoutInSeconds = 120.f, int InOrgId = -1, int InModuleId = -1, FString InUserName = "", FString InModuleVersion = "");
49
50 UFUNCTION(Category = "Multiplayer | Manager")
51 void OnSetLabelSuccess(const FEmptyResponse& Response);
52
53 UFUNCTION(Category = "Multiplayer | Manager")
54 void OnSetLabelFail(const FAgonesError& Error);
55};
#define Error(pmt,...)
UCLASS( ClassGroup=(Custom), meta=(BlueprintSpawnableComponent) )
FGameServerDelegate GameServerDelegate
UPROPERTY(EditAnywhere, BlueprintReadWrite)
bool bWasMetaDataSet
UPROPERTY(BlueprintReadOnly)