i am watching tutorials for a couple of days now, but i can not understand how the programming with c++ in Unreal really works ^^ (Very confusing with header and source file and the whole Ustuff in there).
I have previously used the Unity engine where it is very simple (i am able to develop a complete game) but unreal engine is so much different.
If i search for some sampels i only found someone who is modify some existing content, but i want to learn it from scratch to understand it better how it works.
Can someone give me a sample for spawning a Gameobject like a cube and control the cube with the WSAD keys in c++ ?
I didnt found anything like this.
In Unity this is very simple i only need to define a Transform using a command āinstantiateā and then use if sentence for keyinput,
if one sentence gets true i can use thespawnedobject.translate(vector3) in this if-sentence.
That said depending on how quickly you learn it can take anywhere from a couple weeks to a couple months to be up to speed. Stick with it though, its totally worth it !
First of all, if you come from Unity, welcome to real world.
Before starting you should read the documentation and watch some videos from Unreal Youtube channel to make an idea. Also get familiar with Blueprints, you can do everything with them with out touching a C++ line.
Unity gives you some false ideas about game development and development in general, thatās why you have trouble now to understand Unreal. You just need to familiarize a bit with Unreal.
Emā¦I think pretty much everyone forgot to say that Unreal uses C++ while Unity uses C#ā¦how do you expect to code for Unreal when you donāt know C++? Also, if you have no idea why we have headers and stuff like thatā¦you should either just use blueprints, or buy a c++ book.
@noatom: Thank you for you comment, i know that unity is using C#, but that should be no problem. I learn programming language by doing some stuff, and look at some examples, that is the reason why i like samples and tutorials. :D.
Yesterday i have learned what headers are, and i was able to test some stuff.
But now i am confronted with another problem. I am using Visual Studio and the intellisense is very very slow and sometimes it didnt work, what can i do to fix that?
The Monodevelop(Programming Editor) from unity when using monobehaviour is very fast i only need to press the first letters of the command and press return and get the complete command, does this works with C++ Unreal Engine ?
Intellisense doesnāt work very well with large C++ Code-Bases, which UE4 definitely is.
There are some plug-ins that exists if you have VSPro though, though their name escapes me right now. If anybody does have ay methods for radically speeding up the Intellisense, Iām eager to here it as well.
Try Visual Assist X (also known as VAX by in the Unreal Engine 4 documentation) for better intellisense in C++. Itās not free, but I feel itās a must-have if youāre serious about exploring a large codebase. It has better auto-complete, better syntax highlighting, the ability to switch between a .cpp and a .h for a class with a keypress (you have to setup shortcuts yourself in Visual Studio), and if you press ā.ā at the end of a pointer, itāll automatically turn it into a ā->ā. There are a lot of other features, but those are just a few off the top of my head. I suggest you try the trial and see how it works out for you.
Also my suggestion is donāt get scared by C++, as UE4 C++ is a simplified form of C++, just try to modify the examples to create your own actors, do the rest in blueprints.
Remember also Unity looked complex with the Transform/component architecture, vs Inheritanceā¦
What helped me is realizing that coding everything isnāt the way to go. Almost every C++ tutorial ends up turning the values into Blueprint Ready nodes (UPROPERTY, UFUNCTION) anyway. Familiarize yourself with Blueprints, then when you need additional functionality, try your hand at the C++.
Exactly. When I started using the unreal engine, I said : āI want to do only the coding, I donāt want to touch to blueprint, this is for lowly level designerā (just kidding, level designer out there :D)
Then I also realized that the blueprint are pretty awesome if correctly used. So donāt hesitate to try some blueprint tutorial