DIY
I cannot for the life of me figure out how to create an expression gate that outputs the X, Y, Z coordinates of a position 15000 units in front of the entity. Any help would be appreciated.
DIY
Well this was my attempt... but it always seems to point to pretty much the same place which is not in front of the missle launcher...
<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-spacere;overflow:auto'>N@Missle Control
I@Pitch Yaw Fire
O@X Y Z Launch Lock Latch
Fire == 0 -> Lock = 0, Launch = 0;
Fire == 1 -> X = 150000 * cos(Yaw), Y = 150000 * sin(Yaw), Z = 150000 * sin(Pitch), Lock = 1, Launch = 1;</div>
I'll give you full vector solution tomorrow, when I come back.
I'm still meaning to vector gates and shit some day.
"Our death ray doesn't seem to be working. I'm standing right in it, and I'm not dead yet." - Jamie Hyneman
"Yes, managing the anonymous activity of the entire Internet is a challenge. Shoving the entire universe into a mason jar for use as a personal flashlight would also be a pesky bother." - Karl, BBR
WIREMOD WILL NOT WORK ON YOUR FACE! BUT IT DOES ON YOUR MOM :shifty:
All you need is for the expression to point the right way.
Code:O@X Y Z Length = 50000 Position = vecadd(extpos(),vecsmul(extdirfw(),Length)) X = vecx(Position) Y = vecy(Position) Z = vecz(Position)
Everything can be improved upon. Nothing is Perfect.
The only way to move forward, is to surpass what has already been done.
Creator of many things.
Bookmarks