Get all actors of a class
dumb question alert ....,
I have setup up this hierarchy of Pawn classes : Chess piece parent ->Dark Piece -> Dark Knight ...... ......the " Chess piece" pawn class being parent of the "Dark Piece" class and the latter being parent of the "Dark Knight" class ........all good .......
the funny part here when i put 3 instances of the "Dark Knight" class ,and run get all actors of class ("Dark Knight" class ) in its event graph and print the "for each loop" , i should get only 3 actors , but instead i'm getting the 3 actors multiple times ......... .....as shown in a screen capture of the print result i took below.......
...Thanks for any help appriciated in advance ....
Each dark knight is separate instance and will fire its Begin Play separately, you should see 9 Prints here. If you see more, then it's weird.
If you put this code in the Level Blueprint, Game Mode or any other framework classes, you'll see it print 3 times.
Follow this question
Once you sign in you will be able to subscribe for any updates here