Using 3D model in 2D platform game

Hi!

I’m currently working on a 2D platformer with pretty high-quality graphics. Now I’ve reached a point where I don’t want to import an infinite number of sprites and would rather display and animate 3D with textures directly.

:white_check_mark: So far, I’ve managed to import my 3D model via a SubViewContainer and a SubView and set the 3D light and 3D camera.

:white_check_mark: The whole thing is displayed in my 2D level without any problems.

:red_question_mark:

What I’m wondering now is, is it possible to pass on the available CollisionMesh of the 3D model upwards in such a way that, depending on the current orthographic view of the camera3d, it becomes a “flat” 2D collision shape and can be used directly in the 2D scene? So that the player can run on it, for example.

If the 3D model rotates, the collision shape would have to adjust automatically.

That’s probably not possible, since 2D and 3D are strictly separated at that point, right?

Jeff

It’s possible to convert a 3D shape into a 2D one, but there’s no built in way to do it, you’d have to code it yourself.

I am curious why you don’t want to pre-render 2d sprites from a 3d though?