You've already forked LuckyWorld
Optimize gamemode and gamestate code
This commit is contained in:
@ -6,6 +6,8 @@
|
||||
#include "GameFramework/GameStateBase.h"
|
||||
#include "LuckyRobotsGameState.generated.h"
|
||||
|
||||
class USocketIOClientComponent;
|
||||
class USIOJsonValue;
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@ -13,5 +15,21 @@ UCLASS()
|
||||
class LUCKYROBOTS_API ALuckyRobotsGameState : public AGameStateBase
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
protected:
|
||||
ALuckyRobotsGameState();
|
||||
virtual void BeginPlay() override;
|
||||
|
||||
public:
|
||||
UPROPERTY(Category = Character, VisibleAnywhere, BlueprintReadOnly, meta = (AllowPrivateAccess = "true"))
|
||||
USocketIOClientComponent* SocketIOClientComponent;
|
||||
|
||||
public:
|
||||
UFUNCTION(BlueprintCallable)
|
||||
void DoSendMessage(FString SendValue);
|
||||
|
||||
UFUNCTION(BlueprintCallable)
|
||||
void DoSocketOnConnect(FString SocketId, FString SessionId, bool IsReconnection);
|
||||
|
||||
UFUNCTION(BlueprintCallable)
|
||||
void DoSocketOnGenericEvent(FString EventName, USIOJsonValue* EventData);
|
||||
};
|
||||
|
Reference in New Issue
Block a user