Skip to content

ATDRL_GrenadeBase

Klian edited this page Nov 23, 2023 · 2 revisions

Parent: AActor


This is the base class to use for any type of grenade you'd like to implement.

GrenadeStaticData

Similarly to other classes (i.e. ATDRL_Item) this class implement a set of static information about the grenade class.

image

Icon_Name Name: Display name for this object

Icon_Float MaxArchDistance: Max distance the the player can reach with a parabolic throw. If the cursor's distance from player is greater than this value, a linear throw will be used instead.

Icon_Float MaxForce: Max force to apply, this will be scaled by the character's throwing multiplier value

Icon_SoftPtr Icon: Icon used for UI (Soft Pointer)

Icon_Pointer Preview Mesh: Grenade preview mesh, used while the character's holding the grenade in its hand

Icon_Name Socket: The socket this item will be attached to when equipped

Icon_Float Delay: Time delay between receiving the input and actually throw this grenade. Used to calibrate animations independently.

Throw Montage: Throwing action animation montage.

Icon_Float Time Adjustment: Used to anticipate or delay the throwing animation.

Icon_Float Lifetime: Time before exploding (start when the grenade is thrown)

Icon_Class Persistent Effect: Class to spawn after the explosion. Used for effects persisting in the game after the main grenade actor exploded and is removed, like fire.

Icon_Pointer Trail Effect: Grenade trail effect (Niagara)

Icon_Pointer Explosion Effect: Grenade explosion effect (Niagara)

Icon_Pointer Explosion sound effect: Grenade explosion sound effect

Blueprint Examples

image

Glowstick

image

It's just a ATDRL_GrenadeBase with a light attached to it.

Grenade Base

image

Most basic grenade class you can think of. When exploding, it will apply a radial damage and a radial field (used to trigger chaos destructions)

Molotov

image

Very similar to Grenade Base, but this class overrides the explosion timer and triggers the explosion on hit event. It will also spawn the persistent class "fire"