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

카테고리

분류 전체보기 (2738)
Unity3D (817)
Script (91)
Extensions (14)
Effect (3)
NGUI (77)
UGUI (8)
Physics (2)
Shader (36)
Math (1)
Design Pattern (2)
Xml (1)
Tips (200)
Link (22)
World (1)
AssetBundle (25)
Mecanim (2)
Plugins (70)
Trouble Shooting (68)
Encrypt (7)
LightMap (4)
Shadow (4)
Editor (8)
Crash Report (3)
Utility (9)
UnityVS (2)
Facebook SDK (2)
iTween (3)
Font (11)
Ad (14)
Photon (2)
IAP (1)
Google (8)
Android (45)
iOS (41)
Programming (475)
Server (33)
Unreal (4)
Gamebryo (56)
Tip & Tech (228)
협업 (58)
3DS Max (3)
Game (12)
Utility (136)
Etc (96)
Link (32)
Portfolio (19)
Subject (90)
iOS,OSX (53)
Android (14)
Linux (5)
잉여 프로젝트 (2)
게임이야기 (3)
Memories (20)
Interest (38)
Thinking (38)
한글 (30)
PaperCraft (5)
Animation (408)
Wallpaper (2)
재테크 (18)
Exercise (3)
나만의 맛집 (3)
냥이 (10)
육아 (16)
Total
Today
Yesterday
05-03 00:02

문서들을 여기 저기 따로 공유하려느 번거로워서 유니티 최적화 관련 문서들을 모아두었습니다. 정리는 두서 없이 했고,다만 출처가 유니티 크루인지 아닌지로만 분류하였습니다. 추가적으로 발견하는 대로 지속적으로 갱신 할 예정입니다.


From Unity


from Developers


출처 : http://ozlael.tistory.com/32

반응형
Posted by blueasa
, |

Android Manifest File

Unity3D/Tips / 2015. 8. 25. 15:37


링크1 : http://android007.tistory.com/8

링크2 : http://hyeonstorage.tistory.com/151

반응형
Posted by blueasa
, |

Command line arguments

Unity 편집기를 그것이 연 상태로 특정 태스크를 실행하도록 만들기 위해서 커맨드 라인 아규먼트와 함께 시작하는 것이 가능합니다. 이것은 자동적인 게임 빌드, 테스트 스윗 등등을 허용합니다. below를 살펴보시기 바랍니다.

게다가 Unity와 함께 구축되어 있는 혼자하는 게임은 어떤 커맨드 라인 파라미터를 허용합니다. below를 살펴보시기 바랍니다.

editor

Unity Editor command line arguments

-batchmode

Unity를 batch 모드에서 실행합니다. 이것은 항상 그것이 어떠한 팝업 윈도우도 나타나지 않도록 함에 따라 그리고 어떠한 사람의 개입의 필요를 제거함에 따라 다른 커맨드 라인 아규먼트와 함께 결합되어 사용되야 합니다. 스크립트 코드의 실행 동안에 하나의 예외가 발생할 때 에셋 서버 업데이트는 실패하거나 또는 다른 오퍼레이션 들도 실패하고 Unity는 즉시 1을 리턴 코드로 하고 종료합니다.

Batch 모드에서 Unity는 그것의 로그가 콘솔로 나가는 버전을 쓸 것입니다. 완전한 디버그 정보를 위해서 Unity의 Log Files를 보시기 바랍니다.

-quit

다른 커맨드 라인 아규먼트의 실행을 끝내면서 Unity를 깨끗하게 멈춥니다.

-buildWindowsPlayer

혼자서하는 윈도우즈 플레이어를 구축합니다 (예 -buildWindowsPlayer path/to/your/build.exe).

-buildOSXPlayer

혼자서하는 윈도우즈 플레이어를 구축합니다 (eg, -buildOSXPlayer path/to/your/build.app).

-importPackage //packagepath//

주어진 package를 불러옵니다. 어떠한import 다이아로그도 보여지지 않습니다.

-createProject //pathname//

주어진 경로에 빈 프로젝트를 생성합니다.

-projectPath //pathname//

