Hey thx for the idea. I use hellion to try and it works. But now here's another challenge. I actually don't want my ability to be exactly like Ember Lance where it pierces through enemies. I want it to collide with enemy when it hits. when no enemy in sight it will continue piercing through.
I guess I want like Void Ray when it collides, when not collide it keeps firing in a line like hellion.
I was afraid you'd ask that as there's no way for a beam to inheritantly filter through units it passes.
The best solution I can think of is to scan for the nearest target using triggers. One way to do this is to first fire an invisible beam at your dummy and have it do some effect on all the units in a line that you want to get damaged. Then check with triggers which units got hit by the effect and pick the closest one to the caster to fire the real beam at. To make the real beam still follow your mouse and not instantly pan to the damaged unit, you might want to place your dummy unit at the damaged unit but with the same angle as the mouse pointer relative to caster. Since it will be the closest unit, it should be the only one affected by the beam's line of fire.
I suppose you may be able to use a persistant effect that goes through all points to the range you want, and for each check for a target, and when you hit one, both make the damage effect create the beam, but also do somthing that triggers a false for the validators for the persistant, causing it to stop. The Caster's ability would have a persistant that applies the second persistant effect in the direction the caster is facing, and require channeling, and a trigger would be used to set the caster's facing. Thats all I can think of.
Hi guys,
wondering if it's possible to do that kind of ability based on mouse click and mouse move in SC2?
Youtube Link here:http:www.youtube.com/watch?v=RPcDtsfe_fo
TIA
Here's what you can do.
You can create an invisible dummy unit at a far range and update its position based on where the mouse pointer is relative to your caster.
You can make your unit fire a beam weapon at your dummy, so the effect will look like the beam is following the mouse pointer.
The Hellion can damage units in a line using its beam so you can probably damage all the units in the path of the laser beam.
Try this approach; I think it might work. I use a similar dummy construct for firing guns at the mouse pointer.
@SexLethal: Go
Hey thx for the idea. I use hellion to try and it works. But now here's another challenge. I actually don't want my ability to be exactly like Ember Lance where it pierces through enemies. I want it to collide with enemy when it hits. when no enemy in sight it will continue piercing through.
I guess I want like Void Ray when it collides, when not collide it keeps firing in a line like hellion.
Any tips?
Thanks
@Maknyuzz: Go
I was afraid you'd ask that as there's no way for a beam to inheritantly filter through units it passes.
The best solution I can think of is to scan for the nearest target using triggers. One way to do this is to first fire an invisible beam at your dummy and have it do some effect on all the units in a line that you want to get damaged. Then check with triggers which units got hit by the effect and pick the closest one to the caster to fire the real beam at. To make the real beam still follow your mouse and not instantly pan to the damaged unit, you might want to place your dummy unit at the damaged unit but with the same angle as the mouse pointer relative to caster. Since it will be the closest unit, it should be the only one affected by the beam's line of fire.
I suppose you may be able to use a persistant effect that goes through all points to the range you want, and for each check for a target, and when you hit one, both make the damage effect create the beam, but also do somthing that triggers a false for the validators for the persistant, causing it to stop. The Caster's ability would have a persistant that applies the second persistant effect in the direction the caster is facing, and require channeling, and a trigger would be used to set the caster's facing. Thats all I can think of.
@Ranakastrasz: Go
Yes, but this approach will require that periods be no shorter than .04 second. Otherwise, it gets buggy.