Really neat design pattern and answered a few questions I had about how to not duplicate the creation of objects and reuse. Another great video added to this series. Keep up the great work Matt!
Thanks for the question. It's almost valid, would have to do it slightly differently for that to work but obviously we didn't do that one in the end. A valid way would look like: static struct {} var_name;
Same thing as for C, that defines a structure and the static instance of it within current compilation unit with main(). It won't be accessible via "extern" declaration from other compilation units.
Really neat design pattern and answered a few questions I had about how to not duplicate the creation of objects and reuse. Another great video added to this series. Keep up the great work Matt!
Awesome, thank you!
hello, will you continue rpg playlist, making opengl graphics for it?
What does the “static struct” definition do? I didn’t think that was valid in c++
Thanks for the question. It's almost valid, would have to do it slightly differently for that to work but obviously we didn't do that one in the end. A valid way would look like: static struct {} var_name;
Same thing as for C, that defines a structure and the static instance of it within current compilation unit with main(). It won't be accessible via "extern" declaration from other compilation units.