|
Oakfolks Gold_1.14
Oakfolks coop game
|
Main player character for cooperative gameplay. More...
#include <MainPlayer.h>


Public Member Functions | |
| AMainPlayer () | |
| Initializes the main player with default character settings. | |
| virtual void | BeginPlay () |
| Initializes the player when spawned in the world. | |
| virtual void | SetupPlayerInputComponent (class UInputComponent *PlayerInputComponent) override |
| Configures input action bindings for the player. | |
| void | PickUp () |
| void | PickUp_Implementation () |
| Toggles pickup state for objects in front of the player. | |
| void | Interact () |
| Handles interaction with world objects. | |
| virtual FLocomotionConfiguration | ResetLocomotionConfig_Implementation () override |
| Resets locomotion configuration to default settings. | |
| virtual FLocomotionConfiguration | SetLocomotionConfig_Implementation (ULocomotionConfigurationAsset *NewConfig) override |
| Applies a new locomotion configuration. | |
| virtual FString | GetCustomLogInfo () const override |
| IBCR_Helper interface. | |
| bool | GetPickedUpSomething () |
Public Member Functions inherited from IBCR_Helper | |
| virtual void | CustomLogConsole (const FString &Message=TEXT("")) |
| Custom logging without context. | |
| virtual void | CustomLogScreen (const FString &Message=TEXT(""), float Duration=5.0f, FColor Color=FColor::White) |
| Logs a custom message to the screen without object context. | |
| virtual void | CustomLogAll (const FString &Message=TEXT(""), float Duration=5.0f, FColor Color=FColor::White) |
| Logs a custom message to both console and screen without object context. | |
Public Member Functions inherited from ILocomotional | |
| FLocomotionConfiguration | SetLocomotionConfig (ULocomotionConfigurationAsset *NewConfig) |
| FLocomotionConfiguration | ResetLocomotionConfig () |
| Configuration reset. | |
Public Attributes | |
| AActor * | PickedUpObject |
Protected Member Functions | |
| void | Move (const FInputActionValue &Value) |
| Handles player movement input. | |
| void | Look (const FInputActionValue &Value) |
| Handles player camera look input. | |
Protected Attributes | |
| UInputMappingContext * | DefaultMappingContext |
| UInputAction * | JumpAction |
| Movement actions. | |
| UInputAction * | MoveAction |
| UInputAction * | LookAction |
| UInputAction * | PickUpAction |
| Interaction actions. | |
| UInputAction * | InteractAction |
| UInputAction * | PauseAction |
| UInputAction * | LeftTriggerAction |
| Trigger actions. | |
| UInputAction * | RightTriggerAction |
| bool | bCanMove = true |
| ULocomotionConfigurationAsset * | DefaultLocomotionConfig |
| ULocomotionConfigurationAsset * | CurrentLocomotionConfig |
| bool | PickedUpSomething = false |
Additional Inherited Members | |
Static Public Member Functions inherited from IBCR_Helper | |
| static void | LogConsole (const UObject *Context, const FString &Message=TEXT("")) |
| Logs a message to the console with object context. | |
| static void | LogScreen (const UObject *Context, const FString &Message=TEXT(""), float Duration=5.0f, FColor Color=FColor::White) |
| Logs a message to the screen with object context. | |
| static void | LogAll (const UObject *Context, const FString &Message=TEXT(""), float Duration=5.0f, FColor Color=FColor::White) |
| Logs a message to both console and screen with object context. | |
| static FString | GetBasicObjectInfo (const UObject *Object) |
| Extracts basic information from a UObject. | |
Main player character for cooperative gameplay.
Handles input processing, locomotion configuration, object interaction, and pickup system
| AMainPlayer::AMainPlayer | ( | ) |
Initializes the main player with default character settings.
Sets up collision capsule, character movement, and default physics properties
|
virtual |
Initializes the player when spawned in the world.
Sets up enhanced input mapping context and resets locomotion configuration

|
inlineoverridevirtual |
IBCR_Helper interface.
Implements IBCR_Helper.
| void AMainPlayer::Interact | ( | ) |
Handles interaction with world objects.
INTERACTION SYSTEM //////// World interactions
Detects interactable objects and calls appropriate interaction methods

|
protected |
Handles player camera look input.
Processes look input for camera control (currently disabled for fixed camera)
| Value | Input action value containing look vector |

|
protected |
Handles player movement input.
INPUT HANDLERS //////// Movement processing
Processes 2D movement vector and applies it relative to camera orientation
| Value | Input action value containing movement vector |

| void AMainPlayer::PickUp | ( | ) |
PICKUP SYSTEM //////// Object manipulation

| void AMainPlayer::PickUp_Implementation | ( | ) |
Toggles pickup state for objects in front of the player.
Picks up objects if hands are empty, drops held objects if carrying something
|
overridevirtual |
Resets locomotion configuration to default settings.
INTERFACE IMPLEMENTATIONS //////// ILocomotional interface
Restores normal movement behavior from the default configuration asset
Reimplemented from ILocomotional.


|
overridevirtual |
Applies a new locomotion configuration.
Sets movement constraints and positioning for machine interactions
| NewConfig | The locomotion configuration asset to apply |
Reimplemented from ILocomotional.

|
overridevirtual |
Configures input action bindings for the player.
Sets up Enhanced Input system with movement, interaction, and pickup controls
| PlayerInputComponent | The input component to bind actions to |

|
protected |
MOVEMENT SYSTEM //////// Movement configuration
|
protected |
LOCOMOTION SYSTEM //////// Locomotion configuration
|
protected |
INPUT MAPPING //////// Enhanced Input System
|
protected |
PICKUP STATE //////// Pickup tracking