블로그 이미지
Every unexpected event is a path to learning for you. blueasa

카테고리

분류 전체보기 (2858)
Unity3D (897)
Programming (479)
Server (33)
Unreal (4)
Gamebryo (56)
Tip & Tech (192)
협업 (64)
3DS Max (3)
Game (12)
Utility (142)
Etc (99)
Link (34)
Portfolio (19)
Subject (90)
iOS,OSX (53)
Android (16)
Linux (5)
잉여 프로젝트 (2)
게임이야기 (3)
Memories (20)
Interest (38)
Thinking (38)
한글 (30)
PaperCraft (5)
Animation (408)
Wallpaper (2)
재테크 (19)
Exercise (3)
나만의 맛집 (3)
냥이 (10)
육아 (16)
Total
Today
Yesterday
Here is an advanced version, Just for fun. :p
Features
  • Multiple Define Symbols
  • Safety
  • Runs when Compile ends
  • Removes Duplicates
Installation
  1. Download the Script or Copy/Paste it from the Below
  2. Open Script
  3. Go to Symbols property and add your own symbols
  4. Go back to Unity and wait for compile ends
  5. All done, now check Player Settings, The symbols added
Code (CSharp):
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using UnityEngine;
  5. using UnityEditor;
  6.  
  7. /// <summary>
  8. /// Adds the given define symbols to PlayerSettings define symbols.
  9. /// Just add your own define symbols to the Symbols property at the below.
  10. /// </summary>
  11. [InitializeOnLoad]
  12. public class AddDefineSymbols : Editor
  13. {
  14.  
  15.     /// <summary>
  16.     /// Symbols that will be added to the editor
  17.     /// </summary>
  18.     public static readonly string [] Symbols = new string[] {
  19.         "MYCOMPANY",
  20.         "MYCOMPANY_MYPACKAGE"
  21.     };
  22.  
  23.     /// <summary>
  24.     /// Add define symbols as soon as Unity gets done compiling.
  25.     /// </summary>
  26.     static AddDefineSymbols ()
  27.     {
  28.         string definesString = PlayerSettings.GetScriptingDefineSymbolsForGroup ( EditorUserBuildSettings.selectedBuildTargetGroup );
  29.         List<string> allDefines = definesString.Split ( ';' ).ToList ();
  30.         allDefines.AddRange ( Symbols.Except ( allDefines ) );
  31.         PlayerSettings.SetScriptingDefineSymbolsForGroup (
  32.             string.Join ( ";", allDefines.ToArray () ) );
  33.     }
  34.  
  35. }
Thanks.




[출처] https://forum.unity.com/threads/scripting-define-symbols-access-in-code.174390/

반응형
Posted by blueasa
, |


[Link] https://github.com/zeyangl/UnityAppNameLocalizationForIOS


[참조] https://answers.unity.com/questions/789428/how-to-add-languages-automatically-when-you-export.html



반응형

'Unity3D > Plugins' 카테고리의 다른 글

[링크] Emoji_Extension  (0) 2018.06.07
[펌] Background Worker for Unity3D  (0) 2018.06.01
[에셋] Anti-Cheat Toolkit  (0) 2018.03.06
[펌] UnityIPhoneXSupport  (0) 2017.11.10
[Link] unity-webview  (0) 2017.10.23
Posted by blueasa
, |
반응형
Posted by blueasa
, |
반응형
Posted by blueasa
, |

You can check against UnityEngine.iOS.Device.generation

Note that you'll need Unity 2017.2 or higher to detect iPhone X. 

Unity 5.6.5f1 also seems to support the iPhoneX enum, even though it's not listed in the 5.6 docs. 

  1. bool deviceIsIphoneX = UnityEngine.iOS.Device.generation == UnityEngine.iOS.DeviceGeneration.iPhoneX;
  2. if (deviceIsIphoneX) {
  3. // Do something for iPhone X
  4. }


To check against iPad, you could probably go:

  1. bool deviceIsIpad = UnityEngine.iOS.Device.generation.ToString().Contains("iPad");
  2. if (deviceIsIpad) {
  3. // Do something for iPad
  4. }


[출처] https://answers.unity.com/questions/1432365/how-to-detect-iphone-x-or-ipad-using-iosdevicegene.html

반응형
Posted by blueasa
, |
반응형

'Unity3D > Plugins' 카테고리의 다른 글

[펌] Background Worker for Unity3D  (0) 2018.06.01
[Link] UnityAppNameLocalizationForIOS  (0) 2018.03.27
[펌] UnityIPhoneXSupport  (0) 2017.11.10
[Link] unity-webview  (0) 2017.10.23
[펌] E-Motion . . . Live 2D 와 비슷한 계열의 툴.  (0) 2017.04.28
Posted by blueasa
, |
반응형
Posted by blueasa
, |

http://ip2c.org/ 에 25$ 기부하고 사용하기로 결정.


c#에서는 아래와 같은 함수를 만들어서 간단히 이용 가능함.


public IEnumerator getGeoIP(){


if (DataManager.Inst.psd.systemOpt.nation.Length == 0) {

WWW www = new WWW ("http://ip2c.org/self");

while (!www.isDone) {

yield return new WaitForSeconds (0.1f);

}


if (www.text.Length > 1) {

string[] listnation = www.text.Split (';');

Debug.Log( listnation [2] );

}

}

}


각 국가의 국기 이미지 처리 방법 


http://www.gamedevforever.com/301



출처: http://ongamedev.tistory.com/entry/지역-코드-얻어오기 [가끔 보자, 하늘.]

반응형
Posted by blueasa
, |
반응형
Posted by blueasa
, |


IntPtr.Size returns 8 when the app is 64 bit and 4 when the app is 32 bit. – Programmer Oct 9 '16 at 5:12


[출처] https://stackoverflow.com/questions/39939785/how-to-know-unity-build-application-is-32bit-or-64bit

반응형
Posted by blueasa
, |