Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Fill out your copyright notice in the Description page of Project Settings.
- #pragma once
- #include "GameFramework/PlayerController.h"
- #include "FCPlayerState.h"
- #include "FCWorldSettings.h"
- #include "FCFaction.h"
- #include "FCStratPawn.h"
- #include "FCHero.h"
- #include "Runtime/UMG/Public/Blueprint/UserWidget.h"
- #include "FCPlayerController.generated.h"
- /**
- *
- */
- UCLASS()
- class FIELDCOMMANDER_API AFCPlayerController : public APlayerController
- {
- GENERATED_BODY()
- public:
- // The instance of the players Inventory UI Widget
- UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "UI")
- class UUserWidget* LobbyWidget;
- // The instance of the players Inventory UI Widget
- UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "UI")
- class UUserWidget* HUDWidget;
- UPROPERTY(replicatedUsing = OnRep_StratPawn, BlueprintReadOnly)
- class AFCStratPawn* CurrentFCStratPawn;
- UPROPERTY(replicatedUsing = OnRep_HeroPawn, BlueprintReadOnly)
- class AFCHero* CurrentFCHero;
- UPROPERTY()
- FVector DragScrollStartLocation;
- UPROPERTY()
- FVector DragScrollCursorStartLocation;
- UPROPERTY()
- bool IsDragScrolling;
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerReadyUp(bool PlayerIsReady);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerReadyUp(bool PlayerIsReady);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerPickFaction(TSubclassOf<UFCFaction> NewFaction, bool IsRandomFaction);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerPickFaction(TSubclassOf<UFCFaction> NewFaction, bool IsRandomFaction);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerPickHero(TSubclassOf<AFCHero> NewHero, bool IsRandomHero);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerPickHero(TSubclassOf<AFCHero> NewHero, bool IsRandomHero);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerPickPlayerSlot(int32 TeamSlotIdx, int32 ForceSlotIdx, int32 PlayerSlotIdx);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerPickPlayerSlot(int32 TeamSlotIdx, int32 ForceSlotIdx, int32 PlayerSlotIdx);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerPickStartLocationForForce(int32 NewStartLocation);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerPickStartLocationForForce(int32 NewStartLocation);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerSpawnBase(int32 NewBaseLocation, bool InstantActivation);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerSpawnBase(int32 NewBaseLocation, bool InstantActivation);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerSpawnHero(FVector NewLocation);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerSpawnHero(FVector NewLocation);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerSwapPerspective(bool ToStratCam);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerSwapPerspective(bool ToStratCam);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerHelpers")
- class AFCWorldSettings* GetFCWorldSettings();
- virtual void BeginPlay() override;
- /** Allows the PlayerController to set up custom input bindings. */
- virtual void SetupInputComponent() override;
- virtual void PlayerTick(float DeltaTime) override;
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleMoveForward(float Val);
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleMoveRight(float Val);
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleLookUp(float Val);
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleLookRight(float Val);
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleJump();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandlePerspectiveSwap();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandlePrimaryAction();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleSecondaryAction();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleTertiaryAction();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandlePrimaryActionEnd();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleSecondaryActionEnd();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleTertiaryActionEnd();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleNextWeapon();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandlePrevWeapon();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand1();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand2();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand3();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand4();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand5();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand6();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand7();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand8();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand9();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleStratCommand0();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup1();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup2();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup3();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup4();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup5();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup6();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup7();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup8();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup9();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleHotGroup10();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleSwapKey();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void HandleCancelKey();
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void SelectHotGroup(int32 group);
- UFUNCTION(BlueprintCallable, Category = "FCInput")
- virtual void GiveStratCommand(int32 Idx);
- /** FC Strat Pawn notification callback. */
- UFUNCTION()
- virtual void OnRep_StratPawn();
- /** FC Hero Pawn notification callback. */
- UFUNCTION()
- virtual void OnRep_HeroPawn();
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerSelectUnits(const TArray<AFCUnit*>& NewUnits);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerSelectUnits(const TArray<AFCUnit*>& NewUnits);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerDeselectUnits(const TArray<AFCUnit*>& NewUnits);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerDeselectUnits(const TArray<AFCUnit*>& NewUnits);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerDeselectAllUnits();
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerDeselectAllUnits();
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerChangeCommandMenuPage(int32 newpage);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerChangeCommandMenuPage(int32 newpage);
- UFUNCTION(BlueprintCallable, Category = "FCPlayerControllerActions")
- void PlayerChangeSubSelectionUnitType(TSubclassOf<AFCUnit> NewUnitType);
- UFUNCTION(Server, Reliable, WithValidation)
- void ServerPlayerChangeSubSelectionUnitType(TSubclassOf<AFCUnit> NewUnitType);
- bool HasReceivedGameModeFactionClasses;
- virtual void ReceivedGameModeFactionClasses();
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement