Moving entities instantly

DrLambda

L69: Teeheehee, Member
aa
Feb 18, 2015
458
475
Hello,

second question for today - This April Fool's project made me fiddle with "deep" Hammer stuff more in one day than everything else before.

My question is: I have an entity (brush-based or point-based, doesn't matter) and want to move it to a different point on the map instantly as an output on a logic_relay.

After searching on VDC and here for quite a long time - How do i accomplish such an miraculous feat? Thanks in advance.
 
May 25, 2015
390
307
Well, most entities can't be moved. If you're talking about players or physics objects, you can teleport them using a trigger_teleport.

However, props and otherwise immobile entities (such as brush entities) can be faked to appear to have teleported.
For instance, create two identical func_brush entities in different places. Have one of them start disabled. Then, disable the first one and enable the second one at the same time, and it will appear to have teleported.
 

EArkham

Necromancer
aa
Aug 14, 2009
1,625
2,774
You can use a point_teleport to teleport most entities. I used this on an old ZPO map to randomize objectives. You just need to be careful with the position and angles to make sure it's oriented correctly and not sticking inside something.
 
May 25, 2015
390
307
I'm not sure i understand that correctly - You can parent entities to other moving objects (like putting a control point on a moving train, like on Namicott.) The only difference is that i don't want the visible movement. Is that impossible?

Ok, let me clarify.

If you for instance want a brush pyramide or another project to instantly travel/teleport from point a to point b, this is how I recomend you do it.
Create two instances of the object, one at the starting point, and one at the end point. Have the object at point b start disabled. Then, when you want the object to 'teleport' from point a to point b, disable the object at point a and endable the object at point b at the same time, and it will appear to have moved instantly. What actually happens is that the first object disappear and the other object appear at the same time, giving the illusion of teleportation.
 

DrLambda

L69: Teeheehee, Member
aa
Feb 18, 2015
458
475
I agree that this would work for most cases.

What i did now, with the help of EArkhams answer, was to parent everything i wanted to teleport to a info_target, then teleport the info_target to a point_teleport. This way i can teleport complete complex triggers with multiple objects with just one point_teleport. It works exactly the way i want it to.