Hello,
Here is a screenshot of the construction script.
This construction script basically counts the total number of blue and pink pickups in a level and sets them in the ‘Total Blue pickups’ and ‘Total Pink pickups’ variables respectively based on an editable enumeration. I created this while following a Digital Tutors tutorial about blueprints and wanted to try my own technique of calculating the number of pickups.
However, the construction script is not executing while I am making changes in the viewport. Also, in the event graph, I used a ‘Event Begin Play’ node to print the values of the ‘Total Blue pickups’ and ‘Total Pink pickups’ and when I run the game, the counts are always 0.
But again, when I cut and paste the entire script from the construction script and into the Event Graph, everything works just fine.
There are a few questions :
- Am i doing anything wrong? If so, how can I fix it?
- Are any of the nodes that i have used in the image not meant to be used in the Construction Script?
- Is this a bug? (I have read a few other posts about this sort of Construction script error in the earlier versions of UE4 and there, this behavior is classified as a bug.)
Thank you