BPI_LPSP_PCH
Introduction
The BPI_LPSP_PCH is a Blueprint Interface that helps actors access the values of the player character and call different functions on it. Using this interface instead of directly accessing things on the player blueprint allows developers to completely replace the player character blueprint and simply add this interface to theirs, enabling every other piece of the asset to continue functioning. This is basic decoupling.
If you seek to access the BPI_LPSP_PCH blueprint, it is conveniently located at the following path: LowPolyShooterPack/Core/Characters/BPI_LPSP_PCH.
Functions
LPSP - On Throw Grenade:
This code is called to make the character spawn and throw a grenade. Typically, it is run from an animation notify, so that it can be timed with the animation.
LPSP - Is Aiming:
Return true if the character is currently aiming.
LPSP - Is Running:
This function returns true if the character is currently running.
LPSP - Is Tutorial Text Visible:
This function returns true if the tutorial text should be visible. As most games won't require it, we'll likely move super-specific functions like this to other interfaces.
LPSP - Get Aim Duration:
This function returns the time it takes for the character to go from idle to aim. By default, there is a magic number (0.25) that is timed perfectly with our wiggle animations. However, we can adjust this timing by dividing the magic number by a speed multiplier. This allows us to make the transition faster without breaking the syncing.
LPSP - Get Aim Speed Multiplier:
This function returns the aiming speed multiplier, which alters the play rate of the aiming in and aiming out wiggle animations.
LPSP - Get Field Of View:
This function returns the character's field of view while standing still. By default, the value is retrieved from the Game Instance, which holds a reference to our saved settings.
LPSP - Get Field Of View Running:
This method returns the character's field of view while running. By default, we multiply the default field of view by a multiplier to obtain this value. This approach allows us to keep the field of view proportional, instead of requiring us to modify this number every time we modify the base field of view.
LPSP - Get Sensitivity Multiplier:
This function returns the value by which to multiply the character's look input. Typically, this value is obtained from the game settings. This allows players to modify it, but it can also be a constant value.
LPSP - Get Input Look:
This function returns the value of the character's "look" input axis.
LPSP - Get Input Movement:
This function returns the value of the character's "movement" input axis.
LPSP - Get Grenades Current:
This function returns the current number of grenades held by the character.
LPSP - Get Ability Tags:
This function returns the character's current gameplay tags. It is used by the game ability system in the asset, but may not be necessary if you are not using it.
LPSP - On Set Ability Tags:
This function sets the gameplay tags for a character.
LPSP - On Try Fire Projectile:
This function spawns a projectile and fires it. It is primarily used within the Character Blueprint itself, but it can also be called from an Animation Notify in order to time shooting with an animation. Therefore, it remains a part of this interface.
LPSP - Get Actor Pickup:
This function returns the actor that the character is currently able to pick up.
LPSP - Get Equipped Item:
Returns the Actor for the character's equipped weapon.
LPSP - Set Knife Visibility:
This function sets the visibility of the first-person knife. It is typically called from an animation notify.
LPSP - Is Camera Right Shoulder:
This function returns true if the camera is positioned behind the character's right shoulder.
Note that this function is not currently used in the asset's current version, but it will become important once we release the third-person system.
LPSP - Get Camera Component:
Returns the camera component.
LPSP - Get Shot Count:
Returns the value of Shot Count.
LPSP - On Ammunition Set:
Sets the ammunition for the character's current weapon.
LPSP - Get Ammunition Pool Value:
This function returns the value of a specific ammunition type in the character's ammunition pool.
LPSP - Set Ammunition Pool Value:
This function sets the value of a certain ammunition type in the character's ammunition pool.
LPSP - Get Show Reload Prompt:
Returns true if the reload prompt should be visible.
LPSP - Should Show Ammunition Prompt:
Returns true if the ammunition prompt should be visible.
LPSP - Get Alpha Weapon Lag Look:
Returns the value of Alpha Weapon Lag Look.
LPSP - Add Ammunition Pool Value:
This function adds a specified amount to the value of a certain ammunition type in the character's ammunition pool.
LPSP - Add Ammunition Pool:
This function adds a specific amount of ammunition to the character's ammunition pool.
LPSP - On Pick Up:
This action allows the character to pick up whatever they are looking at. However, currently it is only meant for picking up weapons.
LPSP - Get Facing Rotation:
Returns the rotation that the character's camera is facing.
LPSP - Get Component Interactor:
Returns the Actor that the Character is currently able to pick up.
LPSP - Get Ammunition Prompt:
Returns the ammunition prompt text and color.
LPSP - Get Leaning Alpha:
Returns the value of Leaning Alpha.
LPSP - Is Leaning:
Returns true if the character is leaning.
LPSP - Has Leaning Switched:
This function returns true if the character has just switched to leaning on a different side.
LPSP - Is Lowered:
Returns true if the character's weapon is lowered.
LPSP - Get Recoil State Camera:
Returns the value of Recoil State Camera.
LPSP - Get Recoil State Weapon:
Returns the value of Recoil State Weapon.
LPSP - Get Holster State:
Returns the Holster State.
LPSP - Get Viewmodel Animated Offsets:
Returns all the offsets applied while in the air.
LPSP - Get Camera Rotation:
Returns the rotation of the character's camera.
LPSP - Try Start Ability:
Attempts to initiate a game ability for this character.
LPSP - Stop Ability:
Stops a game ability on the character.
LPSP - Can Start Ability:
This function returns true if the given game ability can be started by this character.
LPSP - Is Holding Fire:
Returns true if the character is holding fire.
LPSP - Get Recoil State Weapon Standing:
Returns the value of Recoil State Weapon.
LPSP - Get Camera Unlocked Start Rotation:
This function returns the starting rotation of the camera when it is unlocked.
LPSP - Is Camera Unlocked:
Returns true if the character’s camera is unlocked.
LPSP - Is Camera Fully Locked:
This function returns true if the character's camera is fully locked, meaning that it is not currently unlocked by a player free-looking around.
LPSP - Is Third Person:
This method returns true if the character is currently being viewed by its owning player from third person perspective. However, this does not apply to AI characters, as they are always in third-person perspective.
LPSP - Is Local:
This function returns true if the character is currently owned by a player.
LPSP - Is Fully Holstered:
This function returns true if the character's item is fully holstered, which indicates that it has completed the entire holster animation.
LPSP - Is Unarmed:
This function returns true if the character is currently unarmed, which generally means that their equipped item is completely holstered.
LPSP - Spawn Hitmarker:
This function allows us to spawn a hit marker on the owning client.
LPSP - Is Aiming At Damageable:
This function returns true if the character is aiming at a damageable actor. This is helpful for turning the crosshair red, for example.
LPSP - Get Blackboard Target:
This function returns the Chase_Target actor for this character. It is very helpful when dealing with AI that can chase a target.
LPSP - Is Equipped Ammunition Empty:
This function returns true if the equipped item's ammunition is empty.
LPSP - Update Equipped Item Physical Settings:
This function allows us to update the physical settings of the equipped item. It's basically just a shortcut, as we could already do this from the item itself.
LPSP - Update Field Of View Materials:
This function allows us to update the field of view materials to match the correct values.
LPSP - Is AI:
This function tells us whether the character is an AI or not.
LPSP - Is Moving:
This function returns true if the character is moving.
LPSP - Get Velocity Rotation:
This function returns the rotation that the character should face while moving.
LPSP - Is Tactical Sprinting:
This function returns true if the given character is currently tactical sprinting.
LPSP - Play Unholster Animation:
This function makes the player character to play the unholster animation on the currently-equipped item. We incorporated this function to force-play the unholster after throwing a grenade when unarmed, as it appears more visually appealing that way.
Last updated
Was this helpful?