주어진 경로에 프로젝트를 오픈 합니다.

-assetServerUpdate //IP[:port] projectName username password [r <revision>]//

IP:port에 의해 주어진 Asset Server 에서 프로젝트의 업데이트를 강요합니다. 포트는 선택적이로 주어지지 않았다면 그것은 스탠다드 원(10733)이 되도록 가저됩니다. 사용자가 옳은 프로젝트와 작업하고 있다는 것을 확신시키기 위해서 -projectPath 아규먼트와 함께 결합된 이 명령을 사용하는 것은 충고될 수 있습니다. 프로젝트 이름이 주어지지 않으면 Unity에서 열어진 마지막 프로젝트가 사용됩니다. -projectPath에 의해 주어진 경로에서 프로젝트가 존재하지 않으면 하나가 자동적으로 생성됩니다.

-executeMethod //ClassName.MethodName//

Unity가 시작되자마자static method를 실행하고 선택적인 에셋 서버 업데이트가 실행된 후에 프로젝트 폴더는 열려집니다. 이것은 계속적인 통합을 하기 위해 사용될 수 있습니다 : Unit 테스트, 빌드 만들기, 데이터 준비하기. 사용자가 커맨드 라인 프로세스로부터 에러를 리턴하고 싶다면 사용자는 Unity가 1과 함께 종료하도록 하는 예외를 던지거나 또는 0이 아닌 코드와 함께EditorApplication.Exit를 콜합니다.

-executeMethod를 사용하기 위해서 _사용자는 편집기 폴더의 스크립트와 클래스의 static 함수를 가질 필요가 있습니다_.

// C# example
using UnityEditor;
class MyEditorScript
{
     static void PerformBuild ()
     {
         string[] scenes = { "Assets/MyScene.unity" };
         BuildPipeline.BuildPlayer(scenes, ...);
     }
}
// JavaScript example
static void PerformBuild ()
{
    string[] scenes = { "Assets/MyScene.unity" };
    BuildPipeline.BuildPlayer(scenes, ...);
}

-exportPackage

주어진 경로에서 하나의 패키지를 export 합니다. _ 사용법:_ -exportPackage exportAssetPath exportFileName
_Where:_ _exportAssetPath:_ unity 프로젝트에서 export하는 폴더입니다 
_exportFileName:_ 패키지 이름입니다 

현재 그것은 전체 폴더만을 export하는 것을 지원합니다.

-nographics //(Windows only)//

Batch 모드에서 실행할 때 그래픽 디바이스를 초기화하지 않아야 합니다. 이것은 GPU를 가지지 않는 기계 위에서 사용자의 자동 워크플로우를 실행하도록 하는 것을 가능하게 합니다.

Example usage

Back 모드에서 Unity를 실행합니다. MyEditorScript.MyMethod 메서드를 실행하고 완료시 종료합니다.

_Windows:_
C:\program files\Unity\Editor>Unity.exe -quit -batchmode -executeMethod MyEditorScript.MyMethod

_Mac OS:_
/Applications/Unity/Unity.app/Contents/MacOS/Unity -quit -batchmode -executeMethod MyEditorScript.MyMethod

Batch 모드에서 Unity를 실행합니다. 주어진 프로젝트 경로를 사용하고 에셋 서버로부터 업데이트 합니다. 모든 에셋이 다운로드 되어지고 에셋 서버로부터 불려진 후에 주어진 메서드를 실행합니다. 메서드가 실행을 마치면 자동적으로 Unity를 종료합니다.

/Applications/Unity/Unity.app/Contents/MacOS/Unity -batchmode -projectPath ~/UnityProjects/AutobuildProject -assetServerUpdate 192.168.1.1 MyGame AutobuildUser l33tpa33 -executeMethod MyEditorScript.PerformBuild -quit

player

Unity Standalone Player command line arguments

Unity와 함께 구축된 혼자서하는 플레이어는 커맨드 라인 아규먼트를 이해합니다:

-batchmode

게임을 "headless" 모드로 실행합니다. 게임은 어떤 것도 보여주지 않을 것이면 사용자 입력을 허용하지 않을 것입니다. 이것은networked games의 실행하는 서버를 위해서 대부분 유용합니다.

