Hey!
What would be your recommendations to build a project upon the new Lyra Starter Game?
Probably best to split this question into multiple parts:
Code
-
When I create completely new gameplay-related C++ classes, should I add them to the LyraGame module, or should I make a new gameplay module that depends on LyraGame?
-
In general, when I create my own gameplay-related classes like pawns or characters, should I inherit from Lyra C++ Classes, like “LyraCharacter”, or should I rather create a duplicate of “LyraCharacter” and rename it?
I fear that if I inherit from Lyra classes, every future engine and LyraStarterGame update might mess up my game, and I think it would be good to keep the engine and Lyra updated as long as possible while developing my game.
So I think I currently prefer creating duplicates of Lyra classes and renaming them, then hooking up everything in the game to my duplicated classes, and when Lyra gets an update, my game does not break, and I can manually copy over the changes from the new Lyra files.
When my duplicated classes get messed up by an engine update, I can also just have a look at the new Lyra version and see if some changes there solve my issues.
What do you think about that? Is that approach dumb?
Content:
-
I think the folder structure and naming conventions in Lyra are pretty good. Currently, I think it would be best to just use the existing folder structure and put my new stuff in the same folders where the Lyra Starter Game stuff is located.
My own main menu widget blueprint would then be located under “Content > UI > Menu”, in the same folder as “W_LyraFrontEnd”. -
Most of the asset names from the Lyra Starter Game contain the term “Lyra”; some of them don’t, unfortunately, like “MI_UI_TitleMaterial” or “W_UserWatermark”. To keep things a little bit more organized, I thought about putting all files from the Lyra Starter Game into a “Lyra Collection”.
Sadly there is no function to hide objects in the content browser that are part of a certain collection, but at least I can see that a file came from Lyra when I hover over it. -
Then there is the inheritance vs. duplicate question again, pretty much the same as with the C++ class duplicates. My gut feeling tells me that it would be good to keep the Lyra files as they are and only modify duplicates from them (or create new ones from scratch that have similar implementations of certain things).
If I create children from the Lyra blueprints, a Lyra update might mess up my game, and editing the existing Lyra files is probably also not a good idea, as every update would then overwrite my changes.
I also noticed that quite a lot of content is put into plugins, like “ShooterCore Content” or “LyraExample Content”. Not sure why though, and how I should tread those in the future.
Well, these are my thoughts so far. What would be your recommended way of building a game upon the Lyra Starter Game? Maybe some kind of “Build upon Lyra best practices” would be a good tutorial or a good addition to the Lyra documentation.
Thanks,
Sascha