Quote:
Originally Posted by ot_207
#2 pev_button works this way. To get it.
PHP Code:
new button = pev(id, pev_button)
PHP Code:
new button = IN_ATTACK | IN_BACK | IN_ALT set_pev(id, pev_button, button)
Will come with an edit to the other 2.
|
I read that I have to use bitwise operators and get the actual buttons pressed like
PHP Code:
pev(id, pev_button, button)
if (button & IN_JUMP)
But I want to make a specific plugin that allows me to control another player. No abuse, I'm about to make a public HNS server with bunny hop courses (blockmaker) and it would be great if I could help out newbies to reach what they want. So if they want help, I could easily control them to the right place. I tried this code:
PHP Code:
pev(id, pev_button, Buttons)
pev(id, pev_angles, Angles)
set_pev(Slave, pev_button, Buttons)
set_pev(Slave, pev_angles, Angles)
And on the dedicated server, I saw that when I press +forward or simply looking left, the Slave is also was about to go forward and look left but it was only a "visual" change, the Slave didn't saw any change. Give me some minutes and I will post the code.