Help Getting Casting Overlap Event to Overlap Different Objects
I am having trouble getting an object to cast to another object when overlapping other actors. The "WallCraftable" Blueprint is spawned as a child within the "HeroCharacter". I am trying to get it to change a variable in "HeroCharacter" when "WallCraftable" overlaps with another dynamic object.
It does successfully cast this variable change "CanPlace" within "HeroCharacter", but only when the "WallCraftable" is overlapped with "HeroCharacter". I need it to fire if "WallCraftable" overlaps pretty much anything else.
I used the print string command to test and it is generating a overlap event any time the "WallCraftable" object overlaps any other dynamic object, including itself, but it does not change the variable "CanPlace" within the "HeroCharacter" unless it is overlapping "HeroCharacter".
Can anyone help with this? Thanks
asked May 21 '18 at 08:55 PM in Blueprint Scripting
for your specific case you dont want to be using the other actor pin for the object pin on the cast. since you want a overlap with any actor to set the variable then you just need to have a reference to the character as the object in pin. in the example below i used the get player character as my reference, though there are many ways to set a reference depending on the situation. from there you just need to drag off the cast to get the variable you want from that character. you can also set the collision settings on the wall to limit which objects can cause an overlap if you wanted to.
answered May 21 '18 at 09:33 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here