Help wiht a conveyor belt setup?

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,696
2,580
Help with a conveyor belt setup?

So, I'm putting together an infinitely-looping conveyor belt with Mad Milk bottles on it, because I think I might want one some day and might as well make it now, and I've run into a couple of minor issues.

The first is scale. The speeds for both the func_tracktrains I'm using to control the movement of the bottles and the texture scrolling proxy I'm using to control the belt itself are documented as being in "units per second", but clearly it means that in a generic, speed-expressable-as-numbers sense rather than actual Hammer units in either case. I can't even figure out the scale of the two measurements so I can get them to line up properly. Right now the conveyor belt is moving at 0.2 and the bottles are moving at 24 (25 was slightly too fast; 24 is too slow).

The second issue is that every few times a bottle is teleported from the end back to the starting point, I get an error in the console like this:

Bad SetLocalAngularVelocity(0.000000,-12000.000977,0.000000) on bottle_18

It doesn't seem to be having any tangible negative effect on anything, but I'd like to know what it's saying I did wrong and how to fix it anyway.
 

A Boojum Snark

Toraipoddodezain Mazahabado
aa
Nov 2, 2007
4,775
7,670
Train speeds are indeed the "hammer units" (I really dislike that term, everything in the source engine is simply units, they are all the same distance).

A lot of material properties deal with 0-1 UV values, and I think how scrolling worked was a speed of 4 would mean the whole texture moves aside and back to center four times every second. Thus your need for really low numbers. They're like that because any other kind of speed would be irrelevant due to the possibility of material scaling both in the VMT and through Hammer.

The error just looks like a typical Source engine hiccup when dealing with moving/teleporting objects.
 

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,696
2,580
So for a texture of 512 square, like this one is, 1 unit per second at the standard .25 texture scale would mean 128 HU/sec?
 

A Boojum Snark

Toraipoddodezain Mazahabado
aa
Nov 2, 2007
4,775
7,670
I believe so, yes. But don't call the texture speed units per second since it really isn't... cycles per second maybe?
I'm not positive, but looking at a few scrollers I have it seems like that makes sense (I never bothered timing/measuring).
 

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,696
2,580
Yep, a movement speed of 32 units per second coupled with .25 cycles per second on the material did the trick. Time to go edit the wiki again.