• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[General] FPS camera

Status
Not open for further replies.
It's technically possible but it will be fairly complicated. First off, the new mouse natives are relative to the terrain, not the screen. This means they only work when the mouse is over terrain. If your mouse is on the skybox in the horizon then it won't work. Furthermore the mouse natives are synchronous which means they will be delayed in multiplayer, which is not good for a camera system. In China they have a couple async natives for mouse position relative to the screen, but we do not.

However, there is still a way, although it's a bit convoluted. The new native BlzGetMouseFocusUnit is async. This means if you lock the camera and display some transparent dummy units on the screen you can get the mouse position in an async manner. It's not easy to do, but it can be done. Personally, I would wait for some proper natives.
 
Status
Not open for further replies.
Top