followspline and its length argument


(Malverik) #1

out of curiosity, has anyone figured out how “length” should be used? I searched the forum for it and I only saw that there should be some documentation about that eventually.

In the stock maps, the length always seems to be the same for all trucks, all churchhills, or all jagdpanthers. So if I use a new model, can I calculate the length to use by looking at the model’s size and the position of its origin or something like that?


(zl1corvette) #2

It has something to do with how movers go through turns. I think it has something to do with affecting how the origin affects the mover, if that makes any sense. I don’t know anymore than that, which kind of sucks because I need it for a train I am making.


(EB) #3

Plot your splines to coincide with the origin brush in the center of the models_clip. This way when you lay the splines, you will know the uniform height to set them. As for the distances between…#1. A damaged vehicle can only stop and be “damaged” at a spline point/////#2. with the origin placed in the center and the angle that the vehicle takes on being the angle between the spline —placing a spline directly above an edge going down to another spline will allow the tank to go slighty past the edge, but then ‘tip’ downward. maybe a control point in there would be good.

No set length though…that would be a pain in the ass if their was. :chef:


(zl1corvette) #4

I think were talking about different “lenghts”


followspline globalaccum 0 spln46 200 wait length -224

:smiley:


(EB) #5

<<<<<idiot


(EB) #6

//this says goto spl_01 at a speed of 100 and don’t look at
//the next command until after waiting 304
followspline 0 spl_02 100 wait length 304
followspline 0 spl_03 100 wait length 304

that is from “surface” ---- http://www.wolfensteinx.com/surface/tutorials/et_simple_script_mover_p2.html


(zl1corvette) #7

I have to disagree with that interpretation for three reasons

  1. It can take negative values, so that kind of doesn’t make sense
  2. In my tests it effects how the mover goes thru turns
  3. It doesn’t make sense. why wouldn’t you just want to wait until the move is completed

(EB) #8

Yeah, that “Surface” site was wrong.

I tested it out on a tank tut map I use for trying angles and such…and it turns out that the length (####) is how the tank turns.

A “0” gave me an instant turn towards the next spline.
A “8000” gave me a straight forward start and then a slow wipeout finish
A " -64 " was slow and smooth
An “18000” gave me a sideways to backwardly mobile sliding tank from whacko world.(Instantly turns backwards and does it’s slide)
A “-18000” same as 18000
A “180000” made it almost never turn…so expect it to slide however it wants to.

I would Imagine it has to do with the degree of the turn and how fast you want it to turn between the distance of the splines. This makes the natural feel easy(I think).


(Malverik) #9

for example, in goldrush the truck has a length of 304 for every followspline and the tank has a length of 32. Therefore, it shouldnt depend on the shape of the curve. A tank could almost make a 360 turn without leaving its spot so it makes sence that the lenght is much smaller than the one of the truck. Where it gets tricky is how can you avoid going on a trial and error frenzy by guessing the length required simply by looking at the model? Another thing I am afraid is that the origin of the truck in goldrush is located at the back of it. The origin of the truck I am using is right in the middle…


(EB) #10

I think you misunderstood me…but you have the grasp anyways. ( I think of the length as a prep. for the next spline. )


(CooperHawkes) #11

IMHO <length> shifts the rotation center of the mover <length> WUs along the spline curve… dunno why a length of 8000 results in a valid movement in your case… maybe just a fluke?


(zl1corvette) #12

IMHO <length> shifts the rotation center of the mover <length> WUs along the spline curve

That was my original thought. But when I had a look at Goldrush (truck) and railgun (tugs) it didn’t seem to be the case. The lengths they use would move the origin more to the front (or rear) of the mover instead of where you would expect the center of rotation to be. The tank in goldrush seemed to already have the origin in the center of the tank, but a length was also specified there, although much smaller ~32 I think. I do agree with you that it affects the center of rotation, but I just don’t know how.