How do I make a brush follow the player's movements.

Avatar
RubyCarbuncIe
303 Posts
Posted Nov 13, 2011
ok so I would like to know how to get a brush entity to follow the player's movements. The brush would be only be able to move up, down, left and right along one surface. For example, if the player moves forward, the brush would move left with the player. Any help on this matter would be greatly appreciated.

Thank you for your time.

Advertisement
Registered users don’t see ads! Register now!
Avatar
spongylover123
944 Posts
Posted Nov 13, 2011
Replied 9 minutes later
Parent a brush entity to a !player. It mig work, try it out
Avatar
Rand0mNumbers
76 Posts
Posted Nov 13, 2011
Replied 8 minutes later
I haven't tried this yet, but perhaps using logic_measure_movement and measuring the !player would work. Just take into consideration the brush will not have proper collision if you do this.

For a second, I thought you were looking for a func_tank to emulate portal cameras.

Avatar
RubyCarbuncIe
303 Posts
Posted Nov 13, 2011
Replied 16 minutes later
Well I've tried both of your solutions and have come up empty handed so far, but thanks for the help anyways.
Avatar
Rand0mNumbers
76 Posts
Posted Nov 13, 2011
Replied 39 minutes later

RubyCarbuncIe wrote:
Well I've tried both of your solutions and have come up empty handed so far, but thanks for the help anyways.

Really? I just setup a logic_measure_movement with the following:
Entity to Measure: !player
Measure Reference: playerReference
Entity to Move: cube
Movement Reference: cubeReference

Both references were info_targets set dead center and at the base of their respective entities. Additionally, I changed the angles of the cube's reference to be 90 degrees while the player's reference was 0 degrees.

This produced an effect where the player's movement was shifted 90 degrees and applied to the cube (move forward -> cube goes left).

Avatar
RubyCarbuncIe
303 Posts
Posted Nov 13, 2011
Replied 13 minutes later
I'll look into what you did, I didn't set up anything for the references so that is most likely the reason nothing happened.

One question though, what entity did you attach the player's target to? You said you placed them in the center of both entities. I know that one of those entities would be the brush I want to move but what about the player's target?

EDIT: Never mind I figured it out, Thanks for your help. I really appreciate it. :smile:

Advertisement
Registered users don’t see ads! Register now!
Avatar
Rand0mNumbers
76 Posts
Posted Nov 13, 2011
Replied 9 minutes later
You're welcome.

Now you've got me thinking. xD