Upgrade to Pro — share decks privately, control downloads, hide ads and more …

はじめてのUnity入門

unitydojo
February 21, 2017

 はじめてのUnity入門

2017年2月20日に21Cafeで行われた「はじめてのUnity 入門」に使用したスライドです。
Unityでゲームを作る上での考え方や、簡単なエディター操作方法、学習のコツについてが含まれます。

unitydojo

February 21, 2017
Tweet

More Decks by unitydojo

Other Decks in Technology

Transcript

  1. IUUQTHPPHM(*3/5
    ➙㔐⢪ֲفٗآؙؑز
    IUUQTHJUIVCDPNUTVCBLJVOJUZ@UVUPSJBM@QMBZHSPVOE
    ؔٔآشٕ63-

    View full-size slide

  2. 6OJUZೖ໳
    5BUTVIJLP:BNBNVSB!6OJUZ

    View full-size slide

  3. 6OJUZͬͯʁ
    6OJUZೖ໳

    View full-size slide

  4. 1$ήʔϜ

    ϒϥ΢βήʔϜ
    ϞόΠϧ 73ίϯςϯπ ήʔϜػ
    6OJUZͰग़དྷΔ͜ͱ

    View full-size slide

  5. ࢢ৔઎༗཰ ࢖ͬͯΔ։ൃऀ ։ൃऀ਺
    ήʔϜͷ

    Πϯετʔϧ਺
    ສਓ ԯճ
    6OJUZͲͷఔ౓࢖ΘΕͯΔʁ

    View full-size slide

  6. 6OJUZήʔϜҎ֎ʹ͸ʁ
    ө૾࡞඼
    ݚڀ࡞඼
    8FCίϯςϯπ
    ҰൠΞϓϦέʔγϣϯ
    *05 ϝσΟΞɾΞʔτ

    View full-size slide

  7. ͲΜͳײ͡Ͱ࡞Δͷʁ
    6OJUZೖ໳

    View full-size slide

  8. 6OJUZͰήʔϜΛ࡞Δ
    $
    ը૾
    α΢ϯυ
    J04
    "OESPJE
    1$
    ؝ط
    ؝ط
    ؝ط

    View full-size slide

  9. 6OJUZͰήʔϜΛ࡞Δ
    • ͍͍ײ͡ͷը໘ޮՌ
    • ͍͍ײ͡ͷޫදݱ
    • ͍͍ײ͡ͷεςʔδߏ੒
    • ͍͍ײ͡ͷ6*
    • ͍͍ײ͡ͷΞχϝʔγϣϯ

    View full-size slide

  10. وأة٦ر٦ة׾⡲׷
    㸣䧭
    穈׫鴥׫
    ؜٦يءأذي׾⡲׷
    ،إحز׾⡲׷
    〳腉

    View full-size slide

  11. ꅾ銲זء٦ٝװ
    أذ٦آך⡲䧭
    װװꅾ銲ז
    ء٦ٝأذ٦آ
    㸣䧭
    ׉׸קו
    ꅾ銲דזְ鿇ⴓ
    ֶ⹻׭

    View full-size slide

  12. فٖ؎،ـٕז
    ٌحؙ،حف⡲䧭
    㸣䧭䏝׾
    ♳־׷
    㸣䧭䏝׾
    ♳־׷
    㸣䧭
    ֶ⹻׭

    View full-size slide

  13. ੈք
    Ϟϊ
    ৼΔ෣͍

    View full-size slide

  14. ੈք
    Ϟϊ
    ৼΔ෣͍

    View full-size slide

  15. 4DFOF
    (BNF

    0CKFDU
    $PNQPOFOU

    View full-size slide

  16. 4DFOF
    (BNF

    0CKFDU
    $PNQPOFOU
    ੈք
    ਓʑ


    ৼΔ෣͍

    View full-size slide

  17. 4DFOF
    (BNF

    0CKFDU
    $PNQPOFOU
    ੈքʢ4DFOFʣΛ࡞Γ

    ෺ʢ0CKFDUʣΛ഑ஔ͠

    ڍಈʢ$PNQPOFOUʣΛ༩͑Δ

    View full-size slide

  18. 4DFOF
    (BNF

    0CKFDU
    $PNQPOFOU
    㣓孡

    穗騟
    ؔـآؙؑزך朐䡾
    ⡘縧٥ぢֹ٥㣐ֹׁ
    䮶׷莸ְ

    View full-size slide

  19. $PNQPOFOUʹ͸

    ͲΜͳ΋ͷ͕͋Δͷʁ
    • ෺ཧԋࢉʢPhysicsʣ
    • ඳըʢRenderingʣ
    • AI
    • Ξχϝʔγϣϯ
    • ࣗ࡞ͷಈ࡞ʢC# Scriptʣ
    • ౰ͨΓ൑ఆʢColliderʣ
    • ΤϑΣΫτ
    • UI
    • ΦʔσΟΦʢAudioʣ
    • ͦͷଞॾʑ

    View full-size slide

  20. Ϙʔϧ
    ௓ͶΔ
    ϓϨΠϠʔ
    ԥΔऽΔ
    ৹൑
    δϟοδ

    ήʔϜਐߦ

    View full-size slide

  21. 6OJUZΤσΟλͷ

    ࢖͍ํΛ֮͑Α͏
    6OJUZೖ໳

    View full-size slide

  22. αϯϓϧϓϩδΣΫτΛ։͘

    View full-size slide

  23. 4DFOF
    (BNF

    0CKFDU
    $PNQPOFOU

    View full-size slide

  24. ͓קΊͷઃఆ

    View full-size slide

  25. 6OJUZΤσΟλͷݟํ

    View full-size slide

  26. ϓϩδΣΫτ

    ΢Οϯυ΢
    ώΤϥϧΩʔ
    γʔϯϏϡʔ
    ΠϯεϖΫλʔ

    Ϗϡʔ

    View full-size slide

  27. γʔϯϏϡʔ
    խ؜٦يח涫㜥ׅ׷ؔـآؙؑز׾

    խꂁ縧ׅ׷歗꬗

    View full-size slide

  28. ώΤϥϧΩʔ

    Ϗϡʔ
    խء٦ٝؽُ٦ח涫㜥ׅ׷ؔـآؙؑز׾

    խٔأز⻉׃׋׮ך

    View full-size slide

  29. ΠϯεϖΫλʔ

    Ϗϡʔ
    խ鼅䫛⚥ך갪湡ך

    խ鑫稢邌爙

    View full-size slide

  30. ϓϩδΣΫτϏϡʔ
    խفٗآؙؑزד⢪欽ׅ׷

    խ،إحز͑ؿ؋؎ٕךٔأزխ

    View full-size slide

  31. խ؜٦ي歗꬗חծ

    խ㹋ꥷח鋅ִ׷歗꬗
    ήʔϜϏϡʔ

    View full-size slide

  32. ࣮ࡍʹ

    ήʔϜΛ࠶ੜ

    ͯ͠ΈΑ͏
    խⱄ欰نةٝ׾䬃׃ג
    խ؜٦ي׾ⱄ欰

    View full-size slide

  33. ɹ8
    "4%
    獳⹛ 鋔挿㢌刿
    αϯϓϧήʔϜͷૢ࡞
    وؐأⵃ欽
    &4$

    View full-size slide

  34. ΦϒδΣΫτΛ

    ഑ஔͨ͠Γɺಈ͔ͨ͠Γ

    View full-size slide

  35. ɹ8
    "4%
    ⵸䖓䊩〸ח獳⹛
    γʔϯϏϡʔͷૢ࡞
    2ɹɹ&
    ♳♴ח獳⹛

    وؐأ〸سٓحؚ

    View full-size slide

  36. γʔϯϏϡʔͷૢ࡞

    View full-size slide

  37. ΦϒδΣΫτΛ഑ஔ

    View full-size slide

  38. ϓϦϛςΟϒͳ෺ͳΒ

    $SFBUF%0CKFDU

    View full-size slide

  39. ҠಈϞʔυ
    8Ωʔ
    ΦϒδΣΫτͷૢ࡞

    View full-size slide

  40. ճసϞʔυ
    խꫬ٥饔٥랕ך简׾

    խ鼅䫛׃גسٓحؚ
    &Ωʔ
    ΦϒδΣΫτͷૢ࡞

    View full-size slide

  41. ֦ॖϞʔυ
    3Ωʔ
    ΦϒδΣΫτͷૢ࡞

    View full-size slide

  42. *OTQFDUPS͔ΒͰ΋஋Λ

    ֬ೝɾૢ࡞͕ग़དྷΔ

    View full-size slide

  43. ৭Λม͑Δ

    View full-size slide

  44. ෳ਺ͷΦϒδΣΫτΛ

    ҰׅͰಈ͔͢

    View full-size slide

  45. ࣮ࡍʹૢ࡞ͯ͠ΈΔ

    View full-size slide

  46. ࣮ࡍʹૢ࡞ͯ͠ΈΔ
    وؐأ〸نةٝ׾

    䬃׃זָ׵

    84"%2&ؗ٦ד
    ء٦ٝךًؕٓ獳⹛
    8ؗ٦ד獳⹛
    &ؗ٦ד㔐鯄
    3ؗ٦ד䭁簭
    ٌ٦س㢌刿
    وذٔ،ٕ׾

    %%׃ג葿׾㢌刿ׅ׷
    1SPKFDUַ׵

    %%

    View full-size slide

  47. ͩΜܑ̏͝ఋΛ࡞Δ
    ࿅श

    View full-size slide

  48. 4QIFSF
    $ZMJOEFS
    وؐأ〸نةٝ׾

    䬃׃זָ׵

    84"%2&ؗ٦ד
    ء٦ٝךًؕٓ獳⹛
    )JFSBSDIZ

    $SFBUF%0CKFDU

    ͰΦϒδΣΫτੜ੒
    8ؗ٦ד獳⹛
    &ؗ٦ד㔐鯄
    3ؗ٦ד䭁簭
    ٌ٦س㢌刿

    View full-size slide

  49. ػೳΛ௥Ճͯ͠ΈΑ͏
    6OJUZೖ໳

    View full-size slide

  50. 4DFOF
    (BNF0CKFDU
    $PNQPOFOU

    View full-size slide

  51. 4DFOF
    (BNF

    0CKFDU
    $PNQPOFOU
    㣓孡

    穗騟
    ؔـآؙؑزך朐䡾
    ⡘縧٥ぢֹ٥㣐ֹׁ
    䮶׷莸ְ

    View full-size slide

  52. ΦϒδΣΫτͷΠϝʔδ
    ໊લ
    ࠲ඪɺ޲͖

    େ͖͞
    ඳը͢ΔϞσϧ
    ඳըઃఆ
    ౰ͨΓ൑ఆ

    View full-size slide

  53. ΦϒδΣΫτͷΠϝʔδ
    ໊લ
    ࠲ඪɺ޲͖

    େ͖͞
    ඳը͢ΔϞσϧ
    ඳըઃఆ
    ౰ͨΓ൑ఆ

    View full-size slide

  54. ػೳΛ଍͢

    View full-size slide

  55. ػೳΛফ͢

    View full-size slide

  56. ࠶ੜΛఀࢭ͢Δ
    խⱄ欰نةٝ׾䬃׃ג
    խ؜٦ي׾⨡姺

    View full-size slide

  57. ࠶ੜΛఀࢭ͢Δ
    խⱄ欰⚥ח㢌⻉׃׋ⰻ㺁ָ

    խⰋג搀ַ׏׋ֿהח
    w w w w w w

    View full-size slide

  58. ࠶ੜΛఀࢭ͢Δ
    խⱄ欰⚥ח㢌⻉׃׋ⰻ㺁ָ

    խⰋג搀ַ׏׋ֿהח
    w w w w w w
    γʔϯͷมߋ͸

    ήʔϜఀࢭதʹߦ͓͏

    View full-size slide

  59. (BNF0CKFDUΛॻग़͠
    ʢผ໊ɿ1SFGBCੜ੒ʣ

    View full-size slide

  60. ࡞੒ͨ͠ϓϨϋϒΛγʔϯʹ഑ஔ

    View full-size slide

  61. ࣗ࡞ͷػೳΛ௥Ճ͠Α͏
    6OJUZೖ໳

    View full-size slide

  62. ࣗ࡞ͷػೳΛ଍͢

    View full-size slide

  63. εΫϦϓτΛॻ͘
    VTJOH6OJUZ&OHJOF

    VTJOH4ZTUFN$PMMFDUJPOT


    QVCMJDDMBTT3PUBUJPO.POP#FIBWJPVS\


    剑ⴱךؿٖ٦يדㄎל׸׷

    WPJE4UBSU
    \


    ^


    嫣ؿٖ٦يㄎל׸׷

    WPJE6QEBUF
    \


    ^

    ^

    .POP#FIBWJPVSًحإ٦آ
    .POP#FIBWJPVSًحإ٦آ

    View full-size slide

  64. εΫϦϓτΛॻ͘
    VTJOH6OJUZ&OHJOF
    VTJOH4ZTUFN$PMMFDUJPOT
    QVCMJDDMBTT3PUBUJPO.POP#FIBWJPVS\

    :鯥׾嫣ؿٖ٦ي5JNFEFMUB5JNF䏝㔐鯄ׇׁ׷
    WPJE6QEBUF
    \
    USBOTGPSN3PUBUF OFX7FDUPS 5JNFEFMUB5JNF


    ^
    ^

    View full-size slide

  65. USBOTGPSN3PUBUF

    荈ⴓ荈魦ך5SBOTGPSN؝ٝه٦طٝزח،ؙإأ
    㔐鯄ׇׁ׷הְֲㄏ⟀ꟼ侧
    㔐鯄ׇׁ׷⦼כ:䏟垥ָ⵸ךؿٖ٦يַ׵穗麓׃׋猱侧9ծ9䏟垥ה;䏟垥כئٗ

    View full-size slide

  66. ্ख͘ಈ͔ͳ͍৔߹ʜ

    View full-size slide

  67. ্ख͘ಈ͔ͳ͍৔߹ʜ
    • εΫϦϓτ໊ͱΫϥε໊͕Ұகͯ͠ͳ͍
    • .POPEFWFMPQͰ$PNNBOE#΋͘͠͸'̔Λԡ͢
    • ҟͳΔίϯϙʔωϯτ͕ઃఆ͞ΕͯΔ
    • .POPCFIBWJPVSϝοηʔδ͕UZQPͯ͠Δ

    View full-size slide

  68. εΫϦϓτΛॻ͘
    VTJOH6OJUZ&OHJOF
    VTJOH4ZTUFN$PMMFDUJPOT
    QVCMJDDMBTT3PUBUJPO.POP#FIBWJPVS\

    :鯥׾嫣ؿٖ٦ي5JNFEFMUB5JNF䏝㔐鯄ׇׁ׷
    WPJE6QEBUF
    \
    USBOTGPSN3PUBUF OFX7FDUPS 5JNFEFMUB5JNF


    ^
    ^
    - ஋͕ιʔείʔυʹ௚ॻ͖
    - 5ZQP΍ຖճͷίϯύΠϧ͕໘౗
    - ΋ͬͱखܰʹඍௐ੔͍ͨ͠

    View full-size slide

  69. ϓϩύςΟͷ࿐ग़
    VTJOH6OJUZ&OHJOF
    VTJOH4ZTUFN$PMMFDUJPOT
    QVCMJDDMBTT3PUBUJPO.POP#FIBWJPVS\
    QVCMJDJOUTQFFE
    :鯥׾嫣ؿٖ٦ي5JNFEFMUB5JNF䏝㔐鯄ׇׁ׷
    WPJE6QEBUF
    \
    USBOTGPSN3PUBUF TQFFE

    ^
    ^

    View full-size slide

  70. ଞͷίϯϙʔωϯτͱͷ࿈ܞ
    • GetComponent<ίϯϙʔωϯτ໊>();

    ಉҰΦϒδΣΫτͷίϯϙʔωϯτΛऔಘ͢Δ
    • FindObjectOfType<ίϯϙʔωϯτ໊>();

    ࢦఆίϯϙʔωϯτΛγʔϯ͔Β୳ͯ͠औಘ͢Δ
    • public΍[SerialiseField]Ͱެ։

    UnityΤσΟλͷGUIͰηοτΞοϓ͢Δ

    View full-size slide

  71. ଞͷίϯϙʔωϯτͱͷ࿈ܞ

    View full-size slide

  72. ଞͷίϯϙʔωϯτͱͷ࿈ܞ
    VTJOH6OJUZ&OHJOF
    VTJOH4ZTUFN$PMMFDUJPOT
    QVCMJDDMBTT$IFDL1PTJUJPO.POP#FIBWJPVS\
    QVCMJD5SBOTGPSNUBSHFU
    WPJE6QEBUF

    \
    JG UBSHFUQPTJUJPOZ
    \
    ة٦؜حز׾嶊ׅ
    ^
    ^
    ^

    View full-size slide

  73. ଞͷίϯϙʔωϯτͱͷ࿈ܞ
    VTJOH6OJUZ&OHJOF
    VTJOH4ZTUFN$PMMFDUJPOT
    QVCMJDDMBTT$IFDL1PTJUJPO.POP#FIBWJPVS\
    QVCMJD5SBOTGPSNUBSHFU
    WPJE6QEBUF

    \
    JG UBSHFUQPTJUJPOZ
    \
    LJMM
    ^
    ^
    ^

    View full-size slide

  74. ଞͷίϯϙʔωϯτͱͷ࿈ܞ
    VTJOH6OJUZ&OHJOF
    VTJOH4ZTUFN$PMMFDUJPOT
    QVCMJDDMBTT$IFDL1PTJUJPO.POP#FIBWJPVS\
    QVCMJD5SBOTGPSNUBSHFU
    WPJE6QEBUF

    \
    JG UBSHFUQPTJUJPOZ
    \
    LJMM
    ^
    ^
    ^

    View full-size slide

  75. 6OJUZͷఏڙ͢ΔαʔϏε
    6OJUZೖ໳

    View full-size slide

  76. 6OJUZͷϥΠηϯε

    View full-size slide

  77. ϥΠηϯε
    ֤ϓϥϯʹػೳతͳࠩ͸΄΅ແ͍
    ऩೖʹԠͨ͡ϨϕχϡʔΩϟοϓ
    1FSTPOBM

    1MVT

    1SP
    લ೥ͷച্͕ສԁҎԼͷ৔߹ͷΈར༻Մೳ

    લ೥ͷച্͕ສԁҎԼͷ৔߹ͷΈར༻Մೳ

    ੍ݶແ͠
    1FSTPOBM͸4QMBTI4DSFFOΛফͤͳ͍

    $BDIF4FSWFS͕࢖͑ͳ͍ʜ͙Β͍

    View full-size slide

  78. Unity Ads
     渣׾剑㣐⻉ׇׁ׷
    Unity Analytics
    فٖ؎َ٦ך遤⹛׾ر٦ة׾〳鋔⻉ׅ׷
    Unity Performance Reporting
    ؜٦يך⢽㢩׾ٍؗفثٍׅ׷
    Unity Cloud Build
    ؽٕس׾ؙٓؐسח䫎־גծꟚ涪儗꟦ך⸬桦⻉
    Unity Collaborate (beta)
    ء٦يٖأח⼿噟׾遤ֲ
    Unity Certification
    ֮ז׋ך6OJUZإٔؗ׾⥂鏾ׅ׷
    ։ൃͰָ͢ΔαʔϏε

    View full-size slide

  79. ։ൃͰָ͢ΔαʔϏε

    View full-size slide

  80. 6OJUZೖ໳
    ޮ཰Α͘शಘ͢Δҝʹ

    View full-size slide

  81. ॻ੶Ͱֶश

    View full-size slide

  82. ಈըͰֶश
    㷕עثُ٦زٔ،ٕ

    View full-size slide

  83. ೔ຊޠࣈນ

    View full-size slide

  84. ΦϑϥΠϯ
    Πϕϯτͷ

    ಈը

    View full-size slide

  85. ΦϑϥΠϯΠϕϯτ
    6OJUF
    6OJUZಓ৔
    ͦͷଞ৭ʑ

    View full-size slide

  86. (BNF+BNʹࢀՃ

    View full-size slide

  87. (BNF+BNʹࢀՃ
    ϓϥϯχϯά͔Β

    ϩʔϯν·Ͱମݧग़དྷΔ
    ࣗ෼ͷʢ૬ରతͳʣՁ஋͕

    ʢԿͱͳ͘ʣ෼͔Δ
    ஥͕ؒग़དྷΔɺ࢓ࣄʹܨ͕Δʢࣄ͕͋Δʣ

    View full-size slide

  88. (BNF+BNʹࢀՃ
    䎃

    ؚٗ٦غٕ؜٦يآٍي
    ⡲ㅷך秈ⶴָ6OJUZ 62% 14%
    24%
    Other Other Engine Unity

    View full-size slide

  89. ίϛϡχςΟΛ׆༻

    View full-size slide

  90. ίϛϡχςΟʹࢀՃ
    6OJUZϢʔβʔॿ͚߹͍ॴ
    6OJUZϢʔβʔࡶஊॴ
    6OJUZ৬ۀ҆ఆॴ
    6OJUZίϛϡχςΟ
    6OJUZ$PNNVOJUZ
    'BDFCPPL
    'BDFCPPL
    'BDFCPPL
    4MBDL
    Ⱅ䒭ؿؓ٦ٓي薉铂

    View full-size slide

  91. άάΔ
    ௐ΂Δ
    ਓʹฉ͘

    View full-size slide

  92. άάΔ
    ௐ΂Δ
    ਓʹฉ͘
    ͱΓ͋͑ͣ
    ࡞ͬͯΈΔ

    View full-size slide