-
Notifications
You must be signed in to change notification settings - Fork 16
SKGShooterPawnComponent
This component is what gets added to your pawn and allows you to easily interface with the rest of the system. It is where you Set and Get the held actor that is to be used with the rest of the system and has helper functions to get access to the current held actor's SKGFirearmComponent, SKGProceduralAnimComponent, SKGOpticComponent, etc.


This is the class to use for the procedurals that inherits from my anim instance. This is useful if you want to utilize the linked anim layer setup for a cleaner anim graph.
If true, the Linked Anim Layer Class will be automatically setup.
If true, Third Person Mesh Component Name or First Person Mesh Component Name will be used (whichever one it finds) rather than both and treats them as the same.
This is the name of your third person mesh on your pawn. In the ACharacter class this defaults to CharacterMesh0.
This is the name of your first person mesh on your pawn. You do not need a first person mesh if you are doing true first person.
The name of your camera component on the pawn.
The name of the socket that your camera gets attached to.
Since unreal by default does not replicate your yaw, I have provided a system that lets you get a replicated control rotation (pitch and yaw are compressed into a Byte and uncompressed when received).
The rate at which the Yaw will be replicated. It only gets replicated when the mouse moves via the SetMouseInput function (also used for deadzone).
Usage covered in the Night Vision section of the Wiki.

If true, this will auto set whether or not your pawn has bUseControllerRotationYaw enabled.
How much you can rotate in the corresponding directions from center when free looking.
How much you can lean to the corresponding angle.

If true, it will utilize spring interpolation for the to/from when leaning/unleaning.
Google these as they are standard for all spring interpolation.
This is the max angle you can lean left/right. The max is 45 due to compression, however you can stack this with more than 1 lean node in the anim graph to lean as far as you want.

This is specific to firearm collision, but it will print out the hit actor to the screen from the firearm collision trace.
This is specific to firearm collision, but it will draw the debug trace of the firearm collision trace.
This function is core to letting actors (such as firearms) interact with the system. When you pickup a firearm, SetHeldActor must be called.
This function is core to clearing the actors from use. For example when you drop a firearm, ClearHeldActor must be called.
This function will link the set Linked Anim Layer Class to the anim instance.
This function will link the set Linked Anim Layer Class to the specific anim instance passed into the function.
This function will unlink the set Linked Anim Layer Class from the anim instance.
This function will unlink the set Linked Anim Layer Class from the specific anim instance passed into the function.
These functions check to see if you can apply more yaw/pitch when free looking or if you have hit the max limit.
When called, this function will start the system for free looking.
When called, this function will stop the system for free looking.
This function will return true if you are currently free looking, will return false otherwise.
This function is required for use with deadzone as it runs on the received moused input. Takes in the X and Y from the mouse input.
This function will return the given multiplier for you to use with your input (X and Y) for the mouse. It lets your mouse sensitivity scale with the magnification/zoom amount.
These functions take in a TargetAngle, this angle is the goal in which you want to lean to. This allows for incremental leaning.
These functions will stop the lean from the given direction.
This function returns the current target lean angle (the angle your trying to lean).
This function will start aiming with the given held firearm or optic.
This function will stop aiming with the given held firearm or optic.
This function will return true if you are currently aiming, false if you are not.
This is the default. Basically it will make the set procedurals use the first person settings for the local client.
This function will make the set procedurals use the third person settings for the local client (useful for third person mode).
This function will change the amount of sway you have. This is useful for injuries and steady aim.
This function will reset the sway multiplier back to it's default.
This will return true if you called SetSwayMultiplier without resetting it (using a value different than the default).
This function will perform procedural recoil using the given settings from the SKGProceduralAnimComponent on the firearm.
This function will trigger the pose (if found) given by the passed in gameplay tag. If bExitPose is true, it will perform the exit pose of that pose.
This function will trigger a curve to play based on the passed in CurveData.
This function will change you from using right handed procedurals to using left handed procedurals.
This function will change you from using left handed procedurals to using right handed procedurals.
This function will return the pose data (if found) from the passed in gameplay tag.
This function will trigger the infrared mode from the SKGShooterWorldSubsystem which will switch registered infrared devices (like the LightLaser) to infrared mode if they support it. It will also auto set the values in the Material Parameter Collection. Long story short, when you enable night vision just call this function.
This function will trigger the infrared mode from the SKGShooterWorldSubsystem which will switch registered infrared devices (like the LightLaser) to normal mode from infrared mode (if they are in it and if they support it). It will also auto set the values in the Material Parameter Collection. Long story short, when you disable night vision just call this function.
This will return the currently held SKGFirearmComponent.
This will return the currently held (or from a firearm) SKGProceduralAnimComponent.
This will return the currently held (or from a firearm) SKGOpticComponent.
This will return the currently held (or from a firearm) SKGLightLaserComponents.
This will return true if the owning pawn of this component is the local controller.
This will return true if this component is set to use first person procedurals for their local client.
This function will return the control rotation if you are the local controller, if you are remote it returns a custom replicated rotator that mimicks the control rotation.
This will return the current procedural data specific to the pawn for use in your own anim graph such as the current held actors ProceduralAnimGameplayTag, bOffHandIKIsLeftHand, and FreeLookLookAtRotation for freelook.
This function will return the stored camera component.
This function will return the First Person Mesh if locally controlled, otherwise it will return the Third Person Mesh.
This function will return the owning pawn of the component.
This function will return the set SKGShooterFrameworkAnimInstance.
This event fires when a pose has been completed (start to end or end to start).
This event fires when the HeldActor is changed.