- Joined
- Feb 18, 2007
- Messages
- 216
So I'm making zombie shooter kind of map, and I have problems with shotguns. I have two types of shotguns in my map, normal and super shotguns, and both have the same idea: firing multiple carrion swarm-spell based projectiles in multiple directions. The main spell is based on carrion swarm also. Shotgun fires the main projectile (the one fired by the caster itself) and four dummy projectiles (carrions swarms casted by dummy units) and Super Shotgun fires six dummy projectiles in addition with the main projectile. The problem is that normal shotgun sometimes fires only three dummy projectiles and all go to weird directions like this:

The blue projectile is the main and green ones are dummies. Super Shotgun never fires more than four dummy projectiles (it should fire six) and they also usually go to weird directions like this:

Here are the triggers, I would use loop but then there would be fired extra dummy projectile that would go same direction as the main projectile.

Anyone have and idea what could be the problem? And yeah I know it leaks, I will fix them when I manage to get this work as it should.

The blue projectile is the main and green ones are dummies. Super Shotgun never fires more than four dummy projectiles (it should fire six) and they also usually go to weird directions like this:

Here are the triggers, I would use loop but then there would be fired extra dummy projectile that would go same direction as the main projectile.
-
Fire Shotgun
-
Events
-
Unit - A unit Begins casting an ability
-
-
Conditions
-
(Ability being cast) Equal to Shotgun (Fire)
-
-
Actions
-
Set shotgun_point = (Target point of ability being cast)
-
Unit - Create 1 Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) + 22.50) degrees)
-
Unit - Create 1 Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) - 22.50) degrees)
-
Unit - Create 1 Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) + 11.25) degrees)
-
Unit - Create 1 Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) - 11.25) degrees)
-
-
-
Fire Super Shotgun
-
Events
-
Unit - A unit Begins casting an ability
-
-
Conditions
-
(Ability being cast) Equal to Super Shotgun (Fire)
-
-
Actions
-
Set shotgun_point = (Target point of ability being cast)
-
Unit - Create 1 Super Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) + 22.50) degrees)
-
Unit - Create 1 Super Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) - 22.50) degrees)
-
Unit - Create 1 Super Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) + 11.25) degrees)
-
Unit - Create 1 Super Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) - 11.25) degrees)
-
Unit - Create 1 Super Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) + 33.75) degrees)
-
Unit - Create 1 Super Shotgun Dummy for Player 1 (Red) at (Position of marine) facing (Angle from (Position of marine) to shotgun_point) degrees
-
Unit - Order (Last created unit) to Undead Dreadlord - Carrion Swarm ((Position of (Casting unit)) offset by (Distance between (Position of (Casting unit)) and shotgun_point) towards ((Angle from (Position of (Casting unit)) to shotgun_point) - 33.75) degrees)
-
-

Anyone have and idea what could be the problem? And yeah I know it leaks, I will fix them when I manage to get this work as it should.