質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
C#

C#はマルチパラダイムプログラミング言語の1つで、命令形・宣言型・関数型・ジェネリック型・コンポーネント指向・オブジェクティブ指向のプログラミング開発すべてに対応しています。

Unity3D

Unity3Dは、ゲームや対話式の3Dアプリケーション、トレーニングシュミレーション、そして医学的・建築学的な技術を可視化する、商業用の開発プラットフォームです。

ビルド

ソースコードを単体で実行可能なソフトウェアへ変換する過程をビルド(build)と呼びます

Unity

Unityは、Unity Technologiesが開発・販売している、IDEを内蔵するゲームエンジンです。主にC#を用いたプログラミングでコンテンツの開発が可能です。

Q&A

解決済

1回答

3970閲覧

Macにてunityで作ったゲームがビルドできません。新規プロジェクトでビルドしてもダメです…

marumarumaryu

総合スコア1

C#

C#はマルチパラダイムプログラミング言語の1つで、命令形・宣言型・関数型・ジェネリック型・コンポーネント指向・オブジェクティブ指向のプログラミング開発すべてに対応しています。

Unity3D

Unity3Dは、ゲームや対話式の3Dアプリケーション、トレーニングシュミレーション、そして医学的・建築学的な技術を可視化する、商業用の開発プラットフォームです。

ビルド

ソースコードを単体で実行可能なソフトウェアへ変換する過程をビルド(build)と呼びます

Unity

Unityは、Unity Technologiesが開発・販売している、IDEを内蔵するゲームエンジンです。主にC#を用いたプログラミングでコンテンツの開発が可能です。

0グッド

0クリップ

投稿2021/10/29 18:43

前提・実現したいこと

unityでゲームをMac os用にビルドしようと思ってもエラーが出てビルドできません。
エラー内容でググって出てきた対応策をいくつか試してみましたが解決しませんでした。
また、別で新規プロジェクトを作成してすぐにビルドを試しても同様のエラーが発生します。
というか1度もビルドできた試しがありません。
原因に心当たりがある方いらっしゃいませんか?

エラーメッセージ1

DirectoryNotFoundException: Could not find a part of the path "/Users/(自分の名前のため伏せてます)/Documents/ゲーム開発/My first Game/Packages/com.unity.nuget.newtonsoft-json/Runtime/AOT/Newtonsoft.Json.dll".
System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.Boolean anonymous, System.IO.FileOptions options) (at <695d1cc93cca45069c528c15c9fdd749>:0)
System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share) (at <695d1cc93cca45069c528c15c9fdd749>:0)
(wrapper remoting-invoke-with-check) System.IO.FileStream..ctor(string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare)
Mono.Cecil.ModuleDefinition.GetFileStream (System.String fileName, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share) (at <ebb9e4250ed24cbfa42055e3532ef311>:0)
Mono.Cecil.ModuleDefinition.ReadModule (System.String fileName, Mono.Cecil.ReaderParameters parameters) (at <ebb9e4250ed24cbfa42055e3532ef311>:0)
Mono.Cecil.ModuleDefinition.ReadModule (System.String fileName) (at <ebb9e4250ed24cbfa42055e3532ef311>:0)
Mono.Cecil.AssemblyDefinition.ReadAssembly (System.String fileName) (at <ebb9e4250ed24cbfa42055e3532ef311>:0)
UnityEditor.AssemblyHelper.GetAssemblyDefinitionCached (System.String path, System.Collections.Generic.Dictionary2[TKey,TValue] cache) (at /Users/bokken/buildslave/unity/build/Editor/Mono/AssemblyHelper.cs:74) UnityEditor.AssemblyHelper.FindAssemblyName (System.String fullName, System.String name, System.String[] allAssemblyPaths, System.String[] foldersToSearch, System.Collections.Generic.Dictionary2[TKey,TValue] cache) (at /Users/bokken/buildslave/unity/build/Editor/Mono/AssemblyHelper.cs:176)
UnityEditor.AssemblyHelper.AddReferencedAssembliesRecurse (System.String assemblyPath, System.Collections.Generic.List1[T] alreadyFoundAssemblies, System.String[] allAssemblyPaths, System.String[] foldersToSearch, System.Collections.Generic.Dictionary2[TKey,TValue] cache, UnityEditor.BuildTarget target) (at /Users/bokken/buildslave/unity/build/Editor/Mono/AssemblyHelper.cs:142)
UnityEditor.AssemblyHelper.FindAssembliesReferencedBy (System.String[] paths, System.String[] foldersToSearch, UnityEditor.BuildTarget target) (at /Users/bokken/buildslave/unity/build/Editor/Mono/AssemblyHelper.cs:198)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)

###エラーメッセージ2

Build completed with a result of 'Failed' in 5 seconds (5485 ms)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)

###エラーメッセージ3

UnityEditor.BuildPlayerWindow+BuildMethodException: 3 errors
at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002be] in /Users/bokken/buildslave/unity/build/Editor/Mono/BuildPlayerWindowBuildMethods.cs:190
at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in /Users/bokken/buildslave/unity/build/Editor/Mono/BuildPlayerWindowBuildMethods.cs:95
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&) (at /Users/bokken/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:189)

試したこと

unityの再インストール
unityのバージョンアップ

使用機材、環境

使用機材、環境
pc : mac
unityバージョン : 2020.3.14

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

ベストアンサー

「/Users/(自分の名前のため伏せてます)/Documents/ゲーム開発/My first Game」のように、日本語が含まれているパスにUnityのプロジェクトを入れてはいけません。

投稿2021/10/30 03:25

fiveHundred

総合スコア9805

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

marumarumaryu

2021/10/30 19:14

解決しました!ありがとうございます! 分かってしまえばこんな単純な理由だったのですね… 己の検索力の無さを痛感します… それと、すぐに回答して頂けて本当助かりました。 改めてありがとうございました。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問