If I shoot a missile through a teleport (with -NOTELEPORT active) using A_ScaleVelocity it will lose the function coming out the other end. Here is a videro showing the issue as well as the code I use for the missile.
TheDarkArchon wrote:I suspect this is a weapons mod, given the demonstration on the teleporter at the end of MAP03, thus using that action would be of no use.
But that's not an assumption is it? I test stuff on stock maps all the time.
Given that actors lose all velocity when teleported, I imagine there's a special case for projectiles to begin with.
And the obvious problem is that the velocity has to be changed to the new direction after teleporting. And as with many other cases (as the recently added option for A_SeekerMissile) the same problem is the culprit: thing->Speed is not the current speed but merely the default speed.
I wonder if any of Randy's new seeker code could be adapted? I'm not sure if simply changing it would bring up any compatibility issues, but I can't think why it would.
Of course it could. That new code does precisely what's needed here (i.e. get a speed value from a velocity vector and uses that instead of thing->Speed)
Yes, it would. The trouble in either case is that when resetting velocity during teleport/seek, the code is looking at the thing's Speed property instead of the actual current speed of the projectile.
Also, the thread title made me do a triple-take until I figured out what it was saying. I assume "will" was supposed to be "when" or "while"
Just tried messing around with some sample maps and teleporting rocket puzzles. I wonder, is it possible to set things up somehow so that the vertical angle does not get preserved across the teleport?
I think it is fine as it is ATM for most uses (and I'm not asking for it to be changed). However, there could be occasions where the rocket (or whatever) needs to come out of the teleport perfectly horizontally. The way it works ATM is that, assuming the player is using freelook, it is very unlikely that they will launch a rocket perfectly horizontally and therefore the rocket comes out of the teleport non-horizontally and this can quite quickly accumulate to the rocket being in a position that scuppers the puzzle.
Enjay wrote:Just tried messing around with some sample maps and teleporting rocket puzzles. I wonder, is it possible to set things up somehow so that the vertical angle does not get preserved across the teleport?
I think it is fine as it is ATM for most uses (and I'm not asking for it to be changed). However, there could be occasions where the rocket (or whatever) needs to come out of the teleport perfectly horizontally. The way it works ATM is that, assuming the player is using freelook, it is very unlikely that they will launch a rocket perfectly horizontally and therefore the rocket comes out of the teleport non-horizontally and this can quite quickly accumulate to the rocket being in a position that scuppers the puzzle.