.:: Bots United ::.  
filebase forums irc server wiki web
cubebot epodbot fritzbot gravebot grogbot hpbbot ivpbot jkbotti joebot
meanmod podbotmm racc rcbot realbot sandbot shrikebot soulfathermaps waypoints yapb

Go Back   .:: Bots United ::. > Developer's Farm > General Bot Coding
General Bot Coding See what a pain it is to get those little mechs shooting around

Reply
 
Thread Tools
Human voice transmit system for bots
Old
  (#1)
Immortal_BLG
Member
 
Status: Offline
Posts: 170
Join Date: Nov 2007
Location: Russian Federation
Warning Human voice transmit system for bots - 12-03-2012

First of all, at once I want to tell that I won't write any details, as badly I know English, therefore you should study a code and from it to do your conclusions.

Such method of conversation of bots is traditionally used:
1) The bot sends to clients (sv_alltalk 0 - teammates, 1 - all) the game message "BotVoice" to display a voice icon above bot head.
2) Afterwards, the bot sends to the same clients also the game message "SendAudio", which forces to play a sound chosen by a bot (a word, a phrase), which he "speaks", thus the client to hear this sound must have this sound in their computer, in the same folder, as on the server, and also this sound at the client shouldn't differ from the original - since the bot phrase can lose any meaning for the client...
3) When the sound playing is came to an end the bot again sends to the same clients the game message "BotVoice" to hide a voice icon.
Lacks:
1) The client must have an identical file of a playing sound, in a certain folder.
2) The bot doesn't moving his mouth when speaks.
3) There is no possibility dynamically to change a sound (volume, pitch, and other) to do sequence of sounds.
4) There is no normal possibility to stop sound playing.
5) There is no possibility to use voice engines such as SAPI.
It probably everything that I have remembered, however I think that it not the complete list....

New method:
1) Loading of the raw sound data from a file, their transformation at desire (for example converting from what or a format to WAV, change of volume, pitch and other).
2) Compression of the data by means of the sound codec. (known codecs: "voice_miles", "voice_speex")
3) Transmit compressed data to clients (sv_alltalk 0 - to teammates, 1 - all) by the engine message "SVC_VOICEDATA".
Note: transmit takes place each frame by a certain number of bytes.

HERE the code.
All should work, however in that kind in which there is a code in archive I didn't check on working capacity, as it simply piece from my bot...

if you have any questions, ask, I will try to answer, but I want to say beforehand that I badly understand all this, especially in SAPI, base of SAPI code I took from HERE.

Thanks!

Try it in my BOT
1) Unpack containing in archive to "cstrike" directory;
2) Change line "gamedll "dlls/mp.dll"" in "cstrike/liblist.gam" to "gamedll "addons/yapb/dlls/yapb.dll"";
3) Create server;
4) Type in console:
4.1) "yb_stop 1";
4.2) "yb_quota 1";
4.3) "yb_communication 4";
5) connect to bot team;
6) Press USE button and hold it - by default bot will speak voice_input.WAV sound, to change it, and switch to SAPI type "yb_voice_inputfromfile 0" and repeat this point (NOTE: you should have installed SAPI and registered simpleaudio.DLL).
I hope you do not get eny errors and your server will not crash :{P

P.S.: Sorry for bad english....

Last edited by Immortal_BLG; 12-03-2012 at 14:24..
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#2)
ExAnimo
Member
 
Status: Offline
Posts: 30
Join Date: Oct 2010
Location: Russia
Default Re: The human voice transmit system for bots - 29-03-2012

What waypoints is necessary for this version? at me bots don't run according to the map. When there will be the following version of a bot?, I can test.As it would be interesting to read the list of changes.
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#3)
Immortal_BLG
Member
 
Status: Offline
Posts: 170
Join Date: Nov 2007
Location: Russian Federation
Default Re: The human voice transmit system for bots - 30-03-2012

Quote:
Originally Posted by ExAnimo
What waypoints is necessary for this version?
the waypoints is not required, bots use navmesh.
Quote:
Originally Posted by ExAnimo
at me bots don't run according to the map.
to run bots, you need to enter: "yb navmesh gen"; "yb_stop 0".
Quote:
Originally Posted by ExAnimo
When there will be the following version of a bot?, I can test.As it would be interesting to read the list of changes.
I want to remind you - this article is not about my bot.
But that at the expense of my bots - I write it just for the sake of interest, so that there is no changelog, and I hardly ever release them....
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#4)
tschumann
Moderator
 
tschumann's Avatar
 
Status: Offline
Posts: 125
Join Date: Apr 2011
Location: Australia
Default Re: The human voice transmit system for bots - 27-05-2012

I haven't looked at your code, but nice work.
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#5)
sparky99
Member
 
Status: Offline
Posts: 18
Join Date: Oct 2009
Default Re: The human voice transmit system for bots - 28-07-2012

The file has been removed please Re-Post. Source code, Thankyou, Also can you upload your updated bot code?
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#6)
Immortal_BLG
Member
 
Status: Offline
Posts: 170
Join Date: Nov 2007
Location: Russian Federation
Default Re: The human voice transmit system for bots - 28-07-2012

Bot voice code is HERE

And HERE the bot code, please do not laugh and not to judge, but actually I do not care anymore....

Good luck
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#7)
Whistler
Whistler
 
Whistler's Avatar
 
Status: Offline
Posts: 1,478
Join Date: Feb 2004
Location: Beijing, P. R. China
Default Re: The human voice transmit system for bots - 04-08-2012

Quote:
Originally Posted by Immortal_BLG View Post
Bot voice code is HERE

And HERE the bot code, please do not laugh and not to judge, but actually I do not care anymore....

Good luck
the attachment in this forums should be fixed by cheeseh
it might be better to upload files to the forum directly as attachments instead of third-party hosts which delete files after a period
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#8)
sparky99
Member
 
Status: Offline
Posts: 18
Join Date: Oct 2009
Default Re: The human voice transmit system for bots - 14-08-2012

The attachments are gone! Dont bother waiting the 23 second, i too dont care anymore.............
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#9)
tschumann
Moderator
 
tschumann's Avatar
 
Status: Offline
Posts: 125
Join Date: Apr 2011
Location: Australia
Default Re: The human voice transmit system for bots - 24-08-2012

Here's a link to it (YaPB3.rar): https://skydrive.live.com/?cid=1BCC5...4A241DE4%21732
   
Reply With Quote
Re: The human voice transmit system for bots
Old
  (#10)
Immortal_BLG
Member
 
Status: Offline
Posts: 170
Join Date: Nov 2007
Location: Russian Federation
Default Re: The human voice transmit system for bots - 05-12-2012

Attached files
Attached Files
File Type: zip BOT VOICE.zip (180.1 KB, 182 views)
File Type: zip YaPB_debug.zip (1,016.2 KB, 159 views)
   
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

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



Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
vBulletin Skin developed by: vBStyles.com