ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/server/c_chat.C
(Generate patch)

Comparing deliantra/server/server/c_chat.C (file contents):
Revision 1.7 by root, Mon Dec 25 11:25:49 2006 UTC vs.
Revision 1.9 by root, Mon Jan 8 22:32:11 2007 UTC

1/* 1/*
2 CrossFire, A Multiplayer game for X-windows 2 CrossFire, A Multiplayer game for X-windows
3 3
4 Copyright (C) 2005, 2006, 2007 Marc Lehmann & Crossfire+ Development Team
4 Copyright (C) 2002 Mark Wedel & Crossfire Development Team 5 Copyright (C) 2002 Mark Wedel & Crossfire Development Team
5 Copyright (C) 1992 Frank Tore Johansen 6 Copyright (C) 1992 Frank Tore Johansen
6 7
7 This program is free software; you can redistribute it and/or modify 8 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by 9 it under the terms of the GNU General Public License as published by
94 * that are not. Helper functions will call basic_emote with the proper 95 * that are not. Helper functions will call basic_emote with the proper
95 * arguments, translating them into commands. Adding a new emotion can be 96 * arguments, translating them into commands. Adding a new emotion can be
96 * done by editing command.c and command.h. 97 * done by editing command.c and command.h.
97 * [garbled 09-25-2001] 98 * [garbled 09-25-2001]
98 */ 99 */
99
100static int 100static int
101basic_emote (object *op, char *params, int emotion) 101basic_emote (object *op, char *params, int emotion)
102{ 102{
103 char buf[MAX_BUF], buf2[MAX_BUF], buf3[MAX_BUF]; 103 char buf[MAX_BUF], buf2[MAX_BUF], buf3[MAX_BUF];
104 player *pl; 104 player *pl;
105 105
106 if (!params) 106 if (!params)
107 { 107 {
108 switch (emotion) 108 switch (emotion)
109 { 109 {
110 case EMOTE_NOD: 110 case EMOTE_NOD:
111 sprintf (buf, "%s nods solemnly.", &op->name); 111 sprintf (buf, "%s nods solemnly.", &op->name);
112 sprintf (buf2, "You nod solemnly."); 112 sprintf (buf2, "You nod solemnly.");
113 break; 113 break;
114 case EMOTE_DANCE: 114 case EMOTE_DANCE:
115 sprintf (buf, "%s expresses himself through interpretive dance.", &op->name); 115 sprintf (buf, "%s expresses himself through interpretive dance.", &op->name);
116 sprintf (buf2, "You dance with glee."); 116 sprintf (buf2, "You dance with glee.");
117 break; 117 break;
118 case EMOTE_KISS: 118 case EMOTE_KISS:
119 sprintf (buf, "%s makes a weird facial contortion", &op->name); 119 sprintf (buf, "%s makes a weird facial contortion", &op->name);
120 sprintf (buf2, "All the lonely people.."); 120 sprintf (buf2, "All the lonely people..");
121 break; 121 break;
122 case EMOTE_BOUNCE: 122 case EMOTE_BOUNCE:
123 sprintf (buf, "%s bounces around.", &op->name); 123 sprintf (buf, "%s bounces around.", &op->name);
124 sprintf (buf2, "BOIINNNNNNGG!"); 124 sprintf (buf2, "BOIINNNNNNGG!");
125 break; 125 break;
126 case EMOTE_SMILE: 126 case EMOTE_SMILE:
127 sprintf (buf, "%s smiles happily.", &op->name); 127 sprintf (buf, "%s smiles happily.", &op->name);
128 sprintf (buf2, "You smile happily."); 128 sprintf (buf2, "You smile happily.");
129 break; 129 break;
130 case EMOTE_CACKLE: 130 case EMOTE_CACKLE:
131 sprintf (buf, "%s throws back his head and cackles with insane " "glee!", &op->name); 131 sprintf (buf, "%s throws back his head and cackles with insane " "glee!", &op->name);
132 sprintf (buf2, "You cackle gleefully."); 132 sprintf (buf2, "You cackle gleefully.");
133 break; 133 break;
134 case EMOTE_LAUGH: 134 case EMOTE_LAUGH:
135 sprintf (buf, "%s falls down laughing.", &op->name); 135 sprintf (buf, "%s falls down laughing.", &op->name);
136 sprintf (buf2, "You fall down laughing."); 136 sprintf (buf2, "You fall down laughing.");
137 break; 137 break;
138 case EMOTE_GIGGLE: 138 case EMOTE_GIGGLE:
139 sprintf (buf, "%s giggles.", &op->name); 139 sprintf (buf, "%s giggles.", &op->name);
140 sprintf (buf2, "You giggle."); 140 sprintf (buf2, "You giggle.");
141 break; 141 break;
142 case EMOTE_SHAKE: 142 case EMOTE_SHAKE:
143 sprintf (buf, "%s shakes his head.", &op->name); 143 sprintf (buf, "%s shakes his head.", &op->name);
144 sprintf (buf2, "You shake your head."); 144 sprintf (buf2, "You shake your head.");
145 break; 145 break;
146 case EMOTE_PUKE: 146 case EMOTE_PUKE:
147 sprintf (buf, "%s pukes.", &op->name); 147 sprintf (buf, "%s pukes.", &op->name);
148 sprintf (buf2, "Bleaaaaaghhhhhhh!"); 148 sprintf (buf2, "Bleaaaaaghhhhhhh!");
149 break; 149 break;
150 case EMOTE_GROWL: 150 case EMOTE_GROWL:
151 sprintf (buf, "%s growls.", &op->name); 151 sprintf (buf, "%s growls.", &op->name);
152 sprintf (buf2, "Grrrrrrrrr...."); 152 sprintf (buf2, "Grrrrrrrrr....");
153 break; 153 break;
154 case EMOTE_SCREAM: 154 case EMOTE_SCREAM:
155 sprintf (buf, "%s screams at the top of his lungs!", &op->name); 155 sprintf (buf, "%s screams at the top of his lungs!", &op->name);
156 sprintf (buf2, "ARRRRRRRRRRGH!!!!!"); 156 sprintf (buf2, "ARRRRRRRRRRGH!!!!!");
157 break; 157 break;
158 case EMOTE_SIGH: 158 case EMOTE_SIGH:
159 sprintf (buf, "%s sighs loudly.", &op->name); 159 sprintf (buf, "%s sighs loudly.", &op->name);
160 sprintf (buf2, "You sigh."); 160 sprintf (buf2, "You sigh.");
161 break; 161 break;
162 case EMOTE_SULK: 162 case EMOTE_SULK:
163 sprintf (buf, "%s sulks in the corner.", &op->name); 163 sprintf (buf, "%s sulks in the corner.", &op->name);
164 sprintf (buf2, "You sulk."); 164 sprintf (buf2, "You sulk.");
165 break; 165 break;
166 case EMOTE_CRY: 166 case EMOTE_CRY:
167 sprintf (buf, "%s bursts into tears.", &op->name); 167 sprintf (buf, "%s bursts into tears.", &op->name);
168 sprintf (buf2, "Waaaaaaahhh.."); 168 sprintf (buf2, "Waaaaaaahhh..");
169 break; 169 break;
170 case EMOTE_GRIN: 170 case EMOTE_GRIN:
171 sprintf (buf, "%s grins evilly.", &op->name); 171 sprintf (buf, "%s grins evilly.", &op->name);
172 sprintf (buf2, "You grin evilly."); 172 sprintf (buf2, "You grin evilly.");
173 break; 173 break;
174 case EMOTE_BOW: 174 case EMOTE_BOW:
175 sprintf (buf, "%s bows deeply.", &op->name); 175 sprintf (buf, "%s bows deeply.", &op->name);
176 sprintf (buf2, "You bow deeply."); 176 sprintf (buf2, "You bow deeply.");
177 break; 177 break;
178 case EMOTE_CLAP: 178 case EMOTE_CLAP:
179 sprintf (buf, "%s gives a round of applause.", &op->name); 179 sprintf (buf, "%s gives a round of applause.", &op->name);
180 sprintf (buf2, "Clap, clap, clap."); 180 sprintf (buf2, "Clap, clap, clap.");
181 break; 181 break;
182 case EMOTE_BLUSH: 182 case EMOTE_BLUSH:
183 sprintf (buf, "%s blushes.", &op->name); 183 sprintf (buf, "%s blushes.", &op->name);
184 sprintf (buf2, "Your cheeks are burning."); 184 sprintf (buf2, "Your cheeks are burning.");
185 break; 185 break;
186 case EMOTE_BURP: 186 case EMOTE_BURP:
187 sprintf (buf, "%s burps loudly.", &op->name); 187 sprintf (buf, "%s burps loudly.", &op->name);
188 sprintf (buf2, "You burp loudly."); 188 sprintf (buf2, "You burp loudly.");
189 break; 189 break;
190 case EMOTE_CHUCKLE: 190 case EMOTE_CHUCKLE:
191 sprintf (buf, "%s chuckles politely.", &op->name); 191 sprintf (buf, "%s chuckles politely.", &op->name);
192 sprintf (buf2, "You chuckle politely"); 192 sprintf (buf2, "You chuckle politely");
193 break; 193 break;
194 case EMOTE_COUGH: 194 case EMOTE_COUGH:
195 sprintf (buf, "%s coughs loudly.", &op->name); 195 sprintf (buf, "%s coughs loudly.", &op->name);
196 sprintf (buf2, "Yuck, try to cover your mouth next time!"); 196 sprintf (buf2, "Yuck, try to cover your mouth next time!");
197 break; 197 break;
198 case EMOTE_FLIP: 198 case EMOTE_FLIP:
199 sprintf (buf, "%s flips head over heels.", &op->name); 199 sprintf (buf, "%s flips head over heels.", &op->name);
200 sprintf (buf2, "You flip head over heels."); 200 sprintf (buf2, "You flip head over heels.");
201 break; 201 break;
202 case EMOTE_FROWN: 202 case EMOTE_FROWN:
203 sprintf (buf, "%s frowns.", &op->name); 203 sprintf (buf, "%s frowns.", &op->name);
204 sprintf (buf2, "What's bothering you?"); 204 sprintf (buf2, "What's bothering you?");
205 break; 205 break;
206 case EMOTE_GASP: 206 case EMOTE_GASP:
207 sprintf (buf, "%s gasps in astonishment.", &op->name); 207 sprintf (buf, "%s gasps in astonishment.", &op->name);
208 sprintf (buf2, "You gasp in astonishment."); 208 sprintf (buf2, "You gasp in astonishment.");
209 break; 209 break;
210 case EMOTE_GLARE: 210 case EMOTE_GLARE:
211 sprintf (buf, "%s glares around him.", &op->name); 211 sprintf (buf, "%s glares around him.", &op->name);
212 sprintf (buf2, "You glare at nothing in particular."); 212 sprintf (buf2, "You glare at nothing in particular.");
213 break; 213 break;
214 case EMOTE_GROAN: 214 case EMOTE_GROAN:
215 sprintf (buf, "%s groans loudly.", &op->name); 215 sprintf (buf, "%s groans loudly.", &op->name);
216 sprintf (buf2, "You groan loudly."); 216 sprintf (buf2, "You groan loudly.");
217 break; 217 break;
218 case EMOTE_HICCUP: 218 case EMOTE_HICCUP:
219 sprintf (buf, "%s hiccups.", &op->name); 219 sprintf (buf, "%s hiccups.", &op->name);
220 sprintf (buf2, "*HIC*"); 220 sprintf (buf2, "*HIC*");
221 break; 221 break;
222 case EMOTE_LICK: 222 case EMOTE_LICK:
223 sprintf (buf, "%s licks his mouth and smiles.", &op->name); 223 sprintf (buf, "%s licks his mouth and smiles.", &op->name);
224 sprintf (buf2, "You lick your mouth and smile."); 224 sprintf (buf2, "You lick your mouth and smile.");
225 break; 225 break;
226 case EMOTE_POUT: 226 case EMOTE_POUT:
227 sprintf (buf, "%s pouts.", &op->name); 227 sprintf (buf, "%s pouts.", &op->name);
228 sprintf (buf2, "Aww, don't take it so hard."); 228 sprintf (buf2, "Aww, don't take it so hard.");
229 break; 229 break;
230 case EMOTE_SHIVER: 230 case EMOTE_SHIVER:
231 sprintf (buf, "%s shivers uncomfortably.", &op->name); 231 sprintf (buf, "%s shivers uncomfortably.", &op->name);
232 sprintf (buf2, "Brrrrrrrrr."); 232 sprintf (buf2, "Brrrrrrrrr.");
233 break; 233 break;
234 case EMOTE_SHRUG: 234 case EMOTE_SHRUG:
235 sprintf (buf, "%s shrugs helplessly.", &op->name); 235 sprintf (buf, "%s shrugs helplessly.", &op->name);
236 sprintf (buf2, "You shrug."); 236 sprintf (buf2, "You shrug.");
237 break; 237 break;
238 case EMOTE_SMIRK: 238 case EMOTE_SMIRK:
239 sprintf (buf, "%s smirks.", &op->name); 239 sprintf (buf, "%s smirks.", &op->name);
240 sprintf (buf2, "You smirk."); 240 sprintf (buf2, "You smirk.");
241 break; 241 break;
242 case EMOTE_SNAP: 242 case EMOTE_SNAP:
243 sprintf (buf, "%s snaps his fingers.", &op->name); 243 sprintf (buf, "%s snaps his fingers.", &op->name);
244 sprintf (buf2, "PRONTO! You snap your fingers."); 244 sprintf (buf2, "PRONTO! You snap your fingers.");
245 break; 245 break;
246 case EMOTE_SNEEZE: 246 case EMOTE_SNEEZE:
247 sprintf (buf, "%s sneezes.", &op->name); 247 sprintf (buf, "%s sneezes.", &op->name);
248 sprintf (buf2, "Gesundheit!"); 248 sprintf (buf2, "Gesundheit!");
249 break; 249 break;
250 case EMOTE_SNICKER: 250 case EMOTE_SNICKER:
251 sprintf (buf, "%s snickers softly.", &op->name); 251 sprintf (buf, "%s snickers softly.", &op->name);
252 sprintf (buf2, "You snicker softly."); 252 sprintf (buf2, "You snicker softly.");
253 break; 253 break;
254 case EMOTE_SNIFF: 254 case EMOTE_SNIFF:
255 sprintf (buf, "%s sniffs sadly.", &op->name); 255 sprintf (buf, "%s sniffs sadly.", &op->name);
256 sprintf (buf2, "You sniff sadly. *SNIFF*"); 256 sprintf (buf2, "You sniff sadly. *SNIFF*");
257 break; 257 break;
258 case EMOTE_SNORE: 258 case EMOTE_SNORE:
259 sprintf (buf, "%s snores loudly.", &op->name); 259 sprintf (buf, "%s snores loudly.", &op->name);
260 sprintf (buf2, "Zzzzzzzzzzzzzzz."); 260 sprintf (buf2, "Zzzzzzzzzzzzzzz.");
261 break; 261 break;
262 case EMOTE_SPIT: 262 case EMOTE_SPIT:
263 sprintf (buf, "%s spits over his left shoulder.", &op->name); 263 sprintf (buf, "%s spits over his left shoulder.", &op->name);
264 sprintf (buf2, "You spit over your left shoulder."); 264 sprintf (buf2, "You spit over your left shoulder.");
265 break; 265 break;
266 case EMOTE_STRUT: 266 case EMOTE_STRUT:
267 sprintf (buf, "%s struts proudly.", &op->name); 267 sprintf (buf, "%s struts proudly.", &op->name);
268 sprintf (buf2, "Strut your stuff."); 268 sprintf (buf2, "Strut your stuff.");
269 break; 269 break;
270 case EMOTE_TWIDDLE: 270 case EMOTE_TWIDDLE:
271 sprintf (buf, "%s patiently twiddles his thumbs.", &op->name); 271 sprintf (buf, "%s patiently twiddles his thumbs.", &op->name);
272 sprintf (buf2, "You patiently twiddle your thumbs."); 272 sprintf (buf2, "You patiently twiddle your thumbs.");
273 break; 273 break;
274 case EMOTE_WAVE: 274 case EMOTE_WAVE:
275 sprintf (buf, "%s waves happily.", &op->name); 275 sprintf (buf, "%s waves happily.", &op->name);
276 sprintf (buf2, "You wave."); 276 sprintf (buf2, "You wave.");
277 break; 277 break;
278 case EMOTE_WHISTLE: 278 case EMOTE_WHISTLE:
279 sprintf (buf, "%s whistles appreciatively.", &op->name); 279 sprintf (buf, "%s whistles appreciatively.", &op->name);
280 sprintf (buf2, "You whistle appreciatively."); 280 sprintf (buf2, "You whistle appreciatively.");
281 break; 281 break;
282 case EMOTE_WINK: 282 case EMOTE_WINK:
283 sprintf (buf, "%s winks suggestively.", &op->name); 283 sprintf (buf, "%s winks suggestively.", &op->name);
284 sprintf (buf2, "Have you got something in your eye?"); 284 sprintf (buf2, "Have you got something in your eye?");
285 break; 285 break;
286 case EMOTE_YAWN: 286 case EMOTE_YAWN:
287 sprintf (buf, "%s yawns sleepily.", &op->name); 287 sprintf (buf, "%s yawns sleepily.", &op->name);
288 sprintf (buf2, "You open up your yap and let out a big breeze " "of stale air."); 288 sprintf (buf2, "You open up your yap and let out a big breeze " "of stale air.");
289 break; 289 break;
290 case EMOTE_CRINGE: 290 case EMOTE_CRINGE:
291 sprintf (buf, "%s cringes in terror!", &op->name); 291 sprintf (buf, "%s cringes in terror!", &op->name);
292 sprintf (buf2, "You cringe in terror."); 292 sprintf (buf2, "You cringe in terror.");
293 break; 293 break;
294 case EMOTE_BLEED: 294 case EMOTE_BLEED:
295 sprintf (buf, "%s is bleeding all over the carpet" " - got a spare tourniquet?", &op->name); 295 sprintf (buf, "%s is bleeding all over the carpet" " - got a spare tourniquet?", &op->name);
296 sprintf (buf2, "You bleed all over your nice new armour."); 296 sprintf (buf2, "You bleed all over your nice new armour.");
297 break; 297 break;
298 case EMOTE_THINK: 298 case EMOTE_THINK:
299 sprintf (buf, "%s closes his eyes and thinks really hard.", &op->name); 299 sprintf (buf, "%s closes his eyes and thinks really hard.", &op->name);
300 sprintf (buf2, "Anything in particular that you'd care to think " "about?"); 300 sprintf (buf2, "Anything in particular that you'd care to think " "about?");
301 break; 301 break;
302 default: 302 default:
303 sprintf (buf, "%s dances with glee.", &op->name); 303 sprintf (buf, "%s dances with glee.", &op->name);
304 sprintf (buf2, "You are a nut."); 304 sprintf (buf2, "You are a nut.");
305 break; 305 break;
306 } /*case */ 306 } /*case */
307
307 new_info_map_except (NDI_WHITE, op->map, op, buf); 308 new_info_map_except (NDI_WHITE, op->map, op, buf);
308 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, op, buf2); 309 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, op, buf2);
309 return (0); 310 return (0);
310 } 311 }
311 else 312 else
316 pl->ob->map == op->map && pl->ob != op && !(QUERY_FLAG (pl->ob, FLAG_WIZ) && pl->ob->contr->hidden)) 317 pl->ob->map == op->map && pl->ob != op && !(QUERY_FLAG (pl->ob, FLAG_WIZ) && pl->ob->contr->hidden))
317 { 318 {
318 /* Hidden dms are not affected by emotions */ 319 /* Hidden dms are not affected by emotions */
319 switch (emotion) 320 switch (emotion)
320 { 321 {
321 case EMOTE_NOD: 322 case EMOTE_NOD:
322 sprintf (buf, "You nod solemnly to %s.", &pl->ob->name); 323 sprintf (buf, "You nod solemnly to %s.", &pl->ob->name);
323 sprintf (buf2, "%s nods solemnly to you.", &op->name); 324 sprintf (buf2, "%s nods solemnly to you.", &op->name);
324 sprintf (buf3, "%s nods solemnly to %s.", &op->name, &pl->ob->name); 325 sprintf (buf3, "%s nods solemnly to %s.", &op->name, &pl->ob->name);
325 break; 326 break;
326 case EMOTE_DANCE: 327 case EMOTE_DANCE:
327 sprintf (buf, "You grab %s and begin doing the Cha-Cha!", &pl->ob->name); 328 sprintf (buf, "You grab %s and begin doing the Cha-Cha!", &pl->ob->name);
328 sprintf (buf2, "%s grabs you, and begins dancing!", &op->name); 329 sprintf (buf2, "%s grabs you, and begins dancing!", &op->name);
329 sprintf (buf3, "Yipe! %s and %s are doing the Macarena!", &op->name, &pl->ob->name); 330 sprintf (buf3, "Yipe! %s and %s are doing the Macarena!", &op->name, &pl->ob->name);
330 break; 331 break;
331 case EMOTE_KISS: 332 case EMOTE_KISS:
332 sprintf (buf, "You kiss %s.", &pl->ob->name); 333 sprintf (buf, "You kiss %s.", &pl->ob->name);
333 sprintf (buf2, "%s kisses you.", &op->name); 334 sprintf (buf2, "%s kisses you.", &op->name);
334 sprintf (buf3, "%s kisses %s.", &op->name, &pl->ob->name); 335 sprintf (buf3, "%s kisses %s.", &op->name, &pl->ob->name);
335 break; 336 break;
336 case EMOTE_BOUNCE: 337 case EMOTE_BOUNCE:
337 sprintf (buf, "You bounce around the room with %s.", &pl->ob->name); 338 sprintf (buf, "You bounce around the room with %s.", &pl->ob->name);
338 sprintf (buf2, "%s bounces around the room with you.", &op->name); 339 sprintf (buf2, "%s bounces around the room with you.", &op->name);
339 sprintf (buf3, "%s bounces around the room with %s.", &op->name, &pl->ob->name); 340 sprintf (buf3, "%s bounces around the room with %s.", &op->name, &pl->ob->name);
340 break; 341 break;
341 case EMOTE_SMILE: 342 case EMOTE_SMILE:
342 sprintf (buf, "You smile at %s.", &pl->ob->name); 343 sprintf (buf, "You smile at %s.", &pl->ob->name);
343 sprintf (buf2, "%s smiles at you.", &op->name); 344 sprintf (buf2, "%s smiles at you.", &op->name);
344 sprintf (buf3, "%s beams a smile at %s.", &op->name, &pl->ob->name); 345 sprintf (buf3, "%s beams a smile at %s.", &op->name, &pl->ob->name);
345 break; 346 break;
346 case EMOTE_LAUGH: 347 case EMOTE_LAUGH:
347 sprintf (buf, "You take one look at %s and fall down " "laughing.", &pl->ob->name); 348 sprintf (buf, "You take one look at %s and fall down " "laughing.", &pl->ob->name);
348 sprintf (buf2, "%s looks at you and falls down on the " "ground laughing.", &op->name); 349 sprintf (buf2, "%s looks at you and falls down on the " "ground laughing.", &op->name);
349 sprintf (buf3, "%s looks at %s and falls down on the " "ground laughing.", &op->name, &pl->ob->name); 350 sprintf (buf3, "%s looks at %s and falls down on the " "ground laughing.", &op->name, &pl->ob->name);
350 break; 351 break;
351 case EMOTE_SHAKE: 352 case EMOTE_SHAKE:
352 sprintf (buf, "You shake %s's hand.", &pl->ob->name); 353 sprintf (buf, "You shake %s's hand.", &pl->ob->name);
353 sprintf (buf2, "%s shakes your hand.", &op->name); 354 sprintf (buf2, "%s shakes your hand.", &op->name);
354 sprintf (buf3, "%s shakes %s's hand.", &op->name, &pl->ob->name); 355 sprintf (buf3, "%s shakes %s's hand.", &op->name, &pl->ob->name);
355 break; 356 break;
356 case EMOTE_PUKE: 357 case EMOTE_PUKE:
357 sprintf (buf, "You puke on %s.", &pl->ob->name); 358 sprintf (buf, "You puke on %s.", &pl->ob->name);
358 sprintf (buf2, "%s pukes on your clothes!", &op->name); 359 sprintf (buf2, "%s pukes on your clothes!", &op->name);
359 sprintf (buf3, "%s pukes on %s.", &op->name, &pl->ob->name); 360 sprintf (buf3, "%s pukes on %s.", &op->name, &pl->ob->name);
360 break; 361 break;
361 case EMOTE_HUG: 362 case EMOTE_HUG:
362 sprintf (buf, "You hug %s.", &pl->ob->name); 363 sprintf (buf, "You hug %s.", &pl->ob->name);
363 sprintf (buf2, "%s hugs you.", &op->name); 364 sprintf (buf2, "%s hugs you.", &op->name);
364 sprintf (buf3, "%s hugs %s.", &op->name, &pl->ob->name); 365 sprintf (buf3, "%s hugs %s.", &op->name, &pl->ob->name);
365 break; 366 break;
366 case EMOTE_CRY: 367 case EMOTE_CRY:
367 sprintf (buf, "You cry on %s's shoulder.", &pl->ob->name); 368 sprintf (buf, "You cry on %s's shoulder.", &pl->ob->name);
368 sprintf (buf2, "%s cries on your shoulder.", &op->name); 369 sprintf (buf2, "%s cries on your shoulder.", &op->name);
369 sprintf (buf3, "%s cries on %s's shoulder.", &op->name, &pl->ob->name); 370 sprintf (buf3, "%s cries on %s's shoulder.", &op->name, &pl->ob->name);
370 break; 371 break;
371 case EMOTE_POKE: 372 case EMOTE_POKE:
372 sprintf (buf, "You poke %s in the ribs.", &pl->ob->name); 373 sprintf (buf, "You poke %s in the ribs.", &pl->ob->name);
373 sprintf (buf2, "%s pokes you in the ribs.", &op->name); 374 sprintf (buf2, "%s pokes you in the ribs.", &op->name);
374 sprintf (buf3, "%s pokes %s in the ribs.", &op->name, &pl->ob->name); 375 sprintf (buf3, "%s pokes %s in the ribs.", &op->name, &pl->ob->name);
375 break; 376 break;
376 case EMOTE_ACCUSE: 377 case EMOTE_ACCUSE:
377 sprintf (buf, "You look accusingly at %s.", &pl->ob->name); 378 sprintf (buf, "You look accusingly at %s.", &pl->ob->name);
378 sprintf (buf2, "%s looks accusingly at you.", &op->name); 379 sprintf (buf2, "%s looks accusingly at you.", &op->name);
379 sprintf (buf3, "%s looks accusingly at %s.", &op->name, &pl->ob->name); 380 sprintf (buf3, "%s looks accusingly at %s.", &op->name, &pl->ob->name);
380 break; 381 break;
381 case EMOTE_GRIN: 382 case EMOTE_GRIN:
382 sprintf (buf, "You grin at %s.", &pl->ob->name); 383 sprintf (buf, "You grin at %s.", &pl->ob->name);
383 sprintf (buf2, "%s grins evilly at you.", &op->name); 384 sprintf (buf2, "%s grins evilly at you.", &op->name);
384 sprintf (buf3, "%s grins evilly at %s.", &op->name, &pl->ob->name); 385 sprintf (buf3, "%s grins evilly at %s.", &op->name, &pl->ob->name);
385 break; 386 break;
386 case EMOTE_BOW: 387 case EMOTE_BOW:
387 sprintf (buf, "You bow before %s.", &pl->ob->name); 388 sprintf (buf, "You bow before %s.", &pl->ob->name);
388 sprintf (buf2, "%s bows before you.", &op->name); 389 sprintf (buf2, "%s bows before you.", &op->name);
389 sprintf (buf3, "%s bows before %s.", &op->name, &pl->ob->name); 390 sprintf (buf3, "%s bows before %s.", &op->name, &pl->ob->name);
390 break; 391 break;
391 case EMOTE_FROWN: 392 case EMOTE_FROWN:
392 sprintf (buf, "You frown darkly at %s.", &pl->ob->name); 393 sprintf (buf, "You frown darkly at %s.", &pl->ob->name);
393 sprintf (buf2, "%s frowns darkly at you.", &op->name); 394 sprintf (buf2, "%s frowns darkly at you.", &op->name);
394 sprintf (buf3, "%s frowns darkly at %s.", &op->name, &pl->ob->name); 395 sprintf (buf3, "%s frowns darkly at %s.", &op->name, &pl->ob->name);
395 break; 396 break;
396 case EMOTE_GLARE: 397 case EMOTE_GLARE:
397 sprintf (buf, "You glare icily at %s.", &pl->ob->name); 398 sprintf (buf, "You glare icily at %s.", &pl->ob->name);
398 sprintf (buf2, "%s glares icily at you, you feel cold to" " your bones.", &op->name); 399 sprintf (buf2, "%s glares icily at you, you feel cold to" " your bones.", &op->name);
399 sprintf (buf3, "%s glares at %s.", &op->name, &pl->ob->name); 400 sprintf (buf3, "%s glares at %s.", &op->name, &pl->ob->name);
400 break; 401 break;
401 case EMOTE_LICK: 402 case EMOTE_LICK:
402 sprintf (buf, "You lick %s.", &pl->ob->name); 403 sprintf (buf, "You lick %s.", &pl->ob->name);
403 sprintf (buf2, "%s licks you.", &op->name); 404 sprintf (buf2, "%s licks you.", &op->name);
404 sprintf (buf3, "%s licks %s.", &op->name, &pl->ob->name); 405 sprintf (buf3, "%s licks %s.", &op->name, &pl->ob->name);
405 break; 406 break;
406 case EMOTE_SHRUG: 407 case EMOTE_SHRUG:
407 sprintf (buf, "You shrug at %s.", &pl->ob->name); 408 sprintf (buf, "You shrug at %s.", &pl->ob->name);
408 sprintf (buf2, "%s shrugs at you.", &op->name); 409 sprintf (buf2, "%s shrugs at you.", &op->name);
409 sprintf (buf3, "%s shrugs at %s.", &op->name, &pl->ob->name); 410 sprintf (buf3, "%s shrugs at %s.", &op->name, &pl->ob->name);
410 break; 411 break;
411 case EMOTE_SLAP: 412 case EMOTE_SLAP:
412 sprintf (buf, "You slap %s.", &pl->ob->name); 413 sprintf (buf, "You slap %s.", &pl->ob->name);
413 sprintf (buf2, "You are slapped by %s.", &op->name); 414 sprintf (buf2, "You are slapped by %s.", &op->name);
414 sprintf (buf3, "%s slaps %s.", &op->name, &pl->ob->name); 415 sprintf (buf3, "%s slaps %s.", &op->name, &pl->ob->name);
415 break; 416 break;
416 case EMOTE_SNEEZE: 417 case EMOTE_SNEEZE:
417 sprintf (buf, "You sneeze at %s and a film of snot shoots" " onto him.", &pl->ob->name); 418 sprintf (buf, "You sneeze at %s and a film of snot shoots" " onto him.", &pl->ob->name);
418 sprintf (buf2, "%s sneezes on you, you feel the snot cover" " you. EEEEEEW.", &op->name); 419 sprintf (buf2, "%s sneezes on you, you feel the snot cover" " you. EEEEEEW.", &op->name);
419 sprintf (buf3, "%s sneezes on %s and a film of snot covers" " him.", &op->name, &pl->ob->name); 420 sprintf (buf3, "%s sneezes on %s and a film of snot covers" " him.", &op->name, &pl->ob->name);
420 break; 421 break;
421 case EMOTE_SNIFF: 422 case EMOTE_SNIFF:
422 sprintf (buf, "You sniff %s.", &pl->ob->name); 423 sprintf (buf, "You sniff %s.", &pl->ob->name);
423 sprintf (buf2, "%s sniffs you.", &op->name); 424 sprintf (buf2, "%s sniffs you.", &op->name);
424 sprintf (buf3, "%s sniffs %s", &op->name, &pl->ob->name); 425 sprintf (buf3, "%s sniffs %s", &op->name, &pl->ob->name);
425 break; 426 break;
426 case EMOTE_SPIT: 427 case EMOTE_SPIT:
427 sprintf (buf, "You spit on %s.", &pl->ob->name); 428 sprintf (buf, "You spit on %s.", &pl->ob->name);
428 sprintf (buf2, "%s spits in your face!", &op->name); 429 sprintf (buf2, "%s spits in your face!", &op->name);
429 sprintf (buf3, "%s spits in %s's face.", &op->name, &pl->ob->name); 430 sprintf (buf3, "%s spits in %s's face.", &op->name, &pl->ob->name);
430 break; 431 break;
431 case EMOTE_THANK: 432 case EMOTE_THANK:
432 sprintf (buf, "You thank %s heartily.", &pl->ob->name); 433 sprintf (buf, "You thank %s heartily.", &pl->ob->name);
433 sprintf (buf2, "%s thanks you heartily.", &op->name); 434 sprintf (buf2, "%s thanks you heartily.", &op->name);
434 sprintf (buf3, "%s thanks %s heartily.", &op->name, &pl->ob->name); 435 sprintf (buf3, "%s thanks %s heartily.", &op->name, &pl->ob->name);
435 break; 436 break;
436 case EMOTE_WAVE: 437 case EMOTE_WAVE:
437 sprintf (buf, "You wave goodbye to %s.", &pl->ob->name); 438 sprintf (buf, "You wave goodbye to %s.", &pl->ob->name);
438 sprintf (buf2, "%s waves goodbye to you. Have a good" " journey.", &op->name); 439 sprintf (buf2, "%s waves goodbye to you. Have a good" " journey.", &op->name);
439 sprintf (buf3, "%s waves goodbye to %s.", &op->name, &pl->ob->name); 440 sprintf (buf3, "%s waves goodbye to %s.", &op->name, &pl->ob->name);
440 break; 441 break;
441 case EMOTE_WHISTLE: 442 case EMOTE_WHISTLE:
442 sprintf (buf, "You whistle at %s.", &pl->ob->name); 443 sprintf (buf, "You whistle at %s.", &pl->ob->name);
443 sprintf (buf2, "%s whistles at you.", &op->name); 444 sprintf (buf2, "%s whistles at you.", &op->name);
444 sprintf (buf2, "%s whistles at %s.", &op->name, &pl->ob->name); 445 sprintf (buf2, "%s whistles at %s.", &op->name, &pl->ob->name);
445 break; 446 break;
446 case EMOTE_WINK: 447 case EMOTE_WINK:
447 sprintf (buf, "You wink suggestively at %s.", &pl->ob->name); 448 sprintf (buf, "You wink suggestively at %s.", &pl->ob->name);
448 sprintf (buf2, "%s winks suggestively at you.", &op->name); 449 sprintf (buf2, "%s winks suggestively at you.", &op->name);
449 sprintf (buf2, "%s winks at %s.", &op->name, &pl->ob->name); 450 sprintf (buf2, "%s winks at %s.", &op->name, &pl->ob->name);
450 break; 451 break;
451 case EMOTE_BEG: 452 case EMOTE_BEG:
452 sprintf (buf, "You beg %s for mercy.", &pl->ob->name); 453 sprintf (buf, "You beg %s for mercy.", &pl->ob->name);
453 sprintf (buf2, "%s begs you for mercy! Show no quarter!", &op->name); 454 sprintf (buf2, "%s begs you for mercy! Show no quarter!", &op->name);
454 sprintf (buf2, "%s begs %s for mercy!", &op->name, &pl->ob->name); 455 sprintf (buf2, "%s begs %s for mercy!", &op->name, &pl->ob->name);
455 break; 456 break;
456 case EMOTE_BLEED: 457 case EMOTE_BLEED:
457 sprintf (buf, "You slash your wrist and bleed all over %s", &pl->ob->name); 458 sprintf (buf, "You slash your wrist and bleed all over %s", &pl->ob->name);
458 sprintf (buf2, "%s slashes his wrist and bleeds all over" " you.", &op->name); 459 sprintf (buf2, "%s slashes his wrist and bleeds all over" " you.", &op->name);
459 sprintf (buf2, "%s slashes his wrist and bleeds all " "over %s.", &op->name, &pl->ob->name); 460 sprintf (buf2, "%s slashes his wrist and bleeds all " "over %s.", &op->name, &pl->ob->name);
460 break; 461 break;
461 case EMOTE_CRINGE: 462 case EMOTE_CRINGE:
462 sprintf (buf, "You cringe away from %s.", &pl->ob->name); 463 sprintf (buf, "You cringe away from %s.", &pl->ob->name);
463 sprintf (buf2, "%s cringes away from you.", &op->name); 464 sprintf (buf2, "%s cringes away from you.", &op->name);
464 sprintf (buf2, "%s cringes away from %s in mortal terror.", &op->name, &pl->ob->name); 465 sprintf (buf2, "%s cringes away from %s in mortal terror.", &op->name, &pl->ob->name);
465 break; 466 break;
466 default: 467 default:
467 sprintf (buf, "You are still nuts."); 468 sprintf (buf, "You are still nuts.");
468 sprintf (buf2, "You get the distinct feeling that %s is nuts.", &op->name); 469 sprintf (buf2, "You get the distinct feeling that %s is nuts.", &op->name);
469 sprintf (buf3, "%s is eyeing %s quizzically.", &pl->ob->name, &op->name); 470 sprintf (buf3, "%s is eyeing %s quizzically.", &pl->ob->name, &op->name);
470 break; 471 break;
471 } /*case */ 472 } /*case */
473
472 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, op, buf); 474 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, op, buf);
473 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, pl->ob, buf2); 475 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, pl->ob, buf2);
474 new_info_map_except2 (NDI_WHITE, op->map, op, pl->ob, buf3); 476 new_info_map_except2 (NDI_WHITE, op->map, op, pl->ob, buf3);
475 return (0); 477 return (0);
476 } 478 }
477 if (strncasecmp (pl->ob->name, params, MAX_NAME) == 0 && pl->ob->map == op->map && pl->ob == op) 479 if (strncasecmp (pl->ob->name, params, MAX_NAME) == 0 && pl->ob->map == op->map && pl->ob == op)
478 { 480 {
479 switch (emotion) 481 switch (emotion)
480 { 482 {
481 case EMOTE_DANCE: 483 case EMOTE_DANCE:
482 sprintf (buf, "You skip and dance around by yourself."); 484 sprintf (buf, "You skip and dance around by yourself.");
483 sprintf (buf2, "%s embraces himself and begins to dance!", &op->name); 485 sprintf (buf2, "%s embraces himself and begins to dance!", &op->name);
484 break; 486 break;
485 case EMOTE_LAUGH: 487 case EMOTE_LAUGH:
486 sprintf (buf, "Laugh at yourself all you want, the others " "won't understand."); 488 sprintf (buf, "Laugh at yourself all you want, the others " "won't understand.");
487 sprintf (buf2, "%s is laughing at something.", &op->name); 489 sprintf (buf2, "%s is laughing at something.", &op->name);
488 break; 490 break;
489 case EMOTE_SHAKE: 491 case EMOTE_SHAKE:
490 sprintf (buf, "You are shaken by yourself."); 492 sprintf (buf, "You are shaken by yourself.");
491 sprintf (buf2, "%s shakes and quivers like a bowlful of " "jelly.", &op->name); 493 sprintf (buf2, "%s shakes and quivers like a bowlful of " "jelly.", &op->name);
492 break; 494 break;
493 case EMOTE_PUKE: 495 case EMOTE_PUKE:
494 sprintf (buf, "You puke on yourself."); 496 sprintf (buf, "You puke on yourself.");
495 sprintf (buf2, "%s pukes on his clothes.", &op->name); 497 sprintf (buf2, "%s pukes on his clothes.", &op->name);
496 break; 498 break;
497 case EMOTE_HUG: 499 case EMOTE_HUG:
498 sprintf (buf, "You hug yourself."); 500 sprintf (buf, "You hug yourself.");
499 sprintf (buf2, "%s hugs himself.", &op->name); 501 sprintf (buf2, "%s hugs himself.", &op->name);
500 break; 502 break;
501 case EMOTE_CRY: 503 case EMOTE_CRY:
502 sprintf (buf, "You cry to yourself."); 504 sprintf (buf, "You cry to yourself.");
503 sprintf (buf2, "%s sobs quietly to himself.", &op->name); 505 sprintf (buf2, "%s sobs quietly to himself.", &op->name);
504 break; 506 break;
505 case EMOTE_POKE: 507 case EMOTE_POKE:
506 sprintf (buf, "You poke yourself in the ribs, feeling very" " silly."); 508 sprintf (buf, "You poke yourself in the ribs, feeling very" " silly.");
507 sprintf (buf2, "%s pokes himself in the ribs, looking very" " sheepish.", &op->name); 509 sprintf (buf2, "%s pokes himself in the ribs, looking very" " sheepish.", &op->name);
508 break; 510 break;
509 case EMOTE_ACCUSE: 511 case EMOTE_ACCUSE:
510 sprintf (buf, "You accuse yourself."); 512 sprintf (buf, "You accuse yourself.");
511 sprintf (buf2, "%s seems to have a bad conscience.", &op->name); 513 sprintf (buf2, "%s seems to have a bad conscience.", &op->name);
512 break; 514 break;
513 case EMOTE_BOW: 515 case EMOTE_BOW:
514 sprintf (buf, "You kiss your toes."); 516 sprintf (buf, "You kiss your toes.");
515 sprintf (buf2, "%s folds up like a jackknife and kisses his" " own toes.", &op->name); 517 sprintf (buf2, "%s folds up like a jackknife and kisses his" " own toes.", &op->name);
516 break; 518 break;
517 case EMOTE_FROWN: 519 case EMOTE_FROWN:
518 sprintf (buf, "You frown at yourself."); 520 sprintf (buf, "You frown at yourself.");
519 sprintf (buf2, "%s frowns at himself.", &op->name); 521 sprintf (buf2, "%s frowns at himself.", &op->name);
520 break; 522 break;
521 case EMOTE_GLARE: 523 case EMOTE_GLARE:
522 sprintf (buf, "You glare icily at your feet, they are " "suddenly very cold."); 524 sprintf (buf, "You glare icily at your feet, they are " "suddenly very cold.");
523 sprintf (buf2, "%s glares at his feet, what is bothering " "him?", &op->name); 525 sprintf (buf2, "%s glares at his feet, what is bothering " "him?", &op->name);
524 break; 526 break;
525 case EMOTE_LICK: 527 case EMOTE_LICK:
526 sprintf (buf, "You lick yourself."); 528 sprintf (buf, "You lick yourself.");
527 sprintf (buf2, "%s licks himself - YUCK.", &op->name); 529 sprintf (buf2, "%s licks himself - YUCK.", &op->name);
528 break; 530 break;
529 case EMOTE_SLAP: 531 case EMOTE_SLAP:
530 sprintf (buf, "You slap yourself, silly you."); 532 sprintf (buf, "You slap yourself, silly you.");
531 sprintf (buf2, "%s slaps himself, really strange...", &op->name); 533 sprintf (buf2, "%s slaps himself, really strange...", &op->name);
532 break; 534 break;
533 case EMOTE_SNEEZE: 535 case EMOTE_SNEEZE:
534 sprintf (buf, "You sneeze on yourself, what a mess!"); 536 sprintf (buf, "You sneeze on yourself, what a mess!");
535 sprintf (buf2, "%s sneezes, and covers himself in a slimy" " substance.", &op->name); 537 sprintf (buf2, "%s sneezes, and covers himself in a slimy" " substance.", &op->name);
536 break; 538 break;
537 case EMOTE_SNIFF: 539 case EMOTE_SNIFF:
538 sprintf (buf, "You sniff yourself."); 540 sprintf (buf, "You sniff yourself.");
539 sprintf (buf2, "%s sniffs himself.", &op->name); 541 sprintf (buf2, "%s sniffs himself.", &op->name);
540 break; 542 break;
541 case EMOTE_SPIT: 543 case EMOTE_SPIT:
542 sprintf (buf, "You drool all over yourself."); 544 sprintf (buf, "You drool all over yourself.");
543 sprintf (buf2, "%s drools all over himself.", &op->name); 545 sprintf (buf2, "%s drools all over himself.", &op->name);
544 break; 546 break;
545 case EMOTE_THANK: 547 case EMOTE_THANK:
546 sprintf (buf, "You thank yourself since nobody else " "wants to!"); 548 sprintf (buf, "You thank yourself since nobody else " "wants to!");
547 sprintf (buf2, "%s thanks himself since you won't.", &op->name); 549 sprintf (buf2, "%s thanks himself since you won't.", &op->name);
548 break; 550 break;
549 case EMOTE_WAVE: 551 case EMOTE_WAVE:
550 sprintf (buf, "Are you going on adventures as well??"); 552 sprintf (buf, "Are you going on adventures as well??");
551 sprintf (buf2, "%s waves goodbye to himself.", &op->name); 553 sprintf (buf2, "%s waves goodbye to himself.", &op->name);
552 break; 554 break;
553 case EMOTE_WHISTLE: 555 case EMOTE_WHISTLE:
554 sprintf (buf, "You whistle while you work."); 556 sprintf (buf, "You whistle while you work.");
555 sprintf (buf2, "%s whistles to himself in boredom.", &op->name); 557 sprintf (buf2, "%s whistles to himself in boredom.", &op->name);
556 break; 558 break;
557 case EMOTE_WINK: 559 case EMOTE_WINK:
558 sprintf (buf, "You wink at yourself?? What are you up to?"); 560 sprintf (buf, "You wink at yourself?? What are you up to?");
559 sprintf (buf2, "%s winks at himself - something strange " "is going on...", &op->name); 561 sprintf (buf2, "%s winks at himself - something strange " "is going on...", &op->name);
560 break; 562 break;
561 case EMOTE_BLEED: 563 case EMOTE_BLEED:
562 sprintf (buf, "Very impressive! You wipe your blood all " "over yourself."); 564 sprintf (buf, "Very impressive! You wipe your blood all " "over yourself.");
563 sprintf (buf2, "%s performs some satanic ritual while " "wiping his blood on himself.", &op->name); 565 sprintf (buf2, "%s performs some satanic ritual while " "wiping his blood on himself.", &op->name);
564 break; 566 break;
565 default: 567 default:
566 sprintf (buf, "My god! is that LEGAL?"); 568 sprintf (buf, "My god! is that LEGAL?");
567 sprintf (buf2, "You look away from %s.", &op->name); 569 sprintf (buf2, "You look away from %s.", &op->name);
568 break; 570 break;
569 } /*case */ 571 } /*case */
570 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, op, buf); 572 new_draw_info (NDI_UNIQUE | NDI_WHITE, 0, op, buf);
571 new_info_map_except (NDI_WHITE, op->map, op, buf2); 573 new_info_map_except (NDI_WHITE, op->map, op, buf2);
572 return (0); 574 return (0);
573 } /*if self */ 575 } /*if self */
574 } /*for */ 576 } /*for */
577
575 new_draw_info_format (NDI_UNIQUE, 0, op, "%s is not around.", params); 578 new_draw_info_format (NDI_UNIQUE, 0, op, "%s is not around.", params);
576 return (1); 579 return (1);
577 } /*else */ 580 } /*else */
578 581
579 return (0); 582 return (0);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines