Raised This Month: $32 Target: $400
 8% 

[CODE] [ORPHEU] How to hook when player use +voicerecord


Post New Thread Reply   
 
Thread Tools Display Modes
Seta00
The Seta00 user has crashed.
Join Date: Jan 2010
Location: Berlin
Old 09-20-2010 , 08:43   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #21

Quote:
Originally Posted by Owyn View Post
if you don't know you don't have to write some random stuff back just to answer something
Implying that Arkshine doesn't know about anything AMXx-related...

Any chance of accessing the voice data?
Seta00 is offline
joropito
AlliedModders Donor
Join Date: Mar 2009
Location: pfnAddToFullPack
Old 09-20-2010 , 10:11   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #22

Quote:
Originally Posted by Seta00 View Post
Any chance of accessing the voice data?
I think can be done, but what do you want to do with it? Save in a file? :p

I don't know the voice encoding method used.
__________________

Divide et vinces
approved plugins | steam account

I don't accept PM for support. Just ask on forums.
If you're looking for private work, PM me.
joropito is offline
Send a message via MSN to joropito
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 09-20-2010 , 10:56   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #23

You can try to hook MSG_WriteBuf() in this function. It should work. The max size is 4096.
__________________
Arkshine is offline
Seta00
The Seta00 user has crashed.
Join Date: Jan 2010
Location: Berlin
Old 09-20-2010 , 12:17   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #24

Quote:
Originally Posted by joropito View Post
I think can be done, but what do you want to do with it?
Stream.
Quote:
Originally Posted by joropito View Post
I don't know the voice encoding method used.
Speex.
Quote:
Originally Posted by Arkshine View Post
You can try to hook MSG_WriteBuf() in this function. It should work. The max size is 4096.
Thanks.
Seta00 is offline
Lt.RAT
Member
Join Date: Sep 2008
Location: Russia Yekaterinburg
Old 09-23-2010 , 16:59   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #25

Quote:
Originally Posted by Seta00 View Post
Speex.
really not.
server sends to client message with codec and quality, for example:
Code:
    Packet: svc_voiceinit (0x34)
      Name: voice_miles
      Quality: 3
and we can choose by:
Code:
sv_voicecodec voice_speex
sv_voicecodec voice_miles
Lt.RAT is offline
Send a message via ICQ to Lt.RAT
zamorac
Junior Member
Join Date: Oct 2008
Old 01-19-2012 , 12:09   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #26

Sorry to ressurect this one, but i need some help.

I dont care what the client is saying, i just need to check if he has a functional mic. So i really just need to see if the signature of the data is different from a player with no mic holding the +voicerecord.

Basicly i want to give the players with microphones some more access, nothing less nothing more
zamorac is offline
joropito
AlliedModders Donor
Join Date: Mar 2009
Location: pfnAddToFullPack
Old 01-19-2012 , 12:39   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #27

Quote:
Originally Posted by zamorac View Post
Sorry to ressurect this one, but i need some help.

I dont care what the client is saying, i just need to check if he has a functional mic. So i really just need to see if the signature of the data is different from a player with no mic holding the +voicerecord.

Basicly i want to give the players with microphones some more access, nothing less nothing more
In the case that you can read the voice data, it will be always different event he's just pressing +voicerecord or talking because client game will get data from soundcard that always has noise.
__________________

Divide et vinces
approved plugins | steam account

I don't accept PM for support. Just ask on forums.
If you're looking for private work, PM me.
joropito is offline
Send a message via MSN to joropito
zamorac
Junior Member
Join Date: Oct 2008
Old 01-19-2012 , 12:45   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #28

Well noise will always be uniform, or at least near uniform, so im guessing if we could read the data and check the peak we could conclude if the user has/does not have a mic?

My other idea is im guessing that the client has to have start/end of transmission packages so the server knows that it has to transmit. If we check the neutral states(start/end) and conclude that some part of the trans differs from those 2 we can conclude there is a mic.

If it can`t be done please tell me to let it go, i am not all that familiar with scripting in amx i am just putting ideas on the table.
zamorac is offline
Starsailor
horrible hahah
Join Date: Aug 2008
Location: Buenos Aires
Old 01-20-2012 , 10:12   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #29

Quote:
Originally Posted by Arkshine View Post
0xAB34F ; you are lazy, I find it in less 10 seconds. :p Also, it would be nice to make signatures of bytes, but I can understand it's boring as hell.
with 0xAB34F doesn't work for me..i use 0xAB7BF

but i'm having problem to get the player id..

[ORPHEU] Invalid memory structure "svs_ptr"

Code:
{
    {
        "name"        : "svs_ptr",
        "library"     : "engine",
        "type"        : "int",
        "memoryType"  : "data",
        "identifiers" :
        [
            {
                "os"    : "windows",
                "mod"   : "cstrike",
                "value" :0
            },
            {
                "os"    : "linux",
                "mod"   : "cstrike",
                "value" : 0xBE130
            }
        ]
    }
}
what is the value for windows?
__________________
Find my plugins here..

Ex - Spanish Moderator.

Last edited by Starsailor; 01-20-2012 at 10:39.
Starsailor is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 01-20-2012 , 14:28   Re: [CODE] [ORPHEU] How to hook when player use +voicerecord
Reply With Quote #30

Bad idea to work with offset and I don't know what binary you use. svs address should be got from a function where it's used. For example Host_InitializeGameDLL, you search "1", you get the address then by soutracting 4 bytes, you get the address of svs.
__________________
Arkshine is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:39.


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