PDA

View Full Version : [TF2] Teleport particle to position + extra y


Michalplyoutube
10-20-2014, 09:42
Will this will work?
TeleportEntity(particle, position + y63, NULL_VECTOR, NULL_VECTOR);
or
TeleportEntity(particle, position + offset[]={0.0,75.0,0.0} , NULL_VECTOR, NULL_VECTOR);

or can someone tell me how do i use offsets?

Oshizu
10-20-2014, 09:53
I myself would do it this way:

position[0] += offset[0]
position[1] += offset[1]
position[2] += offset[2]
TeleportEntity(particle, position, NULL_VECTOR, NULL_VECTOR)
You can do it that kind of way too aswell:

position[0] += offset_x
position[1] += offset_y
position[2] += offset_z
TeleportEntity(particle, position, NULL_VECTOR, NULL_VECTOR)
Depends on how you want to implement stuff :D
You could go for the raw data aswell?

position[0] += 50.0
position[2] += 500.0 // Like this?

friagram
10-20-2014, 14:35
you know that that's in reference to the origin right? if you want to do it in regards to any other orientation, you'll have to use GetAngleVectors and multiply to translate

Michalplyoutube
10-20-2014, 14:37
you know that that's in reference to the origin right? if you want to do it in regards to any other orientation, you'll have to use GetAngleVectors and multiply to translate

I k but i don't need it now but thanks