From 92b3c810204359521eca24070f213aefbe9be6d5 Mon Sep 17 00:00:00 2001 From: Zach Vinless Date: Sun, 6 Nov 2016 23:20:50 -0800 Subject: [PATCH 1/5] Added pro skin icons and moved editor textures - Added Fungus Editor Resources folder for editor textures (these should no longer get included in builds) - Added pro skin icons in Fungus Editor Resources/Icons/Pro - All editor textures should now be accessible as properties in FungusEditorResources. If the textures change, use Tools -> Fungus -> Utilities -> UpdateEditorResourcesScript to automatically update this --- Assets/Fungus/Fungus Editor Resources.meta | 9 + .../Icons.meta | 0 .../Fungus Editor Resources/Icons/Pro.meta | 9 + .../Fungus Editor Resources/Icons/Pro/add.png | Bin 0 -> 865 bytes .../Icons/Pro/add.png.meta} | 16 +- .../Icons/Pro/add_small.png | Bin 0 -> 865 bytes .../Icons/Pro/add_small.png.meta} | 16 +- .../Icons/Pro/delete.png | Bin 0 -> 1076 bytes .../Icons/Pro/delete.png.meta} | 16 +- .../Icons/Pro/down.png | Bin 0 -> 1069 bytes .../Icons/Pro/down.png.meta | 59 ++++++ .../Icons/Pro/duplicate.png | Bin 0 -> 1106 bytes .../Icons/Pro/duplicate.png.meta | 59 ++++++ .../Fungus Editor Resources/Icons/Pro/up.png | Bin 0 -> 1025 bytes .../Icons/Pro/up.png.meta | 59 ++++++ .../Icons/add.png | Bin .../Icons/add.png.meta | 0 .../Icons/add_small.png | Bin .../Icons/add_small.png.meta | 0 .../Icons/delete.png | Bin .../Icons/delete.png.meta | 0 .../Icons/down.png | Bin .../Icons/down.png.meta | 0 .../Icons/duplicate.png | Bin .../Icons/duplicate.png.meta | 0 .../Icons/up.png | Bin .../Icons/up.png.meta | 0 .../Textures.meta | 0 .../Textures/choice_node_off.png | Bin .../Textures/choice_node_off.png.meta | 0 .../Textures/choice_node_on.png | Bin .../Textures/choice_node_on.png.meta | 0 .../Textures/command_background.png | Bin .../Textures/command_background.png.meta | 0 .../Textures/event_node_off.png | Bin .../Textures/event_node_off.png.meta | 0 .../Textures/event_node_on.png | Bin .../Textures/event_node_on.png.meta | 0 .../Textures/play_big.png | Bin .../Textures/play_big.png.meta | 0 .../Textures/play_small.png | Bin .../Textures/play_small.png.meta | 0 .../Textures/process_node_off.png | Bin .../Textures/process_node_off.png.meta | 0 .../Textures/process_node_on.png | Bin .../Textures/process_node_on.png.meta | 0 .../Fungus/Resources/Icons/ResizeHandle.png | Bin 2968 -> 0 bytes Assets/Fungus/Resources/Icons/left.png | Bin 2911 -> 0 bytes Assets/Fungus/Resources/Icons/right.png | Bin 2903 -> 0 bytes Assets/Fungus/Scripts/Editor/BlockEditor.cs | 10 +- .../Scripts/Editor/CommandListAdaptor.cs | 4 +- .../Fungus/Scripts/Editor/FlowchartEditor.cs | 2 +- .../Fungus/Scripts/Editor/FlowchartWindow.cs | 16 +- .../Scripts/Editor/FungusEditorResources.cs | 199 ++++++------------ .../Editor/FungusEditorResourcesGenerated.cs | 26 +++ .../FungusEditorResourcesGenerated.cs.meta | 12 ++ 56 files changed, 345 insertions(+), 167 deletions(-) create mode 100644 Assets/Fungus/Fungus Editor Resources.meta rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons.meta (100%) create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro.meta create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png rename Assets/Fungus/{Resources/Icons/right.png.meta => Fungus Editor Resources/Icons/Pro/add.png.meta} (77%) create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/add_small.png rename Assets/Fungus/{Resources/Icons/ResizeHandle.png.meta => Fungus Editor Resources/Icons/Pro/add_small.png.meta} (77%) create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png rename Assets/Fungus/{Resources/Icons/left.png.meta => Fungus Editor Resources/Icons/Pro/delete.png.meta} (77%) create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png.meta create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png.meta create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png create mode 100644 Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png.meta rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/add.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/add.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/add_small.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/add_small.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/delete.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/delete.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/down.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/down.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/duplicate.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/duplicate.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/up.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Icons/up.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/choice_node_off.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/choice_node_off.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/choice_node_on.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/choice_node_on.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/command_background.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/command_background.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/event_node_off.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/event_node_off.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/event_node_on.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/event_node_on.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/play_big.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/play_big.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/play_small.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/play_small.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/process_node_off.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/process_node_off.png.meta (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/process_node_on.png (100%) rename Assets/Fungus/{Resources => Fungus Editor Resources}/Textures/process_node_on.png.meta (100%) delete mode 100644 Assets/Fungus/Resources/Icons/ResizeHandle.png delete mode 100644 Assets/Fungus/Resources/Icons/left.png delete mode 100644 Assets/Fungus/Resources/Icons/right.png create mode 100644 Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs create mode 100644 Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs.meta diff --git a/Assets/Fungus/Fungus Editor Resources.meta b/Assets/Fungus/Fungus Editor Resources.meta new file mode 100644 index 00000000..81e8ab72 --- /dev/null +++ b/Assets/Fungus/Fungus Editor Resources.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 5ff164265158945c18b7d438b570ba22 +folderAsset: yes +timeCreated: 1478502248 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Icons.meta b/Assets/Fungus/Fungus Editor Resources/Icons.meta similarity index 100% rename from Assets/Fungus/Resources/Icons.meta rename to Assets/Fungus/Fungus Editor Resources/Icons.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro.meta b/Assets/Fungus/Fungus Editor Resources/Icons/Pro.meta new file mode 100644 index 00000000..9dab8a98 --- /dev/null +++ b/Assets/Fungus/Fungus Editor Resources/Icons/Pro.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 5e5a1319ef7f546a7affe3baabd5fba6 +folderAsset: yes +timeCreated: 1478502692 +licenseType: Free +DefaultImporter: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png new file mode 100644 index 0000000000000000000000000000000000000000..23646d93077e6966bca77415871932dbb13c9752 GIT binary patch literal 865 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1|)ksWqBDG7;Q2`B1$5BeXNr6bM+Ea@{>~a zDsl^e@(c_%_7w$*$=RtT3Q4KynR&KK?|1K4QpilPRSGxtHSjHPPR+>ls47YguJQ{> zuF6ifOi{A8KQ26aVgjorKDK}xwt_!19`Se86_nJR{Hwo<>h+i#(Mch>H3D2mX`VkM*2oZ zx=P7{9OiaozEwNS74=qkDD%P(`OwP~; zD#PfSVCE67V%(g(RhALa+U*xFl2C2Z)X@p*X#LS6v?aLt zhXP9{*S=X#CV98m^zCL5^ya=TB4)S2u%mZt*&}-ej;5&21Z^=cGo|M_LLLIfr{C56 zzCH8i-N=G9DqE*qHDFm;a*gM#Pi0uxbsJxOi_9f+_1F&2O7+pxVOfzG&wpj*&wcSv zSH1nd-g2>_ck`~ahn!~(HXqu2=-}El3x7D=SgU#{@FDj@yI?(yKTE!Nblw*^-u))P z^6s;s6Z&t&z8zU@5p*=_kPl}+SNZZumTPO|zfQUqQB@iE^3v`N9EOKQ*B=V`a#vp{WY>MYbl24Hnl^_n@v-DR{J>Flu6&2D z%K%d^XMsm#F#`j)FbFd;%$g$s6twbmaSXBOO-_(tUEI(J1P@P4RQ}&DWBF;m#8#gx z+vdDtGkP>h;fbrXwDg*)mG7Ju9r(~SCD1^Kfgztu&_d{2*)>qk@O1TaS?83{1OQNW BPon?; literal 0 HcmV?d00001 diff --git a/Assets/Fungus/Resources/Icons/right.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png.meta similarity index 77% rename from Assets/Fungus/Resources/Icons/right.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png.meta index 7c6971a5..422af796 100644 --- a/Assets/Fungus/Resources/Icons/right.png.meta +++ b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png.meta @@ -1,5 +1,7 @@ fileFormatVersion: 2 -guid: b3dd8b25a62664f379cb3714060d4e33 +guid: 4e43c476b4a7a49a08c37378fb01ce99 +timeCreated: 1478502692 +licenseType: Free TextureImporter: fileIDToRecycleName: {} serializedVersion: 2 @@ -15,17 +17,17 @@ TextureImporter: bumpmap: convertToNormalMap: 0 externalNormalMap: 0 - heightScale: .25 + heightScale: 0.25 normalMapFilter: 0 isReadable: 0 grayScaleToAlpha: 0 generateCubemap: 0 cubemapConvolution: 0 - cubemapConvolutionSteps: 8 + cubemapConvolutionSteps: 7 cubemapConvolutionExponent: 1.5 seamlessCubemap: 0 textureFormat: -3 - maxTextureSize: 1024 + maxTextureSize: 2048 textureSettings: filterMode: -1 aniso: 1 @@ -35,18 +37,22 @@ TextureImporter: lightmap: 0 rGBM: 0 compressionQuality: 50 + allowsAlphaSplitting: 0 spriteMode: 0 spriteExtrude: 1 spriteMeshType: 1 alignment: 0 - spritePivot: {x: .5, y: .5} + spritePivot: {x: 0.5, y: 0.5} spriteBorder: {x: 0, y: 0, z: 0, w: 0} spritePixelsToUnits: 100 alphaIsTransparency: 1 + spriteTessellationDetail: -1 textureType: 2 buildTargetSettings: [] spriteSheet: + serializedVersion: 2 sprites: [] + outline: [] spritePackingTag: userData: assetBundleName: diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add_small.png b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add_small.png new file mode 100644 index 0000000000000000000000000000000000000000..cf6b201ee000847da384d4353aed81a6769252f9 GIT binary patch literal 865 zcmeAS@N?(olHy`uVB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|S&mJ&t9mH#A@@VOU_FgLOTKt?-WNIE z{U*Tj?z5m1`ftR(9a(J=bTsOa4`)AD`SMAYYis1cPP!IRRT=p5((Vl$hKEJup3OMc z-=BCa^~=Tn>5P$q%J-ss_$N(_@O5j>^)c(5tl&L=h2=@P$&uo=YPyB`!}F#}JF&x04q70i&et|IA2NfsR$dN2hh! z9f*C$D)o!aLgb~kLIu0X`GDZw9Vh3l(Oor3K&9zHp4dUzojMz06jVh2y!-!czP<5D zrr&yAwqc>APv+caIuZ5dg2`FW$Z7t~T(5WSV=1`k+|IzaXr?&BdE5HA&wqxd$Jk3c z-4MK(oAo+Eu_e}M!7Aa3Fu%H|j3$i8nLj7*j907sy`- Qxd6)Sp00i_>zopr06;>sEC2ui literal 0 HcmV?d00001 diff --git a/Assets/Fungus/Resources/Icons/left.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png.meta similarity index 77% rename from Assets/Fungus/Resources/Icons/left.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png.meta index 546dd74e..da792108 100644 --- a/Assets/Fungus/Resources/Icons/left.png.meta +++ b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png.meta @@ -1,5 +1,7 @@ fileFormatVersion: 2 -guid: c0a7a4711d69249ab9dae1539a3247ee +guid: 29c4d29b1678042a5b3516c732ccc507 +timeCreated: 1478502692 +licenseType: Free TextureImporter: fileIDToRecycleName: {} serializedVersion: 2 @@ -15,17 +17,17 @@ TextureImporter: bumpmap: convertToNormalMap: 0 externalNormalMap: 0 - heightScale: .25 + heightScale: 0.25 normalMapFilter: 0 isReadable: 0 grayScaleToAlpha: 0 generateCubemap: 0 cubemapConvolution: 0 - cubemapConvolutionSteps: 8 + cubemapConvolutionSteps: 7 cubemapConvolutionExponent: 1.5 seamlessCubemap: 0 textureFormat: -3 - maxTextureSize: 1024 + maxTextureSize: 2048 textureSettings: filterMode: -1 aniso: 1 @@ -35,18 +37,22 @@ TextureImporter: lightmap: 0 rGBM: 0 compressionQuality: 50 + allowsAlphaSplitting: 0 spriteMode: 0 spriteExtrude: 1 spriteMeshType: 1 alignment: 0 - spritePivot: {x: .5, y: .5} + spritePivot: {x: 0.5, y: 0.5} spriteBorder: {x: 0, y: 0, z: 0, w: 0} spritePixelsToUnits: 100 alphaIsTransparency: 1 + spriteTessellationDetail: -1 textureType: 2 buildTargetSettings: [] spriteSheet: + serializedVersion: 2 sprites: [] + outline: [] spritePackingTag: userData: assetBundleName: diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png new file mode 100644 index 0000000000000000000000000000000000000000..b84dbd531df99f234508b6cdf6836c40959fa038 GIT binary patch literal 1069 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1|)ksWqBDG7;Q5{B1$5BeXNr6bM+Ea@{>~a zDsl^e@(c_%_7w$*$=RtT3Q4KynR&KK?|1K4QpilPRSGxtHSjHPPR+>ls47YguJQ{> zuF6ifOi{A8KQ26aVgjorKDK}xwt_!19`Se86_nJR{Hwo<>h+i#(Mch>H3D2mX`VkM*2oZ zx=P7{9OiaozEwNS74=qkDD%P(`OwP~; zD#PsuOO(<{hJSJDSLLm%o6pojF~J_2&!VUn5$42UA2k9Dnmo&p21 zHPhKSpg73gNx{?A+04+=%uLrv&yayZV`AyV-QLWO0`2yT7fGl#Y3k?%b+rEI5!w>m z{6m4IlWX6sCzHHeZ2ESy2zqnh77?@CVA#>Swd|3-0!LF+XM(mEmzmP@93c+@9DNGjOV|y^5?$z zr>ow6UvIhC(7Sn8+C$E>2AdCUK6G&HnuR|cZmd;36!?()pRs$e0gd21`fl+B681W9P95- zJeK<9V*hl;$Uxw$*b5=$G!ix&BD{x5PKGUus-m+c93(i-`;0azZlZ z>B7%9Ic7gx6rz83;p-2De7UPH6te5SUb<`QcTJl^m-txn9)94cI&y#OM{YUZbXUH^ z*JXgom$SelvY3H^TNs2H8D`Cq0LBulr;B5VMeozewtmcp0b5Cf~GVQvwbi<8f#Z%`bwHldtZ&CUk?BKfWQ_u6-s%i5YH*53hu6Sj7 zGMvF+v$SC3*SEX(7nL155V%?MbkUU5o6-&Cf;Yc%hL-X?*tBZZYMb-+{xZiT=6Ufv#$4&-@?uI z<%pZhv$SnFjk>!N_VP*l$$Q*0P5ACS>tN8;)>V3SyuapuWp!=MQE~Z^QwqxEp00i_ I>zopr06uWF@c;k- literal 0 HcmV?d00001 diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png.meta new file mode 100644 index 00000000..9dba1d7d --- /dev/null +++ b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 5a87a7d3683164a238377d948572805f +timeCreated: 1478502692 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png new file mode 100644 index 0000000000000000000000000000000000000000..7a36f572a8b6eff2d19ba3f0a606ddcaf93a82f8 GIT binary patch literal 1106 zcmeAS@N?(olHy`uVBq!ia0vp^A|TAc1|)ksWqBDG7@aahB1$5BeXNr6bM+Ea@{>~a zDsl^e@(c_%_7w$*$=RtT3Q4KynR&KK?|1K4QpilPRSGxtHSjHPPR+>ls47YguJQ{> zuF6ifOi{A8KQ26aVgjorKDK}xwt_!19`Se86_nJR{Hwo<>h+i#(Mch>H3D2mX`VkM*2oZ zx=P7{9OiaozEwNS74=qkDD%P(`OwP~; zD#Pbn?P$xKcxN!2UJOIOkdxkVr97@)88;obsr-~p4G2MmoOpts|$ z^DYI3W^1Oib3k#ByOV;atFxJ*rJ0$ok)9y~gT}J5 z(Id1axcP?yODEU9Sx+W;x7hUUW)bw}zAYkVx52QZcWc=rdj*cBsLlj!F)lNu=Q%-D`)&0Ib^XA>if;B2zr(88)Sy^(8=d4da*$x|(uHulWC6 zyLQQa&r;#2=Lodhp)>3(=ca&M`SSr1Gg{;GcwGYBLR#hRZkbk5R2ZclMMZi7znujSJ*NsFk;)1 zCC?ZpM%*m%Y_?!H{(vE*dWLBD2JSFx<%@;98W|26FC}KFcrEIcwfZsjuWjAGZR|f@ zFDg?|`Zc>ZG<5FN)Ss5$`rSW^GyG=B=2e&~a zDsl^e@(c_%_7w$*$=RtT3Q4KynR&KK?|1K4QpilPRSGxtHSjHPPR+>ls47YguJQ{> zuF6ifOi{A8KQ26aVgjorKDK}xwt_!19`Se86_nJR{Hwo<>h+i#(Mch>H3D2mX`VkM*2oZ zx=P7{9OiaozEwNS74=qkDD%P(`OwP~; zD#FD=k3$V*q!2RT9?>I$HD^x^&ia^NA7ngAH7>uo% z&dveFLGDfpp03VjhL&b#x<-123=A3*ODFF3W_A>4w_m(SLbXX#M<=MG^+%7;mf+?e z3M`#m`({0v>)6)kjZDJ+|Gu)Vo-07Vbmz_WN7BC~zKQ)(d+F0uaHS3#!}noCzMXlgnq_vf%n+{d`(LTT3G&`r}o OIoH$G&t;ucLK6U96rpnf literal 0 HcmV?d00001 diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png.meta new file mode 100644 index 00000000..2371a0d0 --- /dev/null +++ b/Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png.meta @@ -0,0 +1,59 @@ +fileFormatVersion: 2 +guid: 2a76a781db2994b33b83cd84b8835da7 +timeCreated: 1478502692 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + serializedVersion: 2 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + linearTexture: 1 + correctGamma: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 0 + cubemapConvolution: 0 + cubemapConvolutionSteps: 7 + cubemapConvolutionExponent: 1.5 + seamlessCubemap: 0 + textureFormat: -3 + maxTextureSize: 2048 + textureSettings: + filterMode: -1 + aniso: 1 + mipBias: -1 + wrapMode: 1 + nPOTScale: 0 + lightmap: 0 + rGBM: 0 + compressionQuality: 50 + allowsAlphaSplitting: 0 + spriteMode: 0 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 2 + buildTargetSettings: [] + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Fungus/Resources/Icons/add.png b/Assets/Fungus/Fungus Editor Resources/Icons/add.png similarity index 100% rename from Assets/Fungus/Resources/Icons/add.png rename to Assets/Fungus/Fungus Editor Resources/Icons/add.png diff --git a/Assets/Fungus/Resources/Icons/add.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/add.png.meta similarity index 100% rename from Assets/Fungus/Resources/Icons/add.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/add.png.meta diff --git a/Assets/Fungus/Resources/Icons/add_small.png b/Assets/Fungus/Fungus Editor Resources/Icons/add_small.png similarity index 100% rename from Assets/Fungus/Resources/Icons/add_small.png rename to Assets/Fungus/Fungus Editor Resources/Icons/add_small.png diff --git a/Assets/Fungus/Resources/Icons/add_small.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/add_small.png.meta similarity index 100% rename from Assets/Fungus/Resources/Icons/add_small.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/add_small.png.meta diff --git a/Assets/Fungus/Resources/Icons/delete.png b/Assets/Fungus/Fungus Editor Resources/Icons/delete.png similarity index 100% rename from Assets/Fungus/Resources/Icons/delete.png rename to Assets/Fungus/Fungus Editor Resources/Icons/delete.png diff --git a/Assets/Fungus/Resources/Icons/delete.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/delete.png.meta similarity index 100% rename from Assets/Fungus/Resources/Icons/delete.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/delete.png.meta diff --git a/Assets/Fungus/Resources/Icons/down.png b/Assets/Fungus/Fungus Editor Resources/Icons/down.png similarity index 100% rename from Assets/Fungus/Resources/Icons/down.png rename to Assets/Fungus/Fungus Editor Resources/Icons/down.png diff --git a/Assets/Fungus/Resources/Icons/down.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/down.png.meta similarity index 100% rename from Assets/Fungus/Resources/Icons/down.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/down.png.meta diff --git a/Assets/Fungus/Resources/Icons/duplicate.png b/Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png similarity index 100% rename from Assets/Fungus/Resources/Icons/duplicate.png rename to Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png diff --git a/Assets/Fungus/Resources/Icons/duplicate.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png.meta similarity index 100% rename from Assets/Fungus/Resources/Icons/duplicate.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png.meta diff --git a/Assets/Fungus/Resources/Icons/up.png b/Assets/Fungus/Fungus Editor Resources/Icons/up.png similarity index 100% rename from Assets/Fungus/Resources/Icons/up.png rename to Assets/Fungus/Fungus Editor Resources/Icons/up.png diff --git a/Assets/Fungus/Resources/Icons/up.png.meta b/Assets/Fungus/Fungus Editor Resources/Icons/up.png.meta similarity index 100% rename from Assets/Fungus/Resources/Icons/up.png.meta rename to Assets/Fungus/Fungus Editor Resources/Icons/up.png.meta diff --git a/Assets/Fungus/Resources/Textures.meta b/Assets/Fungus/Fungus Editor Resources/Textures.meta similarity index 100% rename from Assets/Fungus/Resources/Textures.meta rename to Assets/Fungus/Fungus Editor Resources/Textures.meta diff --git a/Assets/Fungus/Resources/Textures/choice_node_off.png b/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png similarity index 100% rename from Assets/Fungus/Resources/Textures/choice_node_off.png rename to Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png diff --git a/Assets/Fungus/Resources/Textures/choice_node_off.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/choice_node_off.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png.meta diff --git a/Assets/Fungus/Resources/Textures/choice_node_on.png b/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png similarity index 100% rename from Assets/Fungus/Resources/Textures/choice_node_on.png rename to Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png diff --git a/Assets/Fungus/Resources/Textures/choice_node_on.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/choice_node_on.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png.meta diff --git a/Assets/Fungus/Resources/Textures/command_background.png b/Assets/Fungus/Fungus Editor Resources/Textures/command_background.png similarity index 100% rename from Assets/Fungus/Resources/Textures/command_background.png rename to Assets/Fungus/Fungus Editor Resources/Textures/command_background.png diff --git a/Assets/Fungus/Resources/Textures/command_background.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/command_background.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/command_background.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/command_background.png.meta diff --git a/Assets/Fungus/Resources/Textures/event_node_off.png b/Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png similarity index 100% rename from Assets/Fungus/Resources/Textures/event_node_off.png rename to Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png diff --git a/Assets/Fungus/Resources/Textures/event_node_off.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/event_node_off.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png.meta diff --git a/Assets/Fungus/Resources/Textures/event_node_on.png b/Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png similarity index 100% rename from Assets/Fungus/Resources/Textures/event_node_on.png rename to Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png diff --git a/Assets/Fungus/Resources/Textures/event_node_on.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/event_node_on.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png.meta diff --git a/Assets/Fungus/Resources/Textures/play_big.png b/Assets/Fungus/Fungus Editor Resources/Textures/play_big.png similarity index 100% rename from Assets/Fungus/Resources/Textures/play_big.png rename to Assets/Fungus/Fungus Editor Resources/Textures/play_big.png diff --git a/Assets/Fungus/Resources/Textures/play_big.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/play_big.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/play_big.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/play_big.png.meta diff --git a/Assets/Fungus/Resources/Textures/play_small.png b/Assets/Fungus/Fungus Editor Resources/Textures/play_small.png similarity index 100% rename from Assets/Fungus/Resources/Textures/play_small.png rename to Assets/Fungus/Fungus Editor Resources/Textures/play_small.png diff --git a/Assets/Fungus/Resources/Textures/play_small.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/play_small.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/play_small.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/play_small.png.meta diff --git a/Assets/Fungus/Resources/Textures/process_node_off.png b/Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png similarity index 100% rename from Assets/Fungus/Resources/Textures/process_node_off.png rename to Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png diff --git a/Assets/Fungus/Resources/Textures/process_node_off.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/process_node_off.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png.meta diff --git a/Assets/Fungus/Resources/Textures/process_node_on.png b/Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png similarity index 100% rename from Assets/Fungus/Resources/Textures/process_node_on.png rename to Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png diff --git a/Assets/Fungus/Resources/Textures/process_node_on.png.meta b/Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png.meta similarity index 100% rename from Assets/Fungus/Resources/Textures/process_node_on.png.meta rename to Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png.meta diff --git a/Assets/Fungus/Resources/Icons/ResizeHandle.png b/Assets/Fungus/Resources/Icons/ResizeHandle.png deleted file mode 100644 index aedc1d2e9485e837bceb1d9c77a7de6639608747..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2968 zcmV;J3up9+P)KLZ*U+IBfRsybQWXdwQbLP>6pAqfylh#{fb6;Z(vMMVS~$e@S=j*ftg6;Uhf59&ghTmgWD0l;*T zI709Y^p6lP1rIRMx#05C~cW=H_Aw*bJ-5DT&Z2n+x)QHX^p z00esgV8|mQcmRZ%02D^@S3L16t`O%c004NIvOKvYIYoh62rY33S640`D9%Y2D-rV&neh&#Q1i z007~1e$oCcFS8neI|hJl{-P!B1ZZ9hpmq0)X0i`JwE&>$+E?>%_LC6RbVIkUx0b+_+BaR3cnT7Zv!AJxW zizFb)h!jyGOOZ85F;a?DAXP{m@;!0_IfqH8(HlgRxt7s3}k3K`kFu>>-2Q$QMFfPW!La{h336o>X zu_CMttHv6zR;&ZNiS=X8v3CR#fknUxHUxJ0uoBa_M6WNWeqIg~6QE69c9o#eyhGvpiOA@W-aonk<7r1(?fC{oI5N*U!4 zfg=2N-7=cNnjjOr{yriy6mMFgG#l znCF=fnQv8CDz++o6_Lscl}eQ+l^ZHARH>?_s@|##Rr6KLRFA1%Q+=*RRWnoLsR`7U zt5vFIcfW3@?wFpwUVxrVZ>QdQz32KIeJ}k~{cZZE^+ya? z2D1z#2HOnI7(B%_ac?{wFUQ;QQA1tBKtrWrm0_3Rgps+?Jfqb{jYbcQX~taRB;#$y zZN{S}1|}gUOHJxc?wV3fxuz+mJ4`!F$IZ;mqRrNsHJd##*D~ju=bP7?-?v~|cv>vB zsJ6IeNwVZxrdjT`yl#bBIa#GxRa#xMMy;K#CDyyGyQdMSxlWT#tDe?p!?5wT$+oGt z8L;Kp2HUQ-ZMJ=3XJQv;x5ci*?vuTfeY$;({XGW_huIFR9a(?@3)XSs8O^N5RyOM=TTmp(3=8^+zpz2r)C z^>JO{deZfso3oq3?Wo(Y?l$ge?uXo;%ru`Vo>?<<(8I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ZGdF1K$3E%e~4LaI(jC-u%2h$&R z9cLXcYC@Xwnns&bn)_Q~Te?roKGD|d-g^8;+aC{{G(1^(O7m37Y1-+6)01cN&y1aw zoqc{T`P^XJqPBbIW6s}d4{z_f5Om?vMgNQEJG?v2T=KYd^0M3I6IZxbny)%vZR&LD zJpPl@Psh8QyPB@KTx+@RdcC!KX7}kEo;S|j^u2lU7XQ}Oo;f|;z4Ll+_r>@1-xl3| zawq-H%e&ckC+@AhPrP6BKT#_XdT7&;F71j}Joy zkC~6lh7E@6o;W@^IpRNZ{ptLtL(gQ-CY~4mqW;US7Zxvm_|@yz&e53Bp_lTPlfP|z zrTyx_>lv@x#=^!PzR7qqF<$gm`|ZJZ+;<)Cqu&ot2z=0000WV@Og>004R=004l4008;_004mL004C`008P>0026e000+nl3&F} z0001jNklN$pM613aU- z6Iy8`b>D$+T-o 1) { - offTex = FungusEditorResources.texChoiceNodeOff; - onTex = FungusEditorResources.texChoiceNodeOn; + offTex = FungusEditorResources.ChoiceNodeOff; + onTex = FungusEditorResources.ChoiceNodeOn; defaultColor = FungusConstants.DefaultChoiceBlockTint; } else { - offTex = FungusEditorResources.texProcessNodeOff; - onTex = FungusEditorResources.texProcessNodeOn; + offTex = FungusEditorResources.ProcessNodeOff; + onTex = FungusEditorResources.ProcessNodeOn; defaultColor = FungusConstants.DefaultProcessBlockTint; } } diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs index 9c35cc05..dad69a76 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs @@ -1,149 +1,76 @@ // This code is part of the Fungus library (http://fungusgames.com) maintained by Chris Gregan (http://twitter.com/gofungus). // It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) -using UnityEngine; +using UnityEngine; using UnityEditor; +using System.IO; using System; +using System.Linq; +using System.Collections.Generic; -namespace Fungus.EditorUtils +namespace Fungus.EditorUtils { - internal static class FungusEditorResources - { + internal static partial class FungusEditorResources + { + private static Dictionary textures = new Dictionary(); + + static FungusEditorResources() + { + LoadResourceAssets(); + } - static FungusEditorResources() { - GenerateSpecialTextures(); - LoadResourceAssets(); - } + private static void LoadResourceAssets() + { + // Get first folder named "Fungus Editor Resources" + var rootGuid = AssetDatabase.FindAssets("\"Fungus Editor Resources\"")[0]; + var root = AssetDatabase.GUIDToAssetPath(rootGuid); + var guids = AssetDatabase.FindAssets("t:Texture2D", new string[] { root }); + var paths = guids.Select(guid => AssetDatabase.GUIDToAssetPath(guid)).OrderBy(path => path.ToLower().Contains("/pro/")); - private enum ResourceName - { - command_background = 0, - choice_node_off, - choice_node_on, - process_node_off, - process_node_on, - event_node_off, - event_node_on, - play_big, - play_small - } - - private static string[] s_LightSkin = { - "command_background", - "choice_node_off", - "choice_node_on", - "process_node_off", - "process_node_on", - "event_node_off", - "event_node_on", - "play_big", - "play_small" - }; + foreach (var path in paths) + { + if (path.ToLower().Contains("/pro/") && !EditorGUIUtility.isProSkin) + { + return; + } + var texture = AssetDatabase.LoadAssetAtPath(path); + textures[texture.name] = texture; + } + } - private static string[] s_DarkSkin = { - "command_background", - "choice_node_off", - "choice_node_on", - "process_node_off", - "process_node_on", - "event_node_off", - "event_node_on", - "play_big", - "play_small" - }; + [MenuItem("Tools/Fungus/Utilities/Update Editor Resources Script")] + private static void GenerateResourcesScript() + { + var guid = AssetDatabase.FindAssets("FungusEditorResources t:MonoScript")[0]; + var relativePath = AssetDatabase.GUIDToAssetPath(guid).Replace("FungusEditorResources.cs", "FungusEditorResourcesGenerated.cs"); + var absolutePath = Application.dataPath + relativePath.Substring("Assets".Length);// + + using (var writer = new StreamWriter(absolutePath)) + { + writer.WriteLine("// This code is part of the Fungus library (http://fungusgames.com) maintained by Chris Gregan (http://twitter.com/gofungus)."); + writer.WriteLine("// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE)"); + writer.WriteLine(""); + writer.WriteLine("using UnityEngine;"); + writer.WriteLine(""); + writer.WriteLine("namespace Fungus.EditorUtils"); + writer.WriteLine("{"); + writer.WriteLine("\tinternal static partial class FungusEditorResources"); + writer.WriteLine("\t{"); - public static Texture2D texCommandBackground - { - get { return s_Cached[(int)ResourceName.command_background]; } - } + foreach (var pair in textures) + { + var name = pair.Key; + var pascalCase = string.Join("", name.Split(new [] { '_' }, StringSplitOptions.RemoveEmptyEntries).Select( + s => s.Substring(0, 1).ToUpper() + s.Substring(1)).ToArray() + ); + writer.WriteLine("\t\tpublic static Texture2D " + pascalCase + " { get { return textures[\"" + name + "\"]; } }"); + } - public static Texture2D texEventNodeOn - { - get { return s_Cached[(int)ResourceName.event_node_on]; } - } - - public static Texture2D texEventNodeOff - { - get { return s_Cached[(int)ResourceName.event_node_off]; } - } + writer.WriteLine("\t}"); + writer.WriteLine("}"); + } - public static Texture2D texProcessNodeOn - { - get { return s_Cached[(int)ResourceName.process_node_on]; } - } - - public static Texture2D texProcessNodeOff - { - get { return s_Cached[(int)ResourceName.process_node_off]; } - } - - public static Texture2D texChoiceNodeOn - { - get { return s_Cached[(int)ResourceName.choice_node_on]; } - } - - public static Texture2D texChoiceNodeOff - { - get { return s_Cached[(int)ResourceName.choice_node_off]; } - } - - public static Texture2D texPlayBig - { - get { return s_Cached[(int)ResourceName.play_big]; } - } - - public static Texture2D texPlaySmall - { - get { return s_Cached[(int)ResourceName.play_small]; } - } - - public static Texture2D texItemSplitter { get; private set; } - - private static void GenerateSpecialTextures() - { - var splitterColor = EditorGUIUtility.isProSkin - ? new Color(1f, 1f, 1f, 0.14f) - : new Color(0.59f, 0.59f, 0.59f, 0.55f) - ; - texItemSplitter = CreatePixelTexture("(Generated) Item Splitter", splitterColor); - } - - public static Texture2D CreatePixelTexture(string name, Color color) - { - var tex = new Texture2D(1, 1, TextureFormat.ARGB32, false, true); - tex.name = name; - tex.hideFlags = HideFlags.HideAndDontSave; - tex.filterMode = FilterMode.Point; - tex.SetPixel(0, 0, color); - tex.Apply(); - return tex; - } - - private static Texture2D[] s_Cached; - - public static void LoadResourceAssets() - { - var skin = EditorGUIUtility.isProSkin ? s_DarkSkin : s_LightSkin; - s_Cached = new Texture2D[skin.Length]; - - for (int i = 0; i < s_Cached.Length; ++i) - { - s_Cached[i] = Resources.Load("Textures/" + skin[i]) as Texture2D; - } - - s_LightSkin = null; - s_DarkSkin = null; - } - - private static void GetImageSize(byte[] imageData, out int width, out int height) - { - width = ReadInt(imageData, 3 + 15); - height = ReadInt(imageData, 3 + 15 + 2 + 2); - } - - private static int ReadInt(byte[] imageData, int offset) - { - return (imageData[offset] << 8) | imageData[offset + 1]; - } - } -} \ No newline at end of file + AssetDatabase.ImportAsset(relativePath); + } + } +} diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs new file mode 100644 index 00000000..d8f36b8b --- /dev/null +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs @@ -0,0 +1,26 @@ +// This code is part of the Fungus library (http://fungusgames.com) maintained by Chris Gregan (http://twitter.com/gofungus). +// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE) + +using UnityEngine; + +namespace Fungus.EditorUtils +{ + internal static partial class FungusEditorResources + { + public static Texture2D Add { get { return textures["add"]; } } + public static Texture2D AddSmall { get { return textures["add_small"]; } } + public static Texture2D Delete { get { return textures["delete"]; } } + public static Texture2D Down { get { return textures["down"]; } } + public static Texture2D Duplicate { get { return textures["duplicate"]; } } + public static Texture2D Up { get { return textures["up"]; } } + public static Texture2D ChoiceNodeOff { get { return textures["choice_node_off"]; } } + public static Texture2D ChoiceNodeOn { get { return textures["choice_node_on"]; } } + public static Texture2D CommandBackground { get { return textures["command_background"]; } } + public static Texture2D EventNodeOff { get { return textures["event_node_off"]; } } + public static Texture2D EventNodeOn { get { return textures["event_node_on"]; } } + public static Texture2D PlayBig { get { return textures["play_big"]; } } + public static Texture2D PlaySmall { get { return textures["play_small"]; } } + public static Texture2D ProcessNodeOff { get { return textures["process_node_off"]; } } + public static Texture2D ProcessNodeOn { get { return textures["process_node_on"]; } } + } +} diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs.meta b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs.meta new file mode 100644 index 00000000..6d6fd014 --- /dev/null +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs.meta @@ -0,0 +1,12 @@ +fileFormatVersion: 2 +guid: f5119f9bdde234916bed657bdc751f76 +timeCreated: 1478502142 +licenseType: Free +MonoImporter: + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: From 248096bbfe947c1f4962b5363b5982c1e3b48998 Mon Sep 17 00:00:00 2001 From: Zach Vinless Date: Mon, 7 Nov 2016 15:06:05 -0800 Subject: [PATCH 2/5] Fixed compatibility with Unity 5.0 -Changed generic LoadAssetAtPath to non-generic version -Added GetTexture wrapper function to avoid key not found errors when moving things around --- .../Scripts/Editor/FungusEditorResources.cs | 21 +++++++++---- .../Editor/FungusEditorResourcesGenerated.cs | 30 +++++++++---------- 2 files changed, 31 insertions(+), 20 deletions(-) diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs index dad69a76..7e80874e 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs @@ -3,8 +3,8 @@ using UnityEngine; using UnityEditor; -using System.IO; using System; +using System.IO; using System.Linq; using System.Collections.Generic; @@ -24,7 +24,7 @@ namespace Fungus.EditorUtils // Get first folder named "Fungus Editor Resources" var rootGuid = AssetDatabase.FindAssets("\"Fungus Editor Resources\"")[0]; var root = AssetDatabase.GUIDToAssetPath(rootGuid); - var guids = AssetDatabase.FindAssets("t:Texture2D", new string[] { root }); + var guids = AssetDatabase.FindAssets("t:Texture2D", new [] { root }); var paths = guids.Select(guid => AssetDatabase.GUIDToAssetPath(guid)).OrderBy(path => path.ToLower().Contains("/pro/")); foreach (var path in paths) @@ -33,7 +33,7 @@ namespace Fungus.EditorUtils { return; } - var texture = AssetDatabase.LoadAssetAtPath(path); + var texture = AssetDatabase.LoadAssetAtPath(path, typeof(Texture2D)) as Texture2D; textures[texture.name] = texture; } } @@ -43,7 +43,7 @@ namespace Fungus.EditorUtils { var guid = AssetDatabase.FindAssets("FungusEditorResources t:MonoScript")[0]; var relativePath = AssetDatabase.GUIDToAssetPath(guid).Replace("FungusEditorResources.cs", "FungusEditorResourcesGenerated.cs"); - var absolutePath = Application.dataPath + relativePath.Substring("Assets".Length);// + var absolutePath = Application.dataPath + relativePath.Substring("Assets".Length); using (var writer = new StreamWriter(absolutePath)) { @@ -63,7 +63,7 @@ namespace Fungus.EditorUtils var pascalCase = string.Join("", name.Split(new [] { '_' }, StringSplitOptions.RemoveEmptyEntries).Select( s => s.Substring(0, 1).ToUpper() + s.Substring(1)).ToArray() ); - writer.WriteLine("\t\tpublic static Texture2D " + pascalCase + " { get { return textures[\"" + name + "\"]; } }"); + writer.WriteLine("\t\tpublic static Texture2D " + pascalCase + " { get { return GetTexture(\"" + name + "\"); } }"); } writer.WriteLine("\t}"); @@ -72,5 +72,16 @@ namespace Fungus.EditorUtils AssetDatabase.ImportAsset(relativePath); } + + private static Texture2D GetTexture(string name) + { + Texture2D texture; + if (!textures.TryGetValue(name, out texture)) + { + Debug.LogWarning("Texture \"" + name + "\" not found!"); + } + + return texture; + } } } diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs index d8f36b8b..e79da844 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs @@ -7,20 +7,20 @@ namespace Fungus.EditorUtils { internal static partial class FungusEditorResources { - public static Texture2D Add { get { return textures["add"]; } } - public static Texture2D AddSmall { get { return textures["add_small"]; } } - public static Texture2D Delete { get { return textures["delete"]; } } - public static Texture2D Down { get { return textures["down"]; } } - public static Texture2D Duplicate { get { return textures["duplicate"]; } } - public static Texture2D Up { get { return textures["up"]; } } - public static Texture2D ChoiceNodeOff { get { return textures["choice_node_off"]; } } - public static Texture2D ChoiceNodeOn { get { return textures["choice_node_on"]; } } - public static Texture2D CommandBackground { get { return textures["command_background"]; } } - public static Texture2D EventNodeOff { get { return textures["event_node_off"]; } } - public static Texture2D EventNodeOn { get { return textures["event_node_on"]; } } - public static Texture2D PlayBig { get { return textures["play_big"]; } } - public static Texture2D PlaySmall { get { return textures["play_small"]; } } - public static Texture2D ProcessNodeOff { get { return textures["process_node_off"]; } } - public static Texture2D ProcessNodeOn { get { return textures["process_node_on"]; } } + public static Texture2D Add { get { return GetTexture("add"); } } + public static Texture2D AddSmall { get { return GetTexture("add_small"); } } + public static Texture2D Delete { get { return GetTexture("delete"); } } + public static Texture2D Down { get { return GetTexture("down"); } } + public static Texture2D Duplicate { get { return GetTexture("duplicate"); } } + public static Texture2D Up { get { return GetTexture("up"); } } + public static Texture2D ChoiceNodeOff { get { return GetTexture("choice_node_off"); } } + public static Texture2D ChoiceNodeOn { get { return GetTexture("choice_node_on"); } } + public static Texture2D CommandBackground { get { return GetTexture("command_background"); } } + public static Texture2D EventNodeOff { get { return GetTexture("event_node_off"); } } + public static Texture2D EventNodeOn { get { return GetTexture("event_node_on"); } } + public static Texture2D PlayBig { get { return GetTexture("play_big"); } } + public static Texture2D PlaySmall { get { return GetTexture("play_small"); } } + public static Texture2D ProcessNodeOff { get { return GetTexture("process_node_off"); } } + public static Texture2D ProcessNodeOn { get { return GetTexture("process_node_on"); } } } } From 3d431cc591184700635991204468b00eedc9dd99 Mon Sep 17 00:00:00 2001 From: Zach Vinless Date: Wed, 9 Nov 2016 23:24:53 -0800 Subject: [PATCH 3/5] Added generation of texture names to load directly -Added texture names array to generated script. These files all specifically loaded rather than looping through a particular folder. -Renamed some functions for better clarity --- .../Scripts/Editor/FungusEditorResources.cs | 37 ++++++++++++++++--- .../Editor/FungusEditorResourcesGenerated.cs | 18 +++++++++ 2 files changed, 50 insertions(+), 5 deletions(-) diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs index 7e80874e..5ce80df0 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs @@ -16,17 +16,32 @@ namespace Fungus.EditorUtils static FungusEditorResources() { - LoadResourceAssets(); + LoadTexturesFromNames(); } - private static void LoadResourceAssets() + private static void LoadTexturesFromNames() + { + var baseDirectories = AssetDatabase.FindAssets("\"Fungus Editor Resources\"").Select( + guid => AssetDatabase.GUIDToAssetPath(guid) + ).ToArray(); + + foreach (var name in resourceNames) + { + LoadTexturesFromGUIDs(AssetDatabase.FindAssets(name + " t:Texture2D", baseDirectories)); + } + } + + private static void LoadAllTexturesInFolder() { - // Get first folder named "Fungus Editor Resources" var rootGuid = AssetDatabase.FindAssets("\"Fungus Editor Resources\"")[0]; var root = AssetDatabase.GUIDToAssetPath(rootGuid); - var guids = AssetDatabase.FindAssets("t:Texture2D", new [] { root }); - var paths = guids.Select(guid => AssetDatabase.GUIDToAssetPath(guid)).OrderBy(path => path.ToLower().Contains("/pro/")); + LoadTexturesFromGUIDs(AssetDatabase.FindAssets("t:Texture2D", new [] { root })); + } + private static void LoadTexturesFromGUIDs(string[] guids) + { + var paths = guids.Select(guid => AssetDatabase.GUIDToAssetPath(guid)).OrderBy(path => path.ToLower().Contains("/pro/")); + foreach (var path in paths) { if (path.ToLower().Contains("/pro/") && !EditorGUIUtility.isProSkin) @@ -41,6 +56,9 @@ namespace Fungus.EditorUtils [MenuItem("Tools/Fungus/Utilities/Update Editor Resources Script")] private static void GenerateResourcesScript() { + textures.Clear(); + LoadAllTexturesInFolder(); + var guid = AssetDatabase.FindAssets("FungusEditorResources t:MonoScript")[0]; var relativePath = AssetDatabase.GUIDToAssetPath(guid).Replace("FungusEditorResources.cs", "FungusEditorResourcesGenerated.cs"); var absolutePath = Application.dataPath + relativePath.Substring("Assets".Length); @@ -56,6 +74,15 @@ namespace Fungus.EditorUtils writer.WriteLine("{"); writer.WriteLine("\tinternal static partial class FungusEditorResources"); writer.WriteLine("\t{"); + writer.WriteLine("\t\tprivate static readonly string[] resourceNames = new [] {"); + + foreach (var pair in textures) + { + writer.WriteLine("\t\t\t\"" + pair.Key + "\","); + } + + writer.WriteLine("\t\t};"); + writer.WriteLine(""); foreach (var pair in textures) { diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs index e79da844..7dd62e34 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs @@ -7,6 +7,24 @@ namespace Fungus.EditorUtils { internal static partial class FungusEditorResources { + private static readonly string[] resourceNames = new [] { + "add", + "add_small", + "delete", + "down", + "duplicate", + "up", + "choice_node_off", + "choice_node_on", + "command_background", + "event_node_off", + "event_node_on", + "play_big", + "play_small", + "process_node_off", + "process_node_on", + }; + public static Texture2D Add { get { return GetTexture("add"); } } public static Texture2D AddSmall { get { return GetTexture("add_small"); } } public static Texture2D Delete { get { return GetTexture("delete"); } } From 5f677602c5540f84858b114b0cc034158d49453a Mon Sep 17 00:00:00 2001 From: Zach Vinless Date: Wed, 9 Nov 2016 23:46:10 -0800 Subject: [PATCH 4/5] Converted tabs to spaces in new files --- .../Fungus/Scripts/Editor/FlowchartWindow.cs | 2 +- .../Scripts/Editor/FungusEditorResources.cs | 182 +++++++++--------- .../Editor/FungusEditorResourcesGenerated.cs | 70 +++---- 3 files changed, 127 insertions(+), 127 deletions(-) diff --git a/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs b/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs index ed4e1463..c11ac1bd 100644 --- a/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs +++ b/Assets/Fungus/Scripts/Editor/FlowchartWindow.cs @@ -473,7 +473,7 @@ namespace Fungus.EditorUtils GUI.color = new Color(1f, 1f, 1f, alpha); } - if (GUI.Button(rect, FungusEditorResources.PlayBig as Texture, new GUIStyle())) + if (GUI.Button(rect, FungusEditorResources.PlayBig, new GUIStyle())) { SelectBlock(flowchart, b); } diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs index 5ce80df0..245de98a 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs @@ -10,105 +10,105 @@ using System.Collections.Generic; namespace Fungus.EditorUtils { - internal static partial class FungusEditorResources - { - private static Dictionary textures = new Dictionary(); - - static FungusEditorResources() - { - LoadTexturesFromNames(); - } + internal static partial class FungusEditorResources + { + private static Dictionary textures = new Dictionary(); + + static FungusEditorResources() + { + LoadTexturesFromNames(); + } - private static void LoadTexturesFromNames() - { - var baseDirectories = AssetDatabase.FindAssets("\"Fungus Editor Resources\"").Select( - guid => AssetDatabase.GUIDToAssetPath(guid) - ).ToArray(); - - foreach (var name in resourceNames) - { - LoadTexturesFromGUIDs(AssetDatabase.FindAssets(name + " t:Texture2D", baseDirectories)); - } - } + private static void LoadTexturesFromNames() + { + var baseDirectories = AssetDatabase.FindAssets("\"Fungus Editor Resources\"").Select( + guid => AssetDatabase.GUIDToAssetPath(guid) + ).ToArray(); + + foreach (var name in resourceNames) + { + LoadTexturesFromGUIDs(AssetDatabase.FindAssets(name + " t:Texture2D", baseDirectories)); + } + } - private static void LoadAllTexturesInFolder() - { - var rootGuid = AssetDatabase.FindAssets("\"Fungus Editor Resources\"")[0]; - var root = AssetDatabase.GUIDToAssetPath(rootGuid); - LoadTexturesFromGUIDs(AssetDatabase.FindAssets("t:Texture2D", new [] { root })); - } + private static void LoadAllTexturesInFolder() + { + var rootGuid = AssetDatabase.FindAssets("\"Fungus Editor Resources\"")[0]; + var root = AssetDatabase.GUIDToAssetPath(rootGuid); + LoadTexturesFromGUIDs(AssetDatabase.FindAssets("t:Texture2D", new [] { root })); + } - private static void LoadTexturesFromGUIDs(string[] guids) - { - var paths = guids.Select(guid => AssetDatabase.GUIDToAssetPath(guid)).OrderBy(path => path.ToLower().Contains("/pro/")); - - foreach (var path in paths) - { - if (path.ToLower().Contains("/pro/") && !EditorGUIUtility.isProSkin) - { - return; - } - var texture = AssetDatabase.LoadAssetAtPath(path, typeof(Texture2D)) as Texture2D; - textures[texture.name] = texture; - } - } + private static void LoadTexturesFromGUIDs(string[] guids) + { + var paths = guids.Select(guid => AssetDatabase.GUIDToAssetPath(guid)).OrderBy(path => path.ToLower().Contains("/pro/")); + + foreach (var path in paths) + { + if (path.ToLower().Contains("/pro/") && !EditorGUIUtility.isProSkin) + { + return; + } + var texture = AssetDatabase.LoadAssetAtPath(path, typeof(Texture2D)) as Texture2D; + textures[texture.name] = texture; + } + } - [MenuItem("Tools/Fungus/Utilities/Update Editor Resources Script")] - private static void GenerateResourcesScript() - { - textures.Clear(); - LoadAllTexturesInFolder(); + [MenuItem("Tools/Fungus/Utilities/Update Editor Resources Script")] + private static void GenerateResourcesScript() + { + textures.Clear(); + LoadAllTexturesInFolder(); - var guid = AssetDatabase.FindAssets("FungusEditorResources t:MonoScript")[0]; - var relativePath = AssetDatabase.GUIDToAssetPath(guid).Replace("FungusEditorResources.cs", "FungusEditorResourcesGenerated.cs"); - var absolutePath = Application.dataPath + relativePath.Substring("Assets".Length); - - using (var writer = new StreamWriter(absolutePath)) - { - writer.WriteLine("// This code is part of the Fungus library (http://fungusgames.com) maintained by Chris Gregan (http://twitter.com/gofungus)."); - writer.WriteLine("// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE)"); - writer.WriteLine(""); - writer.WriteLine("using UnityEngine;"); - writer.WriteLine(""); - writer.WriteLine("namespace Fungus.EditorUtils"); - writer.WriteLine("{"); - writer.WriteLine("\tinternal static partial class FungusEditorResources"); - writer.WriteLine("\t{"); - writer.WriteLine("\t\tprivate static readonly string[] resourceNames = new [] {"); - - foreach (var pair in textures) - { - writer.WriteLine("\t\t\t\"" + pair.Key + "\","); - } + var guid = AssetDatabase.FindAssets("FungusEditorResources t:MonoScript")[0]; + var relativePath = AssetDatabase.GUIDToAssetPath(guid).Replace("FungusEditorResources.cs", "FungusEditorResourcesGenerated.cs"); + var absolutePath = Application.dataPath + relativePath.Substring("Assets".Length); + + using (var writer = new StreamWriter(absolutePath)) + { + writer.WriteLine("// This code is part of the Fungus library (http://fungusgames.com) maintained by Chris Gregan (http://twitter.com/gofungus)."); + writer.WriteLine("// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE)"); + writer.WriteLine(""); + writer.WriteLine("using UnityEngine;"); + writer.WriteLine(""); + writer.WriteLine("namespace Fungus.EditorUtils"); + writer.WriteLine("{"); + writer.WriteLine(" internal static partial class FungusEditorResources"); + writer.WriteLine(" {"); + writer.WriteLine(" private static readonly string[] resourceNames = new [] {"); + + foreach (var pair in textures) + { + writer.WriteLine(" \"" + pair.Key + "\","); + } - writer.WriteLine("\t\t};"); - writer.WriteLine(""); + writer.WriteLine(" };"); + writer.WriteLine(""); - foreach (var pair in textures) - { - var name = pair.Key; - var pascalCase = string.Join("", name.Split(new [] { '_' }, StringSplitOptions.RemoveEmptyEntries).Select( - s => s.Substring(0, 1).ToUpper() + s.Substring(1)).ToArray() - ); - writer.WriteLine("\t\tpublic static Texture2D " + pascalCase + " { get { return GetTexture(\"" + name + "\"); } }"); - } + foreach (var pair in textures) + { + var name = pair.Key; + var pascalCase = string.Join("", name.Split(new [] { '_' }, StringSplitOptions.RemoveEmptyEntries).Select( + s => s.Substring(0, 1).ToUpper() + s.Substring(1)).ToArray() + ); + writer.WriteLine(" public static Texture2D " + pascalCase + " { get { return GetTexture(\"" + name + "\"); } }"); + } - writer.WriteLine("\t}"); - writer.WriteLine("}"); - } + writer.WriteLine(" }"); + writer.WriteLine("}"); + } - AssetDatabase.ImportAsset(relativePath); - } + AssetDatabase.ImportAsset(relativePath); + } - private static Texture2D GetTexture(string name) - { - Texture2D texture; - if (!textures.TryGetValue(name, out texture)) - { - Debug.LogWarning("Texture \"" + name + "\" not found!"); - } - - return texture; - } - } + private static Texture2D GetTexture(string name) + { + Texture2D texture; + if (!textures.TryGetValue(name, out texture)) + { + Debug.LogWarning("Texture \"" + name + "\" not found!"); + } + + return texture; + } + } } diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs index 7dd62e34..e2eab920 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResourcesGenerated.cs @@ -5,40 +5,40 @@ using UnityEngine; namespace Fungus.EditorUtils { - internal static partial class FungusEditorResources - { - private static readonly string[] resourceNames = new [] { - "add", - "add_small", - "delete", - "down", - "duplicate", - "up", - "choice_node_off", - "choice_node_on", - "command_background", - "event_node_off", - "event_node_on", - "play_big", - "play_small", - "process_node_off", - "process_node_on", - }; + internal static partial class FungusEditorResources + { + private static readonly string[] resourceNames = new [] { + "add", + "add_small", + "delete", + "down", + "duplicate", + "up", + "choice_node_off", + "choice_node_on", + "command_background", + "event_node_off", + "event_node_on", + "play_big", + "play_small", + "process_node_off", + "process_node_on", + }; - public static Texture2D Add { get { return GetTexture("add"); } } - public static Texture2D AddSmall { get { return GetTexture("add_small"); } } - public static Texture2D Delete { get { return GetTexture("delete"); } } - public static Texture2D Down { get { return GetTexture("down"); } } - public static Texture2D Duplicate { get { return GetTexture("duplicate"); } } - public static Texture2D Up { get { return GetTexture("up"); } } - public static Texture2D ChoiceNodeOff { get { return GetTexture("choice_node_off"); } } - public static Texture2D ChoiceNodeOn { get { return GetTexture("choice_node_on"); } } - public static Texture2D CommandBackground { get { return GetTexture("command_background"); } } - public static Texture2D EventNodeOff { get { return GetTexture("event_node_off"); } } - public static Texture2D EventNodeOn { get { return GetTexture("event_node_on"); } } - public static Texture2D PlayBig { get { return GetTexture("play_big"); } } - public static Texture2D PlaySmall { get { return GetTexture("play_small"); } } - public static Texture2D ProcessNodeOff { get { return GetTexture("process_node_off"); } } - public static Texture2D ProcessNodeOn { get { return GetTexture("process_node_on"); } } - } + public static Texture2D Add { get { return GetTexture("add"); } } + public static Texture2D AddSmall { get { return GetTexture("add_small"); } } + public static Texture2D Delete { get { return GetTexture("delete"); } } + public static Texture2D Down { get { return GetTexture("down"); } } + public static Texture2D Duplicate { get { return GetTexture("duplicate"); } } + public static Texture2D Up { get { return GetTexture("up"); } } + public static Texture2D ChoiceNodeOff { get { return GetTexture("choice_node_off"); } } + public static Texture2D ChoiceNodeOn { get { return GetTexture("choice_node_on"); } } + public static Texture2D CommandBackground { get { return GetTexture("command_background"); } } + public static Texture2D EventNodeOff { get { return GetTexture("event_node_off"); } } + public static Texture2D EventNodeOn { get { return GetTexture("event_node_on"); } } + public static Texture2D PlayBig { get { return GetTexture("play_big"); } } + public static Texture2D PlaySmall { get { return GetTexture("play_small"); } } + public static Texture2D ProcessNodeOff { get { return GetTexture("process_node_off"); } } + public static Texture2D ProcessNodeOn { get { return GetTexture("process_node_on"); } } + } } From 344696407de0a07e54dd01a3573efe5aeabf1b8c Mon Sep 17 00:00:00 2001 From: Zach Vinless Date: Thu, 10 Nov 2016 08:38:49 -0800 Subject: [PATCH 5/5] Renamed "Fungus Editor Resources" to "EditorResources" --- ...s Editor Resources.meta => EditorResources.meta} | 0 .../Icons.meta | 0 .../Icons/Pro.meta | 0 .../Icons/Pro/add.png | Bin .../Icons/Pro/add.png.meta | 0 .../Icons/Pro/add_small.png | Bin .../Icons/Pro/add_small.png.meta | 0 .../Icons/Pro/delete.png | Bin .../Icons/Pro/delete.png.meta | 0 .../Icons/Pro/down.png | Bin .../Icons/Pro/down.png.meta | 0 .../Icons/Pro/duplicate.png | Bin .../Icons/Pro/duplicate.png.meta | 0 .../Icons/Pro/up.png | Bin .../Icons/Pro/up.png.meta | 0 .../Icons/add.png | Bin .../Icons/add.png.meta | 0 .../Icons/add_small.png | Bin .../Icons/add_small.png.meta | 0 .../Icons/delete.png | Bin .../Icons/delete.png.meta | 0 .../Icons/down.png | Bin .../Icons/down.png.meta | 0 .../Icons/duplicate.png | Bin .../Icons/duplicate.png.meta | 0 .../Icons/up.png | Bin .../Icons/up.png.meta | 0 .../Textures.meta | 0 .../Textures/choice_node_off.png | Bin .../Textures/choice_node_off.png.meta | 0 .../Textures/choice_node_on.png | Bin .../Textures/choice_node_on.png.meta | 0 .../Textures/command_background.png | Bin .../Textures/command_background.png.meta | 0 .../Textures/event_node_off.png | Bin .../Textures/event_node_off.png.meta | 0 .../Textures/event_node_on.png | Bin .../Textures/event_node_on.png.meta | 0 .../Textures/play_big.png | Bin .../Textures/play_big.png.meta | 0 .../Textures/play_small.png | Bin .../Textures/play_small.png.meta | 0 .../Textures/process_node_off.png | Bin .../Textures/process_node_off.png.meta | 0 .../Textures/process_node_on.png | Bin .../Textures/process_node_on.png.meta | 0 .../Fungus/Scripts/Editor/FungusEditorResources.cs | 5 +++-- 47 files changed, 3 insertions(+), 2 deletions(-) rename Assets/Fungus/{Fungus Editor Resources.meta => EditorResources.meta} (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/add.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/add.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/add_small.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/add_small.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/delete.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/delete.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/down.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/down.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/duplicate.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/duplicate.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/up.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/Pro/up.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/add.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/add.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/add_small.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/add_small.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/delete.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/delete.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/down.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/down.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/duplicate.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/duplicate.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/up.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Icons/up.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/choice_node_off.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/choice_node_off.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/choice_node_on.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/choice_node_on.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/command_background.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/command_background.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/event_node_off.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/event_node_off.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/event_node_on.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/event_node_on.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/play_big.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/play_big.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/play_small.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/play_small.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/process_node_off.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/process_node_off.png.meta (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/process_node_on.png (100%) rename Assets/Fungus/{Fungus Editor Resources => EditorResources}/Textures/process_node_on.png.meta (100%) diff --git a/Assets/Fungus/Fungus Editor Resources.meta b/Assets/Fungus/EditorResources.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources.meta rename to Assets/Fungus/EditorResources.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons.meta b/Assets/Fungus/EditorResources/Icons.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons.meta rename to Assets/Fungus/EditorResources/Icons.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro.meta b/Assets/Fungus/EditorResources/Icons/Pro.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro.meta rename to Assets/Fungus/EditorResources/Icons/Pro.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png b/Assets/Fungus/EditorResources/Icons/Pro/add.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png rename to Assets/Fungus/EditorResources/Icons/Pro/add.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/add.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/add.png.meta rename to Assets/Fungus/EditorResources/Icons/Pro/add.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add_small.png b/Assets/Fungus/EditorResources/Icons/Pro/add_small.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/add_small.png rename to Assets/Fungus/EditorResources/Icons/Pro/add_small.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/add_small.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/add_small.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/add_small.png.meta rename to Assets/Fungus/EditorResources/Icons/Pro/add_small.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png b/Assets/Fungus/EditorResources/Icons/Pro/delete.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png rename to Assets/Fungus/EditorResources/Icons/Pro/delete.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/delete.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/delete.png.meta rename to Assets/Fungus/EditorResources/Icons/Pro/delete.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png b/Assets/Fungus/EditorResources/Icons/Pro/down.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png rename to Assets/Fungus/EditorResources/Icons/Pro/down.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/down.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/down.png.meta rename to Assets/Fungus/EditorResources/Icons/Pro/down.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png b/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png rename to Assets/Fungus/EditorResources/Icons/Pro/duplicate.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/duplicate.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/duplicate.png.meta rename to Assets/Fungus/EditorResources/Icons/Pro/duplicate.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png b/Assets/Fungus/EditorResources/Icons/Pro/up.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png rename to Assets/Fungus/EditorResources/Icons/Pro/up.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png.meta b/Assets/Fungus/EditorResources/Icons/Pro/up.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/Pro/up.png.meta rename to Assets/Fungus/EditorResources/Icons/Pro/up.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/add.png b/Assets/Fungus/EditorResources/Icons/add.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/add.png rename to Assets/Fungus/EditorResources/Icons/add.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/add.png.meta b/Assets/Fungus/EditorResources/Icons/add.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/add.png.meta rename to Assets/Fungus/EditorResources/Icons/add.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/add_small.png b/Assets/Fungus/EditorResources/Icons/add_small.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/add_small.png rename to Assets/Fungus/EditorResources/Icons/add_small.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/add_small.png.meta b/Assets/Fungus/EditorResources/Icons/add_small.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/add_small.png.meta rename to Assets/Fungus/EditorResources/Icons/add_small.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/delete.png b/Assets/Fungus/EditorResources/Icons/delete.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/delete.png rename to Assets/Fungus/EditorResources/Icons/delete.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/delete.png.meta b/Assets/Fungus/EditorResources/Icons/delete.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/delete.png.meta rename to Assets/Fungus/EditorResources/Icons/delete.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/down.png b/Assets/Fungus/EditorResources/Icons/down.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/down.png rename to Assets/Fungus/EditorResources/Icons/down.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/down.png.meta b/Assets/Fungus/EditorResources/Icons/down.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/down.png.meta rename to Assets/Fungus/EditorResources/Icons/down.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png b/Assets/Fungus/EditorResources/Icons/duplicate.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png rename to Assets/Fungus/EditorResources/Icons/duplicate.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png.meta b/Assets/Fungus/EditorResources/Icons/duplicate.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/duplicate.png.meta rename to Assets/Fungus/EditorResources/Icons/duplicate.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/up.png b/Assets/Fungus/EditorResources/Icons/up.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/up.png rename to Assets/Fungus/EditorResources/Icons/up.png diff --git a/Assets/Fungus/Fungus Editor Resources/Icons/up.png.meta b/Assets/Fungus/EditorResources/Icons/up.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Icons/up.png.meta rename to Assets/Fungus/EditorResources/Icons/up.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures.meta b/Assets/Fungus/EditorResources/Textures.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures.meta rename to Assets/Fungus/EditorResources/Textures.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png b/Assets/Fungus/EditorResources/Textures/choice_node_off.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png rename to Assets/Fungus/EditorResources/Textures/choice_node_off.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png.meta b/Assets/Fungus/EditorResources/Textures/choice_node_off.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/choice_node_off.png.meta rename to Assets/Fungus/EditorResources/Textures/choice_node_off.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png b/Assets/Fungus/EditorResources/Textures/choice_node_on.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png rename to Assets/Fungus/EditorResources/Textures/choice_node_on.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png.meta b/Assets/Fungus/EditorResources/Textures/choice_node_on.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/choice_node_on.png.meta rename to Assets/Fungus/EditorResources/Textures/choice_node_on.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/command_background.png b/Assets/Fungus/EditorResources/Textures/command_background.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/command_background.png rename to Assets/Fungus/EditorResources/Textures/command_background.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/command_background.png.meta b/Assets/Fungus/EditorResources/Textures/command_background.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/command_background.png.meta rename to Assets/Fungus/EditorResources/Textures/command_background.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png b/Assets/Fungus/EditorResources/Textures/event_node_off.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png rename to Assets/Fungus/EditorResources/Textures/event_node_off.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png.meta b/Assets/Fungus/EditorResources/Textures/event_node_off.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/event_node_off.png.meta rename to Assets/Fungus/EditorResources/Textures/event_node_off.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png b/Assets/Fungus/EditorResources/Textures/event_node_on.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png rename to Assets/Fungus/EditorResources/Textures/event_node_on.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png.meta b/Assets/Fungus/EditorResources/Textures/event_node_on.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/event_node_on.png.meta rename to Assets/Fungus/EditorResources/Textures/event_node_on.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/play_big.png b/Assets/Fungus/EditorResources/Textures/play_big.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/play_big.png rename to Assets/Fungus/EditorResources/Textures/play_big.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/play_big.png.meta b/Assets/Fungus/EditorResources/Textures/play_big.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/play_big.png.meta rename to Assets/Fungus/EditorResources/Textures/play_big.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/play_small.png b/Assets/Fungus/EditorResources/Textures/play_small.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/play_small.png rename to Assets/Fungus/EditorResources/Textures/play_small.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/play_small.png.meta b/Assets/Fungus/EditorResources/Textures/play_small.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/play_small.png.meta rename to Assets/Fungus/EditorResources/Textures/play_small.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png b/Assets/Fungus/EditorResources/Textures/process_node_off.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png rename to Assets/Fungus/EditorResources/Textures/process_node_off.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png.meta b/Assets/Fungus/EditorResources/Textures/process_node_off.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/process_node_off.png.meta rename to Assets/Fungus/EditorResources/Textures/process_node_off.png.meta diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png b/Assets/Fungus/EditorResources/Textures/process_node_on.png similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png rename to Assets/Fungus/EditorResources/Textures/process_node_on.png diff --git a/Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png.meta b/Assets/Fungus/EditorResources/Textures/process_node_on.png.meta similarity index 100% rename from Assets/Fungus/Fungus Editor Resources/Textures/process_node_on.png.meta rename to Assets/Fungus/EditorResources/Textures/process_node_on.png.meta diff --git a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs index 245de98a..a3c9f948 100644 --- a/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs +++ b/Assets/Fungus/Scripts/Editor/FungusEditorResources.cs @@ -13,6 +13,7 @@ namespace Fungus.EditorUtils internal static partial class FungusEditorResources { private static Dictionary textures = new Dictionary(); + private static readonly string editorResourcesFolderName = "\"EditorResources\""; static FungusEditorResources() { @@ -21,7 +22,7 @@ namespace Fungus.EditorUtils private static void LoadTexturesFromNames() { - var baseDirectories = AssetDatabase.FindAssets("\"Fungus Editor Resources\"").Select( + var baseDirectories = AssetDatabase.FindAssets(editorResourcesFolderName).Select( guid => AssetDatabase.GUIDToAssetPath(guid) ).ToArray(); @@ -33,7 +34,7 @@ namespace Fungus.EditorUtils private static void LoadAllTexturesInFolder() { - var rootGuid = AssetDatabase.FindAssets("\"Fungus Editor Resources\"")[0]; + var rootGuid = AssetDatabase.FindAssets(editorResourcesFolderName)[0]; var root = AssetDatabase.GUIDToAssetPath(rootGuid); LoadTexturesFromGUIDs(AssetDatabase.FindAssets("t:Texture2D", new [] { root })); }