Including VoiceInterface.h causes compiling to fail until you include OnlineSubsystem.h in the same file.

This is not expected because VoiceInterface.h is part of the OnlineSubsystem module which has been uncommented in the build.cs file.

Found in 4.14.0 CL# 3195953. Reproduced in 4.13.0 CL# 3172292

Steps to Reproduce
  1. Open a code project
  2. In the project's header file, add #include "UnrealNetwork.h"
  3. Navigate to the Build.cs and uncomment the Online Subsystem section
  4. In one of your code files, add #include "VoiceInterface.h"
  5. Build the project

Result: Build fails with the following errors:

Error (active) cannot open source file "VoiceInterface.h"

Error C2061 syntax error: identifier 'OnPlayerTalkingStateChanged' CodeTestBed
Error C4430 missing type specifier - int assumed. Note: C++ does not support default-int CodeTestBed
Error C4183 'DEFINE_ONLINE_DELEGATE_TWO_PARAM': missing return type; assumed to be a member function returning 'int' CodeTestBed

Expected: Since VoiceInterface.h is included in the OnlineSubsystemModule, the project would build successfully once that module was included in the build.cs

Have Comments or More Details?

Head over to the existing Questions & Answers thread and let us know what's up.

Login to Vote

ComponentUE - Networking
Affects Versions4.134.144.15
Fix Commit3217465
CreatedNov 30, 2016
ResolvedDec 1, 2016
UpdatedJul 14, 2021
View Jira Issue