• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Options for dummy projectiles

Status
Not open for further replies.
I have a pretty basic question which i'd just want to hear some suggestions one. Basically, i want to make a grenade-like spell with a dummy projectile. By "dummy projectile", i mean that i want to use a spell which has projectile art. I want to know what spells work for this, and how you'd do it.

I know that one approach is to create two dummies, and have the one cast a spell based on acid bomb (for instance) on the other. To trace when the projectile hits, you just use a timer to wait (distance)/(missile speed) seconds. However, this requires the second dummy to be selectable, which feels a bit lame. What other options are there? Are there any good ground-targeting abilities which can be used without side-effects?

Also consider that i want to be able to use two similar abilities on one unit, so i may have to use a dummy spell for the targeting (to avoid collisions between spell orders).
 
Level 24
Joined
Aug 1, 2013
Messages
4,657
Why not use a missile system?

Otherwise, the rocket barrage (or something like that) of the tinker/mechanic could probably do it.
I don't know if the shaking part is hardcoded in the ability or the model just like the basic attacks of a dragon rider.
 
I do have a custom missile system - the problem is how to calculate what launch angle is required to hit the target point. The missiles have both inertia and air resistance, and the shell is supposed to be launched at a high angle. This is why i am considering using the default wc3 projectiles instead.

I also considered using cluster rockets, but it has so many effects and extra stuff which might have unwanted consequences.
 
Level 24
Joined
Aug 1, 2013
Messages
4,657
Yea in logic rules it is pretty dumb what I said :D
However that is how warcraft works. If you want to hit a target that is further away then you just put more power in your arrow and fire it with the same angle.

For your arc you can do something like "0.1 + 0.001 * distance" for example and just try some stuff.
I am too lazy to search for my formula list that I made for stuff like this but that one would look better than it sounds.

btw about the Acid Bomb, you can use a DDS to detect when the unit has taken damage and you don't have to select the unit. You can simply hide the unit but still target it I think.
 
Yea in logic rules it is pretty dumb what I said :D
However that is how warcraft works. If you want to hit a target that is further away then you just put more power in your arrow and fire it with the same angle.

For your arc you can do something like "0.1 + 0.001 * distance" for example and just try some stuff.
I am too lazy to search for my formula list that I made for stuff like this but that one would look better than it sounds.

btw about the Acid Bomb, you can use a DDS to detect when the unit has taken damage and you don't have to select the unit. You can simply hide the unit but still target it I think.

No, it is not how warcraft works. Warcraft has fixed projectile speeds, as you specify them in the object editor. The problem about having variable velocity is that the shells can fly really, really high, and also that it is hard to check collision with high velocities. Not to mention, it looks super weird to have mortar shells or grenades flying at supersonic speeds just because the target is farther away. You also need to consider the complexity of the situation - when you are working with acceleration and air resistance, velocity is not linear. You might even say that a parabola is non-linear by definition. Therefore, you can't rely on having a linear solution to the problem.

@MechanicalMan: I looked it up and did not feel convinced. Really, all i want is a simple and flexible way to make a dummy unit fire a missile at a ground point. Preferably without having to target another unit or dummy, and it doesn't really need to spawn anything. I can do all that with a script.
 
Level 24
Joined
Aug 1, 2013
Messages
4,657
Uhm... I said arc decrease will be slowed... not the missile speed.

Lets say that a unit attacks with a missile with 15% arc.
Then it decreases arc from 15 to -15 over the duration of the flight.
If that duration is 3 second then it decreases with 0.3% every 0.03 seconds.
If that duration is 300 then it decreases with 0.003% every 0.03 seconds.
The arc decrease is slower and thus the height will be higher.

This also cannot be predefined. Look at a homing missile, that one will decrease slower if the target moves away and faster if the target comes closer... it should be at least.
 
Level 21
Joined
Mar 27, 2012
Messages
3,232
I don't recommend trying to work with true velocities(vertical and horizontal velocity combined), as it breaks very easily with any kind of tracking AI.
The game uses velocities that are defined by the horizontal velocity and thus, gravity and initial vertical velocity are defined at launch time. However, with this approach you do not need to factor heights in at all for tracking.
 
Hmm, i think you have all misunderstood. What i am asking for is not how to replicate the wc3 projectile system. I have a projectile system already which i am quite content with. What i want to know is what ability is best to use as a dummy ability for a spell projectile. In this case, i want to launch a gas canister to a target location, without using simulated projectiles, just regular wc3 projectiles.
 
Status
Not open for further replies.
Top