Hi I’m recently chose ue4 and never look back…I’m pro at c# and unity
My question : 1…how remove a component from a blueprint witout remove it from other objects have same blueprint
2…how can put 2d/3d collision in ui element like image (for a complex inventory ststem)
3…how can drag and drop blue print for work on another object
4…how change default player(I want my character be default player at start) and how set a camera as main rendere
5… How define a object from scene in bluprint (like "public Gameobject obj; " in unity c#)
Thanks for help…
-
Keep in mind that Blueprints are not prefabs (e.g. not instances), they are classes. So if you make a blueprint with a component, then derive a child blueprint from it, then remove the component from the parent blueprint, it will be also removed from all children. If you want to keep it for some children, you should make a basic blueprint (
Basic_BP) without the component, then make a child from it (e.g.BasicPlus_BP) and add the component into it. So you will be able to derive new blueprints either with the component (derive fromBasicPlus_BP) or without (fromBasic_BP). -
In general, UI widgets (UMG) can’t interact with the world objects. You can either make an actors with Widget Component in the world, or use traces from screen projection to the world (and vice versa).
-
This is again about the difference between blueprints and prefabs. Blueprints are like classes in c++ or c#, they are not instances. So you can either duplicate a blueprint (will not be connected to the original one) or make a child blueprint (will inherit all the stuff from the parent one)
-
To change the player character, you should make a custom GameMode and select it as your game mode in the project settings. Not sure what’s is the “main renderer”, though Unreal will try to automatically use camera from inside of the player character, if any. Or you can add a separate camera actor to the level and use it as the main camera (look for the option: “Auto Activate For Player”)
-
Inside the blueprint, add a variable with the requred class (e.g. Actor reference or anything else), set the checkbox “Instance Editable”, place the blueprint to the level, choose in in the Inspector. You should be able to select objects from a dropdown menu.