{"url":"https://baba-s.hatenablog.com/entry/2019/11/28/160000","blog_url":"https://baba-s.hatenablog.com/","width":"100%","categories":["Unity","Unity - \u62e1\u5f35\u30e1\u30bd\u30c3\u30c9","\u305d\u306e\u4ed6 - \u304a\u6c17\u306b\u5165\u308a"],"published":"2019-11-28 16:00:00","description":"\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9 using UnityEngine; public static class ComponentExt { public static bool TryGetComponentInParent<T>( this Component self, out T component ) where T : Component { component = self.GetComponentInParent<T>(); return component != null; } } public static class GameObjectExt { public static bool Tr\u2026","blog_title":"\u30b3\u30ac\u30cd\u30d6\u30ed\u30b0","image_url":"https://cdn.user.blog.st-hatena.com/default_entry_og_image/94867065/1535279515352365","author_name":"baba_s","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fbaba-s.hatenablog.com%2Fentry%2F2019%2F11%2F28%2F160000\" title=\"\u3010Unity\u3011GetComponentInParent \u306e null \u30c1\u30a7\u30c3\u30af\u3092\u5c11\u3057\u3060\u3051\u7c21\u6f54\u306b\u8a18\u8ff0\u3067\u304d\u308b TryGetComponentInParent \u62e1\u5f35\u30e1\u30bd\u30c3\u30c9 - \u30b3\u30ac\u30cd\u30d6\u30ed\u30b0\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","title":"\u3010Unity\u3011GetComponentInParent \u306e null \u30c1\u30a7\u30c3\u30af\u3092\u5c11\u3057\u3060\u3051\u7c21\u6f54\u306b\u8a18\u8ff0\u3067\u304d\u308b TryGetComponentInParent \u62e1\u5f35\u30e1\u30bd\u30c3\u30c9","provider_url":"https://hatena.blog","height":"190","provider_name":"Hatena Blog","version":"1.0","type":"rich","author_url":"https://blog.hatena.ne.jp/baba_s/"}