convert user index to userid
i have got players index it's 1-32. but userid is different. so i need to do something with player after typing amx_action 1 in servers console.
i tried this so far: PHP Code:
it's because i need to manipulate with players from rcon. my php script got playerx index number and i need to activate command on him. i could use amx_action playerx but i think it could be buggy if others have similar nickname. |
Re: convert user index to userid
new index = str_to_num(target)-1;
i fixed it thanks for your support |
Re: convert user index to userid
This won't work.
Anyway, cmd_target supports name / userid / steamid And to convert index to userid, use : userid = get_user_userid( index ) |
| All times are GMT -4. The time now is 08:19. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.