AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   get id of player reciving msg (https://forums.alliedmods.net/showthread.php?t=5867)

karlos 09-15-2004 11:10

get id of player reciving msg
 
i registered a msg with register_message(get_user_msgid("SayText"),"m yfunc"), with get_msg_arg_int(1) i get the id of the person who sends this message
the func is called (if not team say) as often as there are players on server, but how do i get the id of the player it is currently send to?

devicenull 09-15-2004 17:51

public yourfunc (id) {
iirc, that should work

karlos 09-20-2004 09:37

1) device its not working, the id i returns is not a players id and is always the same (maybe the id of the msg)
any1 can help?
2) btw how to get the number of players it is send to? when normal say then number = max players, if team say the number of team mates, but how to get these from the msg?


solved 1):
i use myfunc(msgid,dummy,receiver_id)
dont really know if msgid is the msg id but its not a player id, so its logical thats its msg id


All times are GMT -4. The time now is 17:10.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.