435 LocalStrs[localLastStr]:= s; |
435 LocalStrs[localLastStr]:= s; |
436 end; |
436 end; |
437 |
437 |
438 t:= LocalTeam; |
438 t:= LocalTeam; |
439 x:= 0; |
439 x:= 0; |
|
440 // speech bubble |
440 if (s[1] = '"') and (s[Length(s)] = '"') |
441 if (s[1] = '"') and (s[Length(s)] = '"') |
441 then x:= 1 |
442 then x:= 1 |
442 |
443 |
|
444 // thinking bubble |
443 else if (s[1] = '''') and (s[Length(s)] = '''') then |
445 else if (s[1] = '''') and (s[Length(s)] = '''') then |
444 x:= 2 |
446 x:= 2 |
445 |
447 |
|
448 // yelling bubble |
446 else if (s[1] = '-') and (s[Length(s)] = '-') then |
449 else if (s[1] = '-') and (s[Length(s)] = '-') then |
447 x:= 3; |
450 x:= 3; |
448 |
451 |
449 if (not CurrentTeam^.ExtDriven) and (x <> 0) then |
452 if (not CurrentTeam^.ExtDriven) and (x <> 0) then |
450 for c:= 0 to Pred(TeamsCount) do |
453 for c:= 0 to Pred(TeamsCount) do |
460 exit |
463 exit |
461 end; |
464 end; |
462 |
465 |
463 if (s[1] = '/') then |
466 if (s[1] = '/') then |
464 begin |
467 begin |
465 // These 3 are same as above, only are to make the hedgehog say it on next attack |
468 |
|
469 // Ignore message-type commands with empty argument list |
|
470 if (copy(s, 2, 2) = 'me') and (Length(s) = 3) then |
|
471 exit; |
|
472 if ((copy(s, 2, 3) = 'hsa') or (copy(s, 2, 3) = 'hta') or (copy(s, 2, 3) = 'hya')) and (Length(s) = 4) then |
|
473 exit; |
|
474 if ((copy(s, 2, 4) = 'team') or (copy(s, 2, 4) = 'clan')) and (Length(s) = 5) then |
|
475 exit; |
|
476 |
|
477 // Speech bubble, but on next attack |
466 if (copy(s, 2, 4) = 'hsa ') then |
478 if (copy(s, 2, 4) = 'hsa ') then |
467 begin |
479 begin |
468 if CurrentTeam^.ExtDriven then |
480 if CurrentTeam^.ExtDriven then |
469 ParseCommand('/say ' + copy(s, 6, Length(s)-5), true) |
481 ParseCommand('/say ' + copy(s, 6, Length(s)-5), true) |
470 else |
482 else |
471 SendHogSpeech(#4 + copy(s, 6, Length(s)-5)); |
483 SendHogSpeech(#4 + copy(s, 6, Length(s)-5)); |
472 exit |
484 exit |
473 end; |
485 end; |
474 |
486 |
|
487 // Thinking bubble, but on next attack |
475 if (copy(s, 2, 4) = 'hta ') then |
488 if (copy(s, 2, 4) = 'hta ') then |
476 begin |
489 begin |
477 if CurrentTeam^.ExtDriven then |
490 if CurrentTeam^.ExtDriven then |
478 ParseCommand('/say ' + copy(s, 6, Length(s)-5), true) |
491 ParseCommand('/say ' + copy(s, 6, Length(s)-5), true) |
479 else |
492 else |
480 SendHogSpeech(#5 + copy(s, 6, Length(s)-5)); |
493 SendHogSpeech(#5 + copy(s, 6, Length(s)-5)); |
481 exit |
494 exit |
482 end; |
495 end; |
483 |
496 |
|
497 // Yelling bubble, but on next attack |
484 if (copy(s, 2, 4) = 'hya ') then |
498 if (copy(s, 2, 4) = 'hya ') then |
485 begin |
499 begin |
486 if CurrentTeam^.ExtDriven then |
500 if CurrentTeam^.ExtDriven then |
487 ParseCommand('/say ' + copy(s, 6, Length(s)-5), true) |
501 ParseCommand('/say ' + copy(s, 6, Length(s)-5), true) |
488 else |
502 else |