-force-opengl //(Windows only)//

심지어Direct3D가 가능할 때도 게임이 렌더링을 위해서OpenGL을 사용하도록 만듭니다. 보통Direct3D이 사용됩니다; 그리고Direct3D 9.0c이 가능하지 않는 경우에만OpenGL이 사용됩니다.

-single-instance //(Windows only)//

게임의 한 인스턴스가 한 번에 실행되도록 합니다. 또다른 게임이 벌써 실행되고 있다면 그것을 -single-instance와 함께 다시 시작하는 것은 기존에 존재하고 있는 것에 포커스를 둘 것입니다.

-nolog //(Windows only)//

Output 로그를 생성하지 않습니다. 주로 output_log.txt는 실행될 수 있는 게임 옆에 *_Data 폴더에 씌여집니다. 거기서Debug.Log 결과는 프린트 됩니다.

-force-d3d9-ref //(Windows only)//

Direct3D의 "Reference" 소프트웨어 렌더러를 사용해서 게임을 실행하도록 만듭니다. DirectX SDK는 이것이 작동하도록 하기 위해서 설치될 필요가 있습니다. 이것은 자동 테스트 스윗을 만들기 위해 매우 유용합니다. 거기서 사용자는 렌더링이 무슨 그래픽 카드이냐에 상관없이 정확하게 같은 것을 하는 것을 확실시하고 싶어합니다.

-adapterN //(Windows only)//

게임이 또다른 디스플레이에서 전체 스크린으로 실행되도록 허용합니다. 거기서 N은 디스플레이 숫자를 의미합니다.

-popupwindow //(Windows only)//

윈도우는 팝업 윈도우로서 생성될 것입니다 (프레임 없이).



출처 : http://openwiki.kr/unity/commandlinearguments

반응형
Posted by blueasa
, |

안드로이드에서 사운드 지연 문제 이슈와 해결 방법으로 올라와 있어서 링크 해 놓음..



참조1 : http://www.gamecodi.com/board/zboard.php?id=GAMECODI_Talkdev&page=1&sn1=&divpage=1&sn=off&ss=on&sc=on&select_arrange=headnum&desc=asc&no=3294


참조2 : http://tsubakit1.hateblo.jp/entry/2015/05/19/011835




If you're developing mobile games for Android, you've probably noticed ridiculous sound delay on some devices. 
No more. With this plugin, your sounds will play almost immediately. Check out this demo video:


Features:

- Play in-game sounds without any delay on Android devices
- Simultaneous playback of several sounds
- All kinds of Android built-in audio file formats are supported
- Plugin uses Android Sound Pool for managing and using sound files
- Doesn't conflict with Unity sound system

It works by issuing direct calls to the Android OS, bypassing everything that Unity has in its audio system. It means that sounds won't be affected by distance, Doppler, project volume settings etc, which is perfectly acceptable for most of the Android games. In our game, music is played by Unity and short sounds are managed by this plugin, with no issues. 

Usage is simple: 
- Send filename of sound and get its ID's with AudioCenter.loadSound(path_to_file) method
- Play it with AudioCenter.playSound(sound_id) method
- Unload it with AudioCenter.unloadSound(sound_id) method to save memory
For more detailed instructions, refer to the .pdf, supplied with the plugin.

Download it directly from our website: http://catsknead.me/static/plugin.zip

In the archive you'll find .unitypackage, .pdf with detailed instructions, .java file, containing full source of the Android-side of the plugin and a test scene, in which you can compare two playback methods. 
If you see no sound delay in the provided example scene - you probably have a lucky device, try another one :)

Coming to the Asset Store soon.



출처 : http://forum.unity3d.com/threads/android-sound-latency-fix.319943/

반응형

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

Android Manifest File  (0) 2015.08.25
Unity Editor command line arguments  (0) 2015.08.12
iOS Native 관련..  (0) 2015.05.12
Scene뷰에서 Handles.Label()  (0) 2015.05.08
[링크] 유니티5 업그레이드 가이드  (0) 2015.03.30
Posted by blueasa
, |

