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
//バックアップ対象から外す | |
- (NSString *)myDocumentsPath | |
{ | |
NSString *documentsPath = [NSHomeDirectory() stringByAppendingPathComponent:@"Library/Preferences"]; | |
return documentsPath; | |
} | |
- (BOOL)addSkipBackupAttributeToItemAtURL:(NSURL *)URL | |
{ | |
assert([[NSFileManager defaultManager] fileExistsAtPath: [URL path]]); |
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
using System; | |
using System.IO; | |
using System.Text; | |
using UnityEditor; | |
using UnityEditorInternal; | |
using UnityEngine; | |
/// <summary> | |
/// オーディオのファイル名を定数で管理するクラスを作成するスクリプト | |
/// </summary> |
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
using UnityEngine; | |
using System.Collections; | |
using System.Collections.Generic; | |
/// <summary> | |
/// BGMとSEの管理をするマネージャ。シングルトン。 | |
/// </summary> | |
public class AudioManager : SingletonMonoBehaviour<AudioManager> | |
{ | |
//ボリューム保存用のkeyとデフォルト値 |
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
using UnityEngine; | |
using System.Collections; | |
using System.Collections.Generic; | |
/// <summary> | |
/// BGMとSEの管理をするマネージャ。シングルトン。 | |
/// </summary> | |
public class AudioManager : SingletonMonoBehaviour<AudioManager> | |
{ | |
//オーディオファイルのパス |
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
/// <summary> | |
/// 入力されたオブジェクト及びその子、全ての色を変える | |
/// </summary> | |
/// <param name="targetObject">色を変更したいオブジェクト</param> | |
/// <param name="color">設定したい色</param> | |
private void ChangeColorOfGameObject(GameObject targetObject, Color color){ | |
//入力されたオブジェクトのRendererを全て取得し、さらにそのRendererに設定されている全Materialの色を変える | |
foreach(Renderer targetRenderer in targetObject.GetComponents<Renderer>()){ | |
foreach(Material material in targetRenderer.materials){ |
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
using UnityEngine; | |
using System.Collections; | |
public class LoadManager : MonoBehaviour { | |
//================================================================================= | |
//初期化 | |
//================================================================================= | |
private void Awake(){ |
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
using UnityEngine; | |
using System.Collections; | |
public class SetMonsterStatus : MonoBehaviour { | |
//モンスターの種類 | |
public enum MonsterType{ | |
Warrior, Witch, Dragon | |
} | |
public MonsterType Type; |
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
using UnityEngine; | |
using System.Collections; | |
using UnityEditor; | |
[CustomEditor (typeof(SetMonsterStatus))] | |
public class SetMonsterStatusEditor : Editor | |
{ | |
public override void OnInspectorGUI() { | |
SetMonsterStatus monster = target as SetMonsterStatus; |
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
using UnityEngine; | |
using System.Collections; | |
using System.Collections.Generic; | |
public class MonsterData : ScriptableObject | |
{ | |
public List<Param> list = new List<Param> (); | |
[System.SerializableAttribute] | |
public class Param |