[JASS] Idds

Status
Not open for further replies.
Level 10
Joined
Jan 21, 2007
Messages
576
Alright so I am making a map and was looking around for a good damage detection system and I found Rising_Dusk's Intuitive Damage Detection System.

Now this is very customizeable, and is pretty sweet. But the only problem is all damage has to be triggered, which wouldn't be that big of a deal except for abilities that have a missile art =/. How would I go about creating making a spell that knows when the missile hits and then damage the unit =O? Or is there something I am missing =/?
 
Level 11
Joined
Feb 22, 2006
Messages
752
Find some kind of projectile system. An ACTUAL projectile system that simulates wc3 projectiles.

At the risk of sounding self-serving, I have a projectile system currently in the Jass submissions section called (xe)projectile. It requires the xe modules (actually just xebasic and xefx).

If you don't like that there's always CasterSystem and its projectile functions.
 
Level 10
Joined
Jan 21, 2007
Messages
576
What is the eventlistener to signal that it is at its target?

EDIT: Bleh "eventlistener" my actionscript is coming out, how do you know when the projectile "hits" it's target?. Do you check if the target is within range? If so you would have to store the damage amount, and types ect. for however long it takes for the projectile to hit. Sounds like something I'm wouldn't really be confident making successfully yet (at least on my own) thanks for the direction though.
 
Level 5
Joined
Dec 18, 2007
Messages
205
another option to detect a missile is to make the missile an ability like "poison arrows".
then you have to detect whether a unit takes damage and has the buff of the "poison arrows". if yes, remove the buff and deal he damage, if not do nothing.
but then you would have to trigger all missiles in the game, ouch!
greetz
 
Level 11
Joined
Feb 22, 2006
Messages
752
What is the eventlistener to signal that it is at its target?

For CasterSystem, I think some of the functions block until the projectile reaches its target (not sure though since it's been 2 years since ive used CS, but that was how it was at least in 14.x).

For my system, you override xeprojectile.onHit(). That method is called when the projectile hits its target.
 
Level 10
Joined
Jan 21, 2007
Messages
576
For CasterSystem, I think some of the functions block until the projectile reaches its target (not sure though since it's been 2 years since ive used CS, but that was how it was at least in 14.x).

For my system, you override xeprojectile.onHit(). That method is called when the projectile hits its target.

=/ kind of restates my question lol, how do they know when the projectile reaches its target haha?
 
Level 11
Joined
Feb 22, 2006
Messages
752
Well, you don't really need to know how they work to use them, but...if you're curious...

Both systems use a periodic timer. The timer is used to move the projectile and every time the timer callback is called, it will check to see if the projectile has reached its target (the projectiles are just dummy units, so they simply compare unit coordinates and such). CS simply has its functions block the thread until the projectile reaches the target. My system calls xeprojectile.onHit() when the projectile reaches the target.
 
Level 10
Joined
Jan 21, 2007
Messages
576
Ah, ok. How do they go about associating the specific target, with the specific projectile over extended periods of time? Or is that something there is a tut on / would be to complicated to explain because I understand both ways.
 
Level 11
Joined
Feb 22, 2006
Messages
752
Not sure how CS does it now since I haven't looked at the code for a bit. But my guess would be storing the info in structs.

My system does the same thing. It treats every projectile as a struct instance and does all the work on the struct, which contains info on the projectile's location, its target coordinates/target unit, its effect model, etc. The struct instance persists as long as the "projectile" exists, so the system can always get the info it needs.
 
Level 10
Joined
Jan 21, 2007
Messages
576
Sounds interesting, your system is a lot more focused on what I need so I will probably look it over and learn some stuff later tonight, but I am a bit busy atm. Thanks for all the info =)
 
Status
Not open for further replies.
Top