iOS Native 관련..

Unity3D/Tips / 2015. 5. 12. 01:52

[링크]

http://www.gamecodi.com/board/zboard.php?id=GAMECODI_Talkdev&page=1&sn1=&divpage=1&sn=off&ss=on&sc=on&select_arrange=headnum&desc=asc&no=3280

반응형
Posted by blueasa
, |

Unity编辑器类在Scene下显示Lable文字




[csharp] view plaincopy
  1. 在Editor文件夹中创建代码如下  
  2.   
  3. using UnityEngine;  
  4. using System.Collections;  
  5. using UnityEditor;  
  6.   
  7.   
  8. [CustomEditor(typeof(Arraw))]  
  9. public class HandlerTest : Editor {  
  10.   
  11.     Vector3[] positions;  
  12.   
  13.     void OnSceneGUI()  
  14.     {  
  15.         float width = HandleUtility.GetHandleSize(Vector3.zero) * 0.5f;  
  16.         Arraw arraw = (Arraw)target;  
  17.   
  18.         Handles.Label( arraw.transform.position + Vector3.up * 1.5f, arraw.transform.position.ToString()+ "\nAAAA");   //绘制文字, 参数1 为坐标,参数2 为要显示的文字  
  19.    
  20.         if (GUI.changed)  
  21.         {  
  22.              EditorUtility.SetDirty(arraw);  
  23.         }  
  24.   
  25.     }  
  26. }  
  27.   
  28.   
  29.   
  30. Arraw脚本如下,将其拖拽到需要绘制Label的对象上即可  
  31. using UnityEngine;  
  32. using System.Collections;  
  33.   
  34. public class Arraw : MonoBehaviour {  
  35.   
  36.     public float shieldArea = 5;  
  37.   
  38. }  


출처 : http://blog.csdn.net/liqiangeastsun/article/details/42175199

반응형
Posted by blueasa
, |


링크 : http://jinhomang.tistory.com/category/Unity/Unity%205

반응형
Posted by blueasa
, |

Link : http://forum.unity3d.com/threads/unity-4-5-new-hierarchy-window-sorting.248298/#post-1642742


[File]


$AlphaNumericSort.cs





기존의 이름이 아닌 트랜스폼 기준으로 변경되었는데요.


(전 처음에 4.5 버전 버그인줄 알고 당황-_-;)



링크의 글 중간에 보시면

$AlphaNumericsort.cs

파일을 다운 받으시고

프로젝트 폴더/Assets/Editor/ 

에 넣어주세요.

유니티를 다시 띄우면 그림처럼 아이콘이 하나가 추가됩니다.

이 아이콘을 누르시면 소팅 방식을 트랜스폼 혹은 이름으로 변경 가능해집니다.




출처 : http://www.gamecodi.com/board/zboard.php?id=GAMECODI_Talkdev&page=1&sn1=&divpage=1&sn=on&ss=on&sc=on&keyword=sort&select_arrange=headnum&desc=asc&no=2703

반응형

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

Scene뷰에서 Handles.Label()  (0) 2015.05.08
[링크] 유니티5 업그레이드 가이드  (0) 2015.03.30
BBCode tags reference  (0) 2015.02.08
안드로이드 유니티 리모트 4 연동 문제 해결하기  (0) 2015.02.04
Unity Platform Defines  (0) 2015.01.28
Posted by blueasa
, |

BBCode tags reference

Unity3D/Tips / 2015. 2. 8. 17:47

BBCode tags reference

