SlideShare a Scribd company logo
1 of 22
Download to read offline
UnrealEngine初心者が通信と
音声通話のプラットフォームを
選定してみた
@mechamogera
自己紹介
• @mechamogera
• GithubやQiitaメインで活動
• 最近のお仕事:UnrealEngineを用いた3Dアプリ開発、AWS lambdaや
Batch・Serverless Frameworkを用いたAPI開発
目次
• UnrealEngineとはとやりたいこと
• 最初に想定していたネットワークの選定条件
• OnlineSubsystem
• ネットワークサービス調査結果
• OnlineSubsystemの利用について
UnrealEngineとは
• UnrealEngine4(以下UE4)
• 公開されて無料になったゲームエンジン
• UnityとかAmazon Sumerianなどと同じような3Dプログラミング開発環境提
供
• ソースコードが公開
• UnityがWindowsならUE4はMacのイメージ
UE4でやりたいこと
• 他の人と空間を共有するVRアプリの開発
• 実現のためにネットワークサービスの選定が必要
• なるべくマネージドなサービス利用
• なるべく無料なサービス利用
選定直後に思っていた条件
• UE4はC++でコードかける
• C++でネットワークサービスのAPIたたければ使えそう
• あまり実装で消耗したくないのでなるべくsdkが欲しい
以前に作った構成
ヘッドセット、両手の位置と回転情報を送信
送信側でヘッドセットと両手を再現
音声やり取り
自前プロトコル
自前で送信された情報を
もとにオブジェクト作成、
位置/回転同期
OnlineSubsystem
• UE4には各プラットフォームサービスを抽象化したインターフェースを提
供するOnlineSubsystemが存在
• 以前に作った構成で自前プロトコルを使っていた部分をUE4がやってく
れる
• ゲームで不正をされないようにセキュリティを考慮
• => なるべくOnlineSubsystem利用したい
OnlineSubsystem
UE4
OnlineSubsystem
OnlineSubsystemNull OnlineSubsystemSteam OnlineSubsystemOculus
Oculus PlatformSteamOnlineSubsystemNull ...
...
OnlineSubsystemが提供するインターフェース
• フレンド、セッション、ユーザークラウド、リーダーボード、ボ
イス、アチーブメント、外部 UI
• ただし、プラットフォームによっては提供していない機能あり
• https://api.unrealengine.com/JPN/Programming/Online/index.htmlより
OnlineSubsystemが提供するインターフェース
• 目的の機能を提供しているかは
[EditorDIR]/Engine/Plugins/Online/OnlineSubsystemXXX/Source/Privat
e/OnlineSubsystemXXX.cppかPublic/OnlineSubsystemXXX.hあたりを
見れば良さそう
IOnlineSessionPtr FOnlineSubsystemNull::GetSessionInterface() const
{
return SessionInterface; // <= インターフェースあり
}
IOnlineFriendsPtr FOnlineSubsystemNull::GetFriendsInterface() const
{
return nullptr; // <= インターフェースなし
}
IOnlinePartyPtr FOnlineSubsystemNull::GetPartyInterface() const
{
return nullptr; // <= インターフェースなし
}
いろいろサービスを調査
サービス名 ボイスチャット対応 OnlineSubystem 選定内容
Microsoft Playfab 〇
あり(非公式、ボイス
チャット未対応、
SDK用のプラグインあ
り)
ボイスチャット機能が従
量課金
Amazon GameSparks ×
なし(SDK用プラグイン
あり)
ボイスチャット機能がな
い
サービス名 ボイスチャット対応 OnlineSubystem 選定内容
モノビットエンジン 〇 なし
ボイスチャットがUnityで
しか使えなさそう
WebRTC 〇 なし
libwebrtcの変更が激し
く追随が大変そう
Photon 〇 なし
ボイスチャットのSDKが
Unityしかない
EpicOnlineService ×(リリース予定あり) なし
いろいろな機能を無料
で提供予定
まだ大部分の機能が未
リリース
サービス名 ボイスチャット対応 OnlineSubystem 選定内容
OnlineSubsystemNull 〇 あり
通信範囲が単一サブ
ネットの範囲
(サブネット複数の企業
内LANでは使い物に
ならない)
OnlineSubsystemSteam 〇 あり
プラットフォームがデス
クトップのみ対応
OnlineSubsystemOculus 〇 あり
【選定】
OnlineSubsystemがあり
無料で利用可能
ただし、OculusのHMD
以外で利用不可
その他のUE4に付属の
OnlineSubsystemXXX
× あり セッションの機能なし
OnlineSubsystem分は調査内容をこちらにまとめた
https://qiita.com/mechamogera/items/312333b165b4b9940f09
OnlineSubsystemの簡単な使い方
• セッション、ボイスの接続は簡単
• セッションの主なブループリントはCreateSession、FindSessions、
JoinSession
• http://historia.co.jp/archives/8827/ 参照
• コンソールコマンドでOpen [ipアドレス]で接続するやり方もある(ボイス不
可)
CreateSession
FindSessions & JoinSession
OnlineSubsystemNull
• FindSessionsではbroadcastで接続先を検索
• 単一サブネットの家庭内Lanなどでは検索可
• 複数サブネットの企業内Lanなどではサブネット間の検索不可
• コンソールコマンドでOpen [ipアドレス]で接続するやり方もある(ボイス不
可)
• VirtualBoxやDockerを入れている場合ネットワーク(Dockerの場合
vEthernet(DockerNAT))を無効にする必要あり
OnlineSubsystemSteam
• Steamプラットフォームを利用したOnlineSubsystm
• PCにSteamアプリが入っていてログインしておく必要あり
• モバイル端末はサポートしていない
• 本格運用する場合はアプリ登録が必要(お試し用のサンプルアプリあり)
OnlineSubystemOculus
• Oculusプラットフォームを利用したOnlineSubsystem
• 基本的にはOculusデバイスでしか利用不可
• FindSessionsとCreateSessionは独自のものを利用する必要あり
• UnrealディベロッパーネットワークではOnlineSubsystemの質問あったけど
ドキュメントのソース見てね、だった
• ボイスはC++を
使って接続
• する必要あり
(右の
RegisterRemoteTalker
とGetNetIdは
C++で実装)
• RegisterRemoteTalker
の中身はネットに
あったがGetNetIdは
なくてソース読んだ
所感
• ネットワークの仕組みが組み込まれているのは他になくて良い
• モバイルからPCをカバーするネットワークサービスがない、見つられてい
ない(EpicOnlineServiceがそこを埋めるものになる?)
• 野良OnlineSubsystemXXXがあまりないがなぜ?(実装は簡単そうだが)
• UE4は最後はソースみれるので安心感がある、そしてそのせいかコード
を見ろ文化?

More Related Content

Featured

PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...DevGAMM Conference
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationErica Santiago
 

Featured (20)

PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 
More than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike RoutesMore than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike Routes
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
 

とっとるびー第33回発表資料「UE4のOnlineSubystemをさわってみた」