Code:
N@Proximity Mine
I@Xin Yin Zin TimerIn RangeIn TargetIn Unlocked
O@Xout Yout Zout EngineOn VectorOn Detonate TimerOut
interval(1000/60)
TargetIn == 1 & TimerIn < 3 & A == 1 ->
TimerOut = 1,
Xout = 0,
Yout = 0,
Zout = -100;
VectorOn = 10000,
TargetIn == 1 & TimerIn > 3 & A == 1 ->
VectorOn = 10000 * (TimerIn > 1.8),
Xout = Xin /-1,
Yout = Yin /-1,
Zout = Zin /-1;
TargetIn == 1 & RangeIn < 50 & TimerIn > 3 & A == 1 ->
Detonate = 1;
TargetIn == 0 & TimerIn > 3 & A == 1 ->
Detonate = 1;
Unlocked == 1 ->
A = 1;
I'm interested in porting this to Expression2 and pushing it into a combined vector, but I'm not sure how to get the direction vector of the target, like this expression uses. I looked around the wiki and played with the expression for a while, but I can't figure it out
. Anyone know how to get the direction vector of a target?
Bookmarks