x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Accessing Session Interface Functions

So I'm currently trying to access the Voice Interface for OnlineSubsystemNull, so that I can check if a local player is speaking into their microphone. This is what I have at the moment (called within a PlayerController Class):

 return FOnlineSubsystemNull::GetVoiceInterface().IsLocalPlayerTalking(PlayerId)


Visual Studio is telling me that this is an illegal call of non-static member function. However, I don't understand how I'm supposed to access the function any other way. What should I be doing?

Product Version: UE 4.10
Tags:
more ▼

asked Apr 02 '16 at 11:58 AM in C++ Programming

avatar image

IrishMTS
15 4 6 7

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

So as it turns out, I was going about it completely the wrong way. Its not a standalone function, its a class variable, so I need to call it with an object of that class.

This is what it should have been:

     IOnlineSubsystem* OnlineSub = IOnlineSubsystem::Get();
     if (OnlineSub)
     {
         IOnlineVoicePtr VoicePointer = OnlineSub->GetVoiceInterface();
         return VoicePointer->IsLocalPlayerTalking(PlayerId);
     }

The problem I face now is getting the valid PlayerId, but that's a different kettle of fish altogether.

My thanks to this blog, this is what got me the info I wanted.

https://madebykrol.wordpress.com/2015/05/21/unreal-engine-and-online-multiplayer/

more ▼

answered Apr 02 '16 at 01:24 PM

avatar image

IrishMTS
15 4 6 7

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question