Announcement

Collapse
No announcement yet.

[Help] How do I have an ability disabled until the player hits a trigger? (more details inside)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [Help] How do I have an ability disabled until the player hits a trigger? (more details inside)

    Ok, so this script, which was made in the character blueprint, makes it so that when I press the left mouse button, I throw a grenade, which destroys itself within a set amount of time:
    Click image for larger version

Name:	grenade.PNG
Views:	2
Size:	103.6 KB
ID:	1225047


    The "Add Grenade Ability" node or function that you see there, houses this:
    Click image for larger version

Name:	grenade2.PNG
Views:	2
Size:	79.0 KB
ID:	1225048

    Then the SpawnActor Grenade node is linked to this Blueprint Class, which is an actor:
    Click image for larger version

Name:	grenade3.PNG
Views:	2
Size:	119.5 KB
ID:	1225049

    However, what I want to do is to have my grenade throwing abilities disabled at the start of the game. My grenade throwing abilities, I want it to be enabled when I hit a trigger. Hope that makes sense

    So I guess for this to work, I need to figure out how to set the value of that boolean variable when I hit a trigger. But how do I do that?
Working...
X