Day of Defeat Plugins Community
This site is an archive — everything is readable and downloadable, nothing can be posted. Admin
Archive › Old Forum Threads › Help › Scripting Help › How to edit voice radio message?
9 posts, 5 people · 1,465 views Thread Rating: ★★★★★
closedHow to edit voice radio message?
Started by oofishg on 11-06-2009, 09:41 AM
O oofishg
started this thread
Posts: 3
Threads: 1
Joined: Oct 2005
11-06-2009, 09:41 AM #1

How to edit voice radio message?rnrnex:rnvoice_gogogorn(Voice) oofish : Go Go Go!rnrnrn↓rn(Voice) oofish : Guys,GoGoGo!rnrnor anyrnrn?

Dr.G
posted here
Posts: 776
Threads: 75
Joined: Nov 2007
11-06-2009, 01:03 PM #2

You cant. Its a sound file that only says gogogo. You would need to find or create a new sound file, and after that you would have to make a new command for playing it.

O oofishg
started this thread
Posts: 3
Threads: 1
Joined: Oct 2005
11-06-2009, 01:17 PM #3
You cant. Its a sound file that only says gogogo. You would need to find or create a new sound file, and after that you would have to make a new command for playing it.
rnrn@@rnnot soundrnrnthe voice radio message(msg)

O oofishg
started this thread
Posts: 3
Threads: 1
Joined: Oct 2005
11-08-2009, 06:02 AM #4