In this section, a reference table for all of the more popular bbcode tags, is provided. Some are considered to be standard and should be supported in just about any bbcode implementation. Other are less likely to be supported, but nonetheless popular (hence the reason they've been included here).

Tags reference table

NameSyntaxPurposeExample
Bold[b]{text}[/b]Makes {text} boldBold example
Italic[i]{text}[/i]Makes {text} italicItalic example
Underline[u]{text}[/u]Underlines {text}Underline example
Line-through[s]{text}[/s]Create a line-through/strike through on {text}Line-through example
Font-size[size={number}]{text}[/size]Changes the font-size of {text}Font-size example
Font colour[color={colour}]{text}[/color]Changes the colour of {text}Font colour example
Center text[center]{text}[/center]Centers {text} on screenCenter text example
Quote[quote]{text}[/quote]Creates a quotation box containing {text}Quote example
Quote (named)[quote={name}]{text}[/quote]Creates a quotation box quoting {name} as saying {text}Quote (named) example
Link[url]{url}[/url]Makes a link to {url}Link example
Link (named)[url={url}]{text}[/url]Makes a named link to {url}Link (named) example
Image[img]{url}[/img]Shows the image indicated by {url}Image example
Image (resized)Full version: [img width={width} height={height} ...]{url}[/img]
Another variant (shorthand): [img={width}x{height}]{url}[/img]
Shows {url} image resized to {width} and {height}Image (resized) example
ListUnordered list: [ul]{items}[/ul]
Ordered list: [ol]{items}[/ol]
Another variant: [list]{items}[/list]
Displays a list of {items}List example
List item[li]{text}[/li]
Shorthand: [*]{text}\newline
Species an {item} within a listList item example
Code[code]{text}[/code]Renders the {text} while maintaing all white spacingCode example
Tables[table]{rows}[/table]Show a table with {rows} in itTables example
Table rows[tr]{cells}[/tr]Renders a table row containing {cells}Table rows example
Table content cellsHeading cell: [th]{content}[/th]
Content cell: [td]{content}[/td]
Shows {content} in a table (heading) cellTable content cells example
Youtube videos[youtube]{id}[/youtube]Shows the youtube video indicated by {id}Youtube videos example
Google videos[gvideo]{id}[/gvideo]Shows the google video indicated by {id}Google videos example

Something missing?

If you think that some tags are missing here, please do not hesitate to contact us!

BBCode examples

Go to the examples section to find many examples of how you can use these tags.





출처 : http://www.bbcode.org/reference.php

반응형
Posted by blueasa
, |

안드로이드 유니티 리모트 4 연동 문제 해결하기

안드로이드에서 유니티 리모트를 연동하기 법은 구글형이 잘 알려준다. 여기서는 자주 발생하는 문제에 대한 해결책을 정리한다.
  1. 폰이 인식되지 않는다
  2. 인증되지 않았다
  3. 유니티에서 Play를 해도 반응이 없다

폰이 인식되지 않는다

일단 USB를 꽂으면, 인식이 되고, 탐색기로 봤을 때, 폰이 보이고, 폴더에 접근하여 파일을 복사하거나 삭제할 수 있어야 한다.

확인방법

  1. 탐색기에서 보이는지 확인
  2. adb로 확인
  3. 폰의 개발자 모드에서 USB 디버깅 활성화 체크

해결방법

  1. USB 통합 드라이브를 설치한다. (구글형에게 문의)
  2. 콘솔명령창에서 adb devices를 실행한다.
  3. 폰 설정에 들어가서 USB 디버깅을 활성화 한다. (구글형에게 문의)

폰이 인증되지 않았다

폰이 인식되면, USB 디버깅을 활성화하면, 유니티에서 Play를 할 때, 개발 컴퓨터의 접속을 허가할 지, 폰에서 묻는다. 이 때, 잘 응답하면 문제가 없으나, 잘못하면 인증이 안된 상태가 된다.

확인방법

  1. adb devices를 했을 때, 폰은 나오나 Unauthorized라고 나온다.

해결방법

콘솔 창에서 다음 명령을 실행한다
  1. adb kill-server
  2. adb start-server
위의 명령을 하고 다시 유니티에서 Play를 하면 폰에서 인증창이 다시 나온다.

유니티에서 Play를 해도 반응이 없다

유니티가 실행된 후에 폰을 연결한 경우, 유니티가 인식을 못하는 경우가 있다

확인방법

  1. 위의 문제의 확인 방법을 통해서 문제가 없는데도 Play를 하면 안된다

해결방법

  1. 유니티 에디터를 재실행한다


출처 : http://junhan627.blogspot.kr/2014/11/4.html

반응형
Posted by blueasa
, |