Skip to content

Unity Things

JungSu Kim edited this page Jan 26, 2016 · 2 revisions

LifeCycle

Execution Order

Project folder structure

  • Assets
  • Dynamic Assets
  • Editor
  • Extensions
  • Fonts
  • Plugins
  • Resources
  • Prefabs
  • Scenes
  • Scripts
  • Common
  • Context InGame Main OutGame Crypto Library Log Model Service Agent Utils Shaders Standard Assets Tests Textures Data Documents ProjectSettings

Namespace

  • UnityEngine
  • UnityEditor
  • UnityEngine.UI
  • System
  • System.Collections
  • System.Collections.Generic
  • {ProjectName}
  • {ProjectName}/Scrits
  • {ProjectName}/Resources
  • {ProjectName}/External Resources
  • {ProjectName}/Stream Resources
  • {ProjectName}/Scenes

Asset Components

Reference : http://docs.unity3d.com/Manual/comp-AssetsGroup.html

  • Audio Clip
  • Cubemap Texture
  • Importing Models
  • Models
  • FBX Importer Rig Options
  • FBX Importer Animations Tab
  • Flare
  • Text Asset
  • Font
  • Meshes
  • Materials
  • Procedural Material Assets
  • RenderTextures
  • 2D Textures
  • Movie Textures

Object hierarchy Dont destory instance Singleton instance Hierarchy tree for state Hierarchy management

Handle new unity UI elements UI Canvas UI Rect Transform Anchors, Pivot, Rotation, Scale UI Button Transition(None, ColorTint, SpriteSwap, Animation) EventSystem Click trigger Make gameobject Add script public void functions Attach click event and function UI Image UI Text UI Events and Event Triggers UI Slider UI Transitions UI Scroll Rect UI Scrollbar UI Mask

Handle unity elements Layout Tags Input Manager Sprite Packer Sprite Editor AssetBundle NevMesh Collider with Trigger Particle Rigidbody2D, Collider2D ... Compare 3D or 2D elements Physics Materials Collider2D Circle, Box, Polygon, Edge Hinge Joint2D Spring Joint2D Distance Joint2D Resource load, unload, destory ... Single instance Monobehavior Gismo

Shader Official Built-in Shader(from Unity) Cg(C for graphics)

Physics NVIDIA PhyX

Architecture Inversion of Control frameworks for Unity StrangeIOC Zenject Lightweight IOC Inconspicuous.Framework Refactoring Architecture explorer VS2013 ultimate Crypto Base64 DES (CBC, TDES) SHA1, SHA256 MD5 Hash Data serialization Game data serialization/deserialization Need security protobuf-net

Managing Memory Types of memory application code managed heap native heap stack Memory leak detection Garbage collector Reference : http://docs.unity3d.com/Manual/MobileProfiling.html Out of memory crashes Two big scenes being loaded at the same time - use an empty scene between two bigger ones to fix this. Additive scene loading - remove unused parts to maintain the memory size. Huge asset bundles loaded to the memory. Textures without proper compression (a no go for mobiles). Textures having Get/Set pixels enabled. This requires an uncompressed copy of the texture in memory. Textures loaded from JPEG/PNGs at runtime are essentially uncompressed. Big mp3 files marked as decompress on loading. Keeping unused assets in weird caches like statics monobehavior fileds, which are not cleared when changing scenes. Stack / Heap Boxing / Unboxing Confirm IL ILSpy ILDASM Build settings .Net subset .Net Using Mono project Open source github Custom build

Performance Measure performance Function performance measure (optional DEBUG) Unity Profiler : http://docs.unity3d.com/Manual/Profiler.html Cache mechnism http://en.wikipedia.org/wiki/Cache_algorithms Least Recently Used (LRU) Pool Object pool Resource pool

Build & Deploy UnitTest Use Unity Test Tools Continues Integration build => test => reporting Auto deploy

Useful asset from AssetStore UnityVS Unity Test Tools "Unity UI":https://bitbucket.org/Unity-Technologies/ui CN Controls / TouchScript Create Script Dialog Code Architecture PSD Importer HyperViewes "RAIN AI":http://rivaltheory.com/ A* Pathfinding "StrangeIOC":http://strangeioc.github.io/strangeioc/ TexturePacker Importer UniRx Unity Remote Smart Localization LeanTween -iTween(iTween Visual Editor, iTween Path Editor)- -UIToolkit- -NI mate-

Managing Resources AssetBundle Load/Unload Prefabs

Managing Scene Performance Switching scene(Load, LoadAsync)

External tools Hyperviewer Unity TestSuite UnityVS UnityPsdImporter Texture Packer

Libraries Network Ligdren AI RAIN {Indie} FSM A* pathfinding UI iTween/HOTween/GOKit/LeanTween Tween Library Compare Popular Tween(GoKit, HOTween, iTween, LeanTween) Reference : http://dentedpixel.com/developer-diary/leantween-speed-comparison-to-itween/ Unity Project : TestingTweenEngines.zip Futile framework Control TouchControl(Double, Swipe, Touch ...) InputControl(Key, Device ...) Performance RXPerformance Object pool Prefactory Programming UniRx(Reactive programming for Unity) Linq

Analytics Google Analytics Flurry TestFilght

Ads Admob Facebook SDK Unity Ads SDK Everyplay

Externals Google Analytics Pmang Facebook Google+ Tweeter Kakao Google Play Game EveryPlay Parse.com SoundCloud Youtube Google API Google Maps Google Street View Unity Ads

Principle Physics Math 3D Position FSM A* Pathfinding 군집

Service Cloud service Interface with HTTP service Async request model Saving data client and server Sync data with interval

Clone this wiki locally