:(rnrni know CS can do it , but DOD i can't ..rnrnrnpublic color_radio(msgid, msgDest, msgEnt){rn new argNum = get_msg_args()rn if (argNum!=5) return PLUGIN_CONTINUErn if (get_msg_argtype(1)!=ARG_BYTE) return PLUGIN_CONTINUErn new arg1=get_msg_arg_int(1)rn if (arg1!=5) return PLUGIN_CONTINUErn new arg3[256]rn get_msg_arg_string(3,arg3,255)rn if(equal(arg3,"#Game_Radio")){rn new arg4[33],arg5[129]rn get_msg_arg_string(4,arg4,32)rn get_msg_arg_string(5,arg5,128)rn new saymsg[255]rn if(equal(arg5,"#Go_go_go")){//Msg GoGoGorn format(saymsg,192,"^x03%s :^x04 衝啊..!",arg4)rn }rn else if(equal(arg5,"#Stick_together_team")){rn format(saymsg,255,"^x03%s :^x04 一起走吧! 各位..",arg4)rn }rn else if(equal(arg5,"#Team_fall_back")){rn format(saymsg,255,"^x03%s :^x04 快撤退啊!",arg4)rn }rn else if(equal(arg5,"#Cover_me")){rn format(saymsg,255,"^x03%s :^x04 掩護我!",arg4)rn }rn else if(equal(arg5,"#You_take_the_point")){rn format(saymsg,255,"^x03%s :^x04 你守住這個位置",arg4)rn }rn else if(equal(arg5,"#Hold_this_position")){rn format(saymsg,255,"^x03%s :^x04 各單位保持現在的位置",arg4)rn }rn else if(equal(arg5,"#Regroup_team")){rn format(saymsg,255,"^x03%s :^x04 重新組合隊形",arg4)rn }rn else if(equal(arg5,"#Follow_me")){rn format(saymsg,255,"^x03%s :^x04 跟我來...",arg4)rn }rn else if(equal(arg5,"#Taking_fire")){rn format(saymsg,255,"^x03%s :^x04 開火啊..需要支援!",arg4)rn }rn else if(equal(arg5,"#Get_in_position_and_wait")){rn format(saymsg,255,"^x03%s :^x04 全隊就定位,等我衝出去時掩護我",arg4)rn }rn else if(equal(arg5,"#Storm_the_front")){rn format(saymsg,255,"^x03%s :^x04 全隊正面快攻!",arg4)rn }rn else if(equal(arg5,"#Report_in_team")){rn format(saymsg,255,"^x03%s :^x04 回報行動是否準備OK",arg4)rn }rn else if(equal(arg5,"#Affirmative")){rn format(saymsg,255,"^x03%s :^x04 收到",arg4)rn }rn else if(equal(arg5,"#Roger_that")){rn format(saymsg,255,"^x03%s :^x04 了解",arg4)rn }rn else if(equal(arg5,"#Enemy_spotted")){rn format(saymsg,255,"^x03%s :^x04 發現敵人",arg4)rn }rn else if(equal(arg5,"#Need_backup")){rn format(saymsg,255,"^x03%s :^x04 我需要支援",arg4)rn }rn else if(equal(arg5,"#Sector_clear")){rn format(saymsg,255,"^x03%s :^x04 此區域安全",arg4)rn }rn else if(equal(arg5,"#In_position")){rn format(saymsg,255,"^x03%s :^x04 我已經就定位",arg4)rn }rn else if(equal(arg5,"#Reporting_in")){rn format(saymsg,255,"^x03%s :^x04 回報行動準備OK",arg4)rn }rn else if(equal(arg5,"#Get_out_of_there")){rn format(saymsg,255,"^x03%s :^x04 炸彈要爆炸了.閃人閃人閃人!",arg4)rn }rn else if(equal(arg5,"#Negative")){rn format(saymsg,255,"^x03%s :^x04 想的美咧",arg4)rn }rn else if(equal(arg5,"#Enemy_down")){rn format(saymsg,255,"^x03%s :^x04 敵人死了",arg4)rn }rn else if(equal(arg5,"#Hostage_down")){rn format(saymsg,255,"^x03%s :^x04 人質死了= =..",arg4)rn }rn else if(equal(arg5,"#Fire_in_the_hole")){rn format(saymsg,255,"^x03%s :^x04 我要丟啦..小心被噴到!",arg4)rn }rn else {rn return PLUGIN_CONTINUErn //format(saymsg,random_num(0,255),"^x03%s : ^x04What are you saying!",arg4)rn }rn message_begin(MSG_ONE, get_user_msgid("SayText"), {0,0,0}, msgEnt) rn write_byte(msgEnt)rn write_string(saymsg)rn message_end()rn //client_color(0,msgEnt,saymsg)rn return PLUGIN_HANDLEDrn }rn return PLUGIN_CONTINUE

Vet
posted here
Posts: 229
Threads: 24
Joined: Oct 2006
11-08-2009, 09:44 PM #5

In DoD, the voices are done with EVENTS (events 30 and 31 to be exact), not messages. Its like Dr.G said, you'd need to create your replacement sound bites and upload them to your clients. Then trap all the client voice_* and voice_menu* commands and issue the corresponding voice file via an emit_sound or spk command.

meathead
posted here
Posts: 337
Threads: 23
Joined: Aug 2007
11-09-2009, 04:11 AM #6

Sorry but beer is making me but in. Can you not just change the .wav file or something. Never looked at a radio file. would that just screw up the .bsp?

Vet
posted here
Posts: 229
Threads: 24
Joined: Oct 2006
11-09-2009, 10:32 AM #7

Yes, you could change the wav to play on your local machine. I assumed, perhaps erroneously, he wanted to change the wavs for everyone entering his server via a plugin. And since you can't force a client to upload an existing file, you'd need different filenames.

diamond-optic
posted here
Posts: 2,068
Threads: 103
Joined: May 2005
11-09-2009, 04:17 PM #8

what i gather from this.. is that he doesnt wanna change the sound.. but he wants to change the text printed to the chat

Vet
posted here
Posts: 229
Threads: 24
Joined: Oct 2006
11-10-2009, 12:56 AM #9

lol, oh ya. I guess I oughta learn how to read.

Archive › Old Forum Threads › Help › Scripting Help › How to edit voice radio message?
DoD Plugins Archive · Repository · Old Forum Threads · Maps · Admin · built 14 Sep 2026 00:34 UTC