Add to Player Screen not working as I expected
I am attempting to set up split screen for my game for testing purposes. I am trying to get 3 different in game HUD's to display. I am using Add to Player Screen as it was recommended for split screen. My blueprint looks correct to me, but the HUD's are still displaying the same way as when I used add to view port. Instead of HUD being in each persons smaller viewport it is displaying as if the whole screen is each persons view port. I have attached some images showing you what it looks like in game and the blueprint I am using. Thank you for any help. (Edit: I do not know why images are not displaying in the post. Let me know if you cannot access the images.) ![alt text]
The bar I circled is supposed to be near the bottom left. As well as the bars not being scaled down. Am I musunderstanding how Add to Player Screen works? Let me know if you need more information. : /storage/temp/124503-capture2.png
If you are trying to create the widget inside the Player Controller 'BeginPlay' event as the live training did you will see an error on the console... 'CreateWidget cannot be used on Player Controller with no attached player'. This is why the HUD isn't appearing for the extra players.
What I did was to add some logic to the Player Controller which checked if the HUD variable is valid, and if not, create the widget before it calls 'Spawn Character' on the game mode. You also need to un-hook the widget creation from the BeginPlay event.
answered May 09 '17 at 11:33 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here