private void OnSpeakAttempt(EntityUid uid, SharedSpeechComponent component, SpeakAttemptEvent args)
 {
     if (!component.Enabled)
     {
         args.Cancel();
     }
 }
Esempio n. 2
0
 private void OnSpeakAttempt(SpeakAttemptEvent args)
 {
     if (!TryComp(args.Uid, out SharedSpeechComponent? speech) || !speech.Enabled)
     {
         args.Cancel();
     }
 }
 private void OnSpeakAttempt(SpeakAttemptEvent ev)
 {
     if (!ev.Entity.HasComponent <SharedSpeechComponent>())
     {
         ev.Cancel();
     }
 }