#3D Isometric - Rotate "player" to cursor position
1 messages · Page 1 of 1 (latest)
Are you able to get the position of the mouse with relation to the world space yet (assuming you click on the terrain, or something)?
No actually I have nothing related with mouse
I just started a project to learn about Unity and DOTS
That will be the first step. Inside a System (ECS) you will need to use a ray from Camera to mouse position to get the worldspace point you want your player to rotate towards. Once you have that point, the rest of the work is rotating the transform of your player to face towards the direction of the worldspace point from your mouse click.
Oh, welcome! Have you gone through all the tutorials for DOTS yet?
Hum ok, I'll try to dig more in this way !
Well actually I'm new in Unity, and even more in DOTS/ECS, but I'm learning by reading/testing stuff
Any chance you have the samples repo?
https://github.com/Unity-Technologies/EntityComponentSystemSamples/tree/master?tab=readme-ov-file
a few videos there, it will help you answer part of your question especially around rotating your character.
Well it looks messy, because it's just a "test" project to learn about dots
everything is made with entities
very cool actually!
Well, my final goal is to make a vampire survivor like but in 3D
and with a lot more enemies
and why not cooperation
That's why I'm going with DOTS, to be able to manage a lot of entities and still having good performance 🙂
makes sense
But yeah, I have to learn eveything, this is my first time in game dev 😄
the first step is to do translate the mouse click into a world position that your player can face towards.
Educational project that demonstrates RTS mechanics within Unity ECS. - bustedbunny/RTSDemo
I have an example repo with similiar functionality
turret has to aim at target position, which is cursor
is BustedBunny you, @signal sky ?