Staredit Network

Staredit Network -> UMS Assistance -> Running over stuff
Report, edit, etc...Posted by rockz on 2006-02-24 at 18:30:53
I need some help figuring out how to "run over" stuff with a vehicle. Essentially what I plan is to kill the unit if the unit is in front of the vehicle and the vehicle is moving. The problem is, I'm not sure of how triggers run.

I plan on having 2-3 locations on a vehicle at all times. One is very small so that it works like the 'footstep sounds' trigger, to help show that the vehicle is moving. This might not be needed.

The next location moves while the vehicle moves and is a bit bigger than the vehicle itself.

The final location moves while the vehicle moves, but is the same size as the second location. Since it's center location trigger is at a different place, I assume I can put in a trigger beforehand that goes something like this:
Trigger
Conditions:
¤ Player 1 brings exactly 0 vehicle to location 1
¤ Current Player brings at least 1 any unit to location 2
¤ Current Player brings exactly 0 any unit to location 3
Actions:
¤ Kill all any unit at location 2 for current player


Another way I could do this to be a bit more accurately is to delay the centering of location 3.

The other problem with this is that I don't think I can discriminate against what all dies. I know that killing all "any unit" is a bad idea. If I just kill 1, there is a chance that one of the units could get right up next to the vehicle prevent the trigger from firing again.
Report, edit, etc...Posted by A_of_s_t on 2006-02-24 at 19:06:52
use preserve trigger in that trigger up there ^ and put preserve trigger and it will always fire! tongue.gif
Report, edit, etc...Posted by Conquer)Fa( on 2006-02-24 at 19:12:13
I got bored so I made a map to show you the triggers (Attached)

Enjoy smile.gif











Map Name: RunningOverUnits.scx
Report, edit, etc...Posted by O)FaRTy1billion on 2006-02-24 at 21:40:00
Just kill units when the locations recenter with the "footsteps" thing.
So you have the small location, the larger location, and the second larger location.

Always center one of the larger locations, or whatever it is for.

When it leaves the small location, center the small location and the other larger location. Play the footsteps sound and kill units at the larger location.
Report, edit, etc...Posted by rockz on 2006-02-24 at 21:44:47
QUOTE(Conquer)Fa( @ Feb 24 2006, 07:12 PM)
I got bored so I made a map to show you the triggers (Attached)

  Enjoy  smile.gif
Map Name: RunningOverUnits.scx
[right][snapback]433913[/snapback][/right]

Wonderful man. Not exactly how I envisioned it, but it still works.

While it's not really all that important, I'd like to make it so that the vehicle needs to be extremely close to kill it, and to only kill it if it hits it in the front. If you put a civ on the back corner in this map, the vulture will still kill it if it moves away.

Now for the other question. When you move the location, does it always center on the center of the unit (and thus go by pixel), or is it by each tile? I'm pretty sure it goes by pixel, but if anyone knows for a fact (and I'm too lazy now to test it), it would help.

Also, to A_of_s_t, preserve trigger is pretty much a given, so I usually don't bother putting it.
Report, edit, etc...Posted by PCFredZ on 2006-02-24 at 23:12:43
QUOTE(rockz @ Feb 24 2006, 09:44 PM)
Now for the other question.  When you move the location, does it always center on the center of the unit (and thus go by pixel), or is it by each tile?  I'm pretty sure it goes by pixel, but if anyone knows for a fact (and I'm too lazy now to test it), it would help.
[right][snapback]434026[/snapback][/right]

Definitely pixel.
Report, edit, etc...Posted by Conquer)Fa( on 2006-02-25 at 12:41:48
Yeah thanks, no problem.

If you want it to have to be really close to the vulture resize the larger location using starforge to a appropriate size, and as for how you want it only to kill at the front, I have an idea but I don't think it will work.

You could probably have 2 movement check locations, 1 that centers and doesnt do anything and the origonal 1- both 2x1 size. In the centering trigger of the movement check have it so the one that doesnt do anything is centered, then it centers the other 1. Wait nvm sorry that wouldnt work it would probably go to the back.

Sorry, I don't think there's a way to just do the front- but if you make the location smaller using starforge to fit the vulture, it should help. Try out my idea (above) if you want, but I don't think you'll get any results. sad.gif
Report, edit, etc...Posted by Corbo(MM) on 2006-02-25 at 12:50:22
QUOTE(Conquer)Fa( @ Feb 25 2006, 11:41 AM)
Yeah thanks, no problem.
 
  If you want it to have to be really close to the vulture resize the larger location using starforge to a appropriate size, and as for how you want it only to kill at the front, I have an idea but I don't think it will work.

  You could probably have 2 movement check locations, 1 that centers and doesnt do anything and the origonal 1- both 2x1 size. In the centering trigger of the movement check have it so the one that doesnt do anything is centered, then it centers the other 1. Wait nvm sorry that wouldnt work it would probably go to the back.

  Sorry, I don't think there's a way to just do the front- but if you make the location smaller using starforge to fit the vulture, it should help. Try out my idea (above) if you want, but I don't think you'll get any results.  sad.gif
[right][snapback]434404[/snapback][/right]
from what i get you are not so far from reality because, locations do not center on locations you will have to do more like
+first center location that doesn't do anything
+then detect the units like "player x brings at least 1 unit at "location that does nothing"
+then center location "original 1"
and yes the location its always centered on the unit (pixel)

Report, edit, etc...Posted by rockz on 2006-02-25 at 13:54:28
QUOTE(Conquer)Fa( @ Feb 25 2006, 12:41 PM)
Yeah thanks, no problem.
 
  If you want it to have to be really close to the vulture resize the larger location using starforge to a appropriate size, and as for how you want it only to kill at the front, I have an idea but I don't think it will work.

  You could probably have 2 movement check locations, 1 that centers and doesnt do anything and the origonal 1- both 2x1 size. In the centering trigger of the movement check have it so the one that doesnt do anything is centered, then it centers the other 1. Wait nvm sorry that wouldnt work it would probably go to the back.

  Sorry, I don't think there's a way to just do the front- but if you make the location smaller using starforge to fit the vulture, it should help. Try out my idea (above) if you want, but I don't think you'll get any results.  sad.gif
[right][snapback]434404[/snapback][/right]

Going from the back isn't a problem, because i couldn't even get your way to work from the back... But I question the 2x1 location size, because I still want this to work in all directions.
Report, edit, etc...Posted by PCFredZ on 2006-02-25 at 15:07:05
As long as you kill only when your unit is moving and the location is small enough, it should look close enough to running over things in your front (since you can't make a vehicle drive sideways or backwards anyway).
Next Page (1)