Download

ELI5: High-level steps to create car that doesn't use official Vehicle code

I would like to migrate my game project from Unity to UE4. It’s an arcade car combat game, physics-based (with cartoony physics). In Unity, my car is literally a box that slides along the ground via two “arcadeWheel” components (rear handles thrust, front steering). Friction is calculated entirely based on the orientation of the “wheels”, so I can do things like have infinite grip, etc.

All that to say: the only examples I can find for implementation of vehicles utilize the built-in Vehicle framework. I totally get it, it’s the right solve for 98% of stuff, and I’m sure an invaluable learning tool. But I’m having trouble applying it to my problem.

So then I thought “I’ll just make it a character, with a box for collision.” But then I noticed that the tooltip for a Character mentions things like swimming and walking around. So now I’m not sure if I’ll end up fighting it the whole time to make it a car.

(if you made it this far, thanks!) TL;DR: I’m happy to go learn for myself, but I am so unfamiliar with this toolchain that I don’t even know how to identify the right path to take here.

So does anyone have advice as to where to start, or whether I’m going about this wrong (I’m fully prepared to accept that, haha).

Thanks

Definitely not able to explain the whole thing as I’m probably only 1 or 2 steps beyond where I believe you would be in my UE4 knowledge - but I’d start with an Actor rather than a Character.

You’ll probably need to implement the Tick functions (if you need them) and do the input binding yourself but it’s reasonably straight forward from there. Take a look at the character examples in the 3PP templates if you need to see how that’s done - just be aware that much of the movement implementation in those examples occurs in the engines character.cpp - and thus isn’t able to be edited, only overridden

Pretty much unless your character is a human or human-like being that walks, runs and swims (and for some reason flies!) then you’ll need to write your own movement - and the Actor class is a much cleaner slate to start from

Mootjuh: that’s the post that was the basis of my entire vehicle approach in unity. It’s a fantastic resource! I think I just need to make a toy game in UE4 first, because the concepts described in the linked post are simple to program once one understands the engine itself.

Shambler2: Thanks for the in-depth reply! I’m attempting to use the Blue Man Vehicle plugin at the moment, but my fallback is to basically do exactly what you suggest. The only reason I’m not doing that immediately is that I was warned about the necessity to write my own network replication / rollback code if I went that route. Network code is my kryptonite (at least in my real job as a devops engineer) so I’m hoping to avoid that.

Thanks both of you for taking the time to respond, it’s really appreciated.

congrats on taking the plunge. Youll be happier in the long run. Your in the right place with the blueman vehicle physics pack.
Hes constantly answering peoples questions and supporting the products he sells. You cant beat customer service.
There are some good racing kits in the mp.
There is also one example provided by epic under the learn tab of your launcher. Heres a link to another downloadable project. https://m.youtube.com/watch?v=2o1xSxEIODE
those 3 projects should give u a good start.