• 🏆 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!

How to get the future position of an unit?

Status
Not open for further replies.
Level 1
Joined
Oct 30, 2004
Messages
5
In my map, there is an alchimist walking around a square. Below that square, an unit shoots at the alchimist. The missile does not follow the alchimist's movement, it can be only targeted at points. But: When the missile impacts, it should exactly hit the alchimist!

So the unit has to shoot at the position of the alchimist that he will have when the missile arrives. To know that position, I need to know the time between missile spawn and impact... and you get the time with:
Distance between missile start point and target point / Missile speed (700)

So I can only know the time that the missile will fly if I know the shoot distance! But to know the distance, I need to know the time!
:( Does someone have a solution maybe?
 
Level 8
Joined
Apr 3, 2004
Messages
507
Test the projectile speed and movement speed in a simple map, and try to find one that crosses the distance in an easy-to-track time, like one second. Figure out what the conversion would be between the speed and the distance, and then you have your coefficient.
 
Status
Not open for further replies.
Top