-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from MidraLab/develop
v0.0.3
- Loading branch information
Showing
33 changed files
with
397 additions
and
258 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ jobs: | |
id: getManualLicenseFile | ||
uses: game-ci/unity-request-activation-file@v2 | ||
with: | ||
unityVersion: 2022.2.5f1 | ||
unityVersion: 2022.2.15f1 | ||
# Upload artifact (Unity_v20XX.X.XXXX.alf) | ||
- name: Expose as artifact | ||
uses: actions/[email protected] | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,7 @@ on: | |
pull_request: | ||
branches: | ||
- main | ||
- develop | ||
|
||
jobs: | ||
meta-check: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Empty file.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Empty file.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
%YAML 1.1 | ||
%TAG !u! tag:unity3d.com,2011: | ||
--- !u!1 &7114562640169053628 | ||
GameObject: | ||
m_ObjectHideFlags: 0 | ||
m_CorrespondingSourceObject: {fileID: 0} | ||
m_PrefabInstance: {fileID: 0} | ||
m_PrefabAsset: {fileID: 0} | ||
serializedVersion: 6 | ||
m_Component: | ||
- component: {fileID: 997822693772618305} | ||
- component: {fileID: 2866147896293219298} | ||
- component: {fileID: 45360905756024039} | ||
- component: {fileID: 1689601321579300571} | ||
m_Layer: 5 | ||
m_Name: Background | ||
m_TagString: Untagged | ||
m_Icon: {fileID: 0} | ||
m_NavMeshLayer: 0 | ||
m_StaticEditorFlags: 0 | ||
m_IsActive: 1 | ||
--- !u!224 &997822693772618305 | ||
RectTransform: | ||
m_ObjectHideFlags: 0 | ||
m_CorrespondingSourceObject: {fileID: 0} | ||
m_PrefabInstance: {fileID: 0} | ||
m_PrefabAsset: {fileID: 0} | ||
m_GameObject: {fileID: 7114562640169053628} | ||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} | ||
m_LocalPosition: {x: 0, y: 0, z: 0} | ||
m_LocalScale: {x: 1, y: 1, z: 1} | ||
m_ConstrainProportionsScale: 1 | ||
m_Children: [] | ||
m_Father: {fileID: 0} | ||
m_RootOrder: -1 | ||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} | ||
m_AnchorMin: {x: 0, y: 0} | ||
m_AnchorMax: {x: 1, y: 1} | ||
m_AnchoredPosition: {x: 0, y: 0} | ||
m_SizeDelta: {x: 0, y: 0} | ||
m_Pivot: {x: 0.5, y: 0.5} | ||
--- !u!222 &2866147896293219298 | ||
CanvasRenderer: | ||
m_ObjectHideFlags: 0 | ||
m_CorrespondingSourceObject: {fileID: 0} | ||
m_PrefabInstance: {fileID: 0} | ||
m_PrefabAsset: {fileID: 0} | ||
m_GameObject: {fileID: 7114562640169053628} | ||
m_CullTransparentMesh: 1 | ||
--- !u!114 &45360905756024039 | ||
MonoBehaviour: | ||
m_ObjectHideFlags: 0 | ||
m_CorrespondingSourceObject: {fileID: 0} | ||
m_PrefabInstance: {fileID: 0} | ||
m_PrefabAsset: {fileID: 0} | ||
m_GameObject: {fileID: 7114562640169053628} | ||
m_Enabled: 1 | ||
m_EditorHideFlags: 0 | ||
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} | ||
m_Name: | ||
m_EditorClassIdentifier: | ||
m_Material: {fileID: 0} | ||
m_Color: {r: 1, g: 1, b: 1, a: 1} | ||
m_RaycastTarget: 1 | ||
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} | ||
m_Maskable: 1 | ||
m_OnCullStateChanged: | ||
m_PersistentCalls: | ||
m_Calls: [] | ||
m_Sprite: {fileID: 0} | ||
m_Type: 0 | ||
m_PreserveAspect: 0 | ||
m_FillCenter: 1 | ||
m_FillMethod: 4 | ||
m_FillAmount: 1 | ||
m_FillClockwise: 1 | ||
m_FillOrigin: 0 | ||
m_UseSpriteMesh: 0 | ||
m_PixelsPerUnitMultiplier: 1 | ||
--- !u!114 &1689601321579300571 | ||
MonoBehaviour: | ||
m_ObjectHideFlags: 0 | ||
m_CorrespondingSourceObject: {fileID: 0} | ||
m_PrefabInstance: {fileID: 0} | ||
m_PrefabAsset: {fileID: 0} | ||
m_GameObject: {fileID: 7114562640169053628} | ||
m_Enabled: 1 | ||
m_EditorHideFlags: 0 | ||
m_Script: {fileID: 11500000, guid: a1f4d01e48c9499f80ebc24e695fa593, type: 3} | ||
m_Name: | ||
m_EditorClassIdentifier: | ||
backgroundSprites: [] |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
3 changes: 0 additions & 3 deletions
3
Assets/EasyADV/Scripts/DataModel/CharacterVoiceSetting.cs.meta
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,125 @@ | ||
using System.IO; | ||
using EasyADV.FungusExtension; | ||
using EasyADV.Scripts; | ||
using Fungus; | ||
using UnityEditor; | ||
using UnityEngine; | ||
|
||
namespace EasyADV.Editor | ||
{ | ||
/// <summary> | ||
/// EasyADVのメニューを追加するクラス | ||
/// </summary> | ||
public class EasyADVMenu | ||
{ | ||
/// <summary> | ||
/// 背景画像のフォルダ名 | ||
/// </summary> | ||
private const string BackgroundImageFolderName = "BackgroundImage"; | ||
|
||
/// <summary> | ||
/// キャラクター画像のフォルダ名 | ||
/// </summary> | ||
private const string CharacterImageFolderName = "CharacterImage"; | ||
|
||
/// <summary> | ||
/// サウンドのフォルダ名 | ||
/// </summary> | ||
private const string SoundFolderName = "Sound"; | ||
|
||
[MenuItem("Tools/EasyADV/Setup")] | ||
private static void Setup() | ||
{ | ||
SetupHierarchyObject(); | ||
SetupMaterialFolder(); | ||
} | ||
|
||
/// <summary> | ||
/// 素材フォルダを作成する | ||
/// </summary> | ||
private static void SetupMaterialFolder() | ||
{ | ||
var folderRoot = Application.dataPath + "/EasyADV/"; | ||
|
||
// 背景画像フォルダがなければ作成 | ||
if (!Directory.Exists(folderRoot + BackgroundImageFolderName)) | ||
{ | ||
Directory.CreateDirectory(folderRoot + BackgroundImageFolderName); | ||
CreateGitKeep(Path.Combine(folderRoot, BackgroundImageFolderName)); | ||
} | ||
|
||
// キャラクター画像フォルダがなければ作成 | ||
if (!Directory.Exists(folderRoot + CharacterImageFolderName)) | ||
{ | ||
Directory.CreateDirectory(folderRoot + CharacterImageFolderName); | ||
CreateGitKeep(Path.Combine(folderRoot, CharacterImageFolderName)); | ||
} | ||
|
||
// サウンドフォルダがなければ作成 | ||
if (!Directory.Exists(folderRoot + SoundFolderName)) | ||
{ | ||
Directory.CreateDirectory(folderRoot + SoundFolderName); | ||
CreateGitKeep(Path.Combine(folderRoot, SoundFolderName)); | ||
} | ||
|
||
AssetDatabase.Refresh(); | ||
} | ||
|
||
/// <summary> | ||
/// Fungus・EasyADVを使用するためのオブジェクトを作成する | ||
/// </summary> | ||
private static void SetupHierarchyObject() | ||
{ | ||
if (Object.FindObjectOfType<Flowchart>() == null) | ||
{ | ||
Fungus.EditorUtils.FlowchartMenuItems.CreateFlowchart(); | ||
} | ||
|
||
if(Object.FindObjectOfType<Stage>() == null) | ||
{ | ||
Fungus.EditorUtils.NarrativeMenuItems.CreateStage(); | ||
} | ||
|
||
if (Object.FindObjectOfType<SayDialog>() == null) | ||
{ | ||
Fungus.EditorUtils.NarrativeMenuItems.CreateSayDialog(); | ||
} | ||
|
||
// FlowchartにUpdateScenarioFromGoogleSheetコンポーネントが追加されていなければ追加 | ||
var flowchart = Object.FindObjectOfType<Flowchart>(); | ||
if (flowchart == null || flowchart.GetComponent<UpdateScenarioFromGoogleSheet>() != null) | ||
{ | ||
return; | ||
} | ||
|
||
flowchart.gameObject.AddComponent<UpdateScenarioFromGoogleSheet>(); | ||
|
||
// ステージ内に背景画 切り替え用のオブジェクトとコンポーネントの追加 | ||
var stageCanvas = Object.FindObjectOfType<Stage>().GetComponentInChildren<Canvas>(); | ||
if (stageCanvas.GetComponentInChildren<SetBackgroundImage>() != null) | ||
{ | ||
return; | ||
} | ||
|
||
var backgroundPrefab = | ||
AssetDatabase.LoadAssetAtPath<SetBackgroundImage>("Assets/EasyADV/Prefabs/Background.prefab"); | ||
var backgroundObject = Object.Instantiate(backgroundPrefab, stageCanvas.transform); | ||
backgroundObject.name = "Background"; | ||
} | ||
|
||
/// <summary> | ||
/// Gitの管理下に置くためのファイルを作成する | ||
/// </summary> | ||
/// <param name="path"></param> | ||
private static void CreateGitKeep(string path) | ||
{ | ||
var gitKeepPath = path + "/.gitkeep"; | ||
if (File.Exists(gitKeepPath)) | ||
{ | ||
return; | ||
} | ||
|
||
File.Create(gitKeepPath); | ||
} | ||
} | ||
} |
Oops, something went wrong.