question

andre-wagner avatar image
andre-wagner asked

Get Player Statistics always crashes the UE4

Every time I press "C" on the keyboard the engine crashes.

Has anyone an idea how to get the player statistics right without crashing the engine

Thank you, in Advance

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

v-humcin avatar image
v-humcin answered

Using "Make Array" with no entries in your request seems to be causing a crash. If you are not using that field it would be better to uncheck the "as pin" option in details for the request otherwise you wish to leave it as a pin, you can promote it to variable and leave that null it will also relieve the crash.

Beyond that you will need to specify a field name in "Get Field" to get a specific piece of data.


2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

andre-wagner avatar image andre-wagner commented ·

Thank you that works, and when I type in "Value" as field name, it works, when I click "C" in the game and i get the value back, but when I type in "Name" or "Key" to get the name of the Statistic and I click "C" in the game, I get nothing back. Is the field name wrong or is it my setup ?

0 Likes 0 ·
v-humcin avatar image v-humcin ♦ andre-wagner commented ·

The field that you would use to get the name is called "StatisticName". In general there are two main ways to make sure you are accessing the correct field, checking the documentation or using "Get Field Names".

In the GetPlayerStatistics documentation, we can see that the result holds an array of "StatisticValues" which have three fields. You can also use the "Get Field Names" blueprint to check what fields are in an object at runtime if you are not sure what fields would be present. Hope this helps!

0 Likes 0 ·
andre-wagner avatar image
andre-wagner answered

It did thank you

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.