In game variable.
Is there any method to create variable in game? For example, player starts game and event begin play creates new virable with pre-conceived or random variable name.
asked Nov 30 '16 at 09:27 AM in Blueprint Scripting
You can, sort of. If you make two arrays, one with the names and one with the value or you make one array with a special tuple class holding both the name and the value you can simply add to that array. This is as close as you can get though.
answered Nov 30 '16 at 11:10 AM
I don't think you can create member variable during runtime (it's the same as C++, you can't modify class during runtime :D). But maybe you are looking for nodes like Make TEMPORARY_VARIABLE_TYPE for example you can create a float in the blueprint using Make Literal Float and do whatever you want with. However, like any scoped variable in C++, it will be destroyed at the end of your current exec line.
Good luck, best regards.
answered Nov 30 '16 at 09:53 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here