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
#include "DirectWriteCustomFont.h" | |
void DirectWriteSample() | |
{ | |
// フォントデータ | |
FontData data; | |
// DirectWrite描画クラス | |
DirectWriteCustomFont* Write; |
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.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using UnityEngine.InputSystem; | |
using UnityEngine.UI; | |
public class WarningWindow : MonoBehaviour | |
{ | |
//============================================================================= | |
// 列挙型 |
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.Collections; | |
using UnityEngine; | |
using UnityEngine.InputSystem; | |
public class ErrorWindow : MonoBehaviour | |
{ | |
//============================================================================= | |
// 変数 | |
//============================================================================= | |
// ウィンドウの本来のポジション |
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
#include "main.h" // main | |
#include "renderer.h" // Renderer | |
#include "DirectWrite.h" | |
//================================================================================================================================= | |
// 第1引数:フォント名(L"メイリオ", L"Arial", L"Meiryo UI"等) | |
// 第2引数:フォントコレクション(nullptr) | |
// 第3引数:フォントの太さ(DWRITE_FONT_WEIGHT_NORMAL, DWRITE_FONT_WEIGHT_BOLD等) | |
// 第4引数:フォントスタイル(DWRITE_FONT_STYLE_NORMAL, DWRITE_FONT_STYLE_OBLIQUE, DWRITE_FONT_STYLE_ITALIC) | |
// 第5引数:フォントの幅(DWRITE_FONT_STRETCH_NORMAL,DWRITE_FONT_STRETCH_EXTRA_EXPANDED等) |
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
#pragma once | |
//============================================================================= | |
// フォントリスト | |
//============================================================================= | |
enum class Font | |
{ | |
Meiryo, | |
Arial, | |
MeiryoUI | |
}; |
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.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class DirectionMark : MonoBehaviour | |
{ | |
//============================================================================= | |
// 変数 | |
//============================================================================= | |
// プレイヤーの情報 |
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.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
public class DirectionMark : MonoBehaviour | |
{ | |
//============================================================================= | |
// 変数 | |
//============================================================================= | |
// プレイヤーの情報 |
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> | |
/// SE再生 | |
/// </summary> | |
/// <param name="seType"> 曲名 </param> | |
/// <param name="loop"> ループの有無 </param> | |
/// <param name="PlayVolume"> 再生時のボリューム </param> | |
/// <param name="Singleton"> 同じ曲は再生しない </param> | |
public void PlaySE(string seType, bool loop = false, float PlayVolume = -1, bool Singleton = false) | |
{ | |
// ミュートでは無い場合 |
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.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using UnityEngine.Audio; | |
[System.Serializable] | |
public class AudioData | |
{ | |
// 名前(インスペクターからの登録) | |
public string name = ""; |
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.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using System; | |
public abstract class SingletonMonoBehaviour<T> : MonoBehaviour where T : MonoBehaviour | |
{ | |
// 継承先で「破棄はできないか?」を指定 | |
protected bool dontDestroyOnLoad = true; |