{"url":"https://baba-s.hatenablog.com/entry/2022/08/25/105945","blog_title":"\u30b3\u30ac\u30cd\u30d6\u30ed\u30b0","width":"100%","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fbaba-s.hatenablog.com%2Fentry%2F2022%2F08%2F25%2F105945\" title=\"\u3010Unity\u3011SendMessage cannot be called during Awake, CheckConsistency, or OnValidate (XXXX: OnRectTransformDimensionsChange) - \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>","image_url":"https://cdn.user.blog.st-hatena.com/default_entry_og_image/94867065/1638616250229186","provider_name":"Hatena Blog","provider_url":"https://hatena.blog","categories":["Unity","Unity - \u30c8\u30e9\u30d6\u30eb\u30b7\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0"],"version":"1.0","blog_url":"https://baba-s.hatenablog.com/","height":"190","author_url":"https://blog.hatena.ne.jp/baba_s/","description":"\u306f\u3058\u3081\u306b using UnityEngine; public class Example : MonoBehaviour { private void OnValidate() { Apply(); } private void Apply() { var rectTransform = GetComponent<RectTransform>(); rectTransform.sizeDelta = new Vector2 ( Random.Range( 0f, 100f ), Random.Range( 0f, 100f ) ); } } \u4e0a\u8a18\u306e\u3088\u3046\u306a\u30b3\u30fc\u30c9\u3092\u66f8\u3044\u305f\u3089\u3001\u30b3\u30f3\u30d1\u30a4\u30eb\u5b8c\u4e86\u6642\u306b S\u2026","title":"\u3010Unity\u3011SendMessage cannot be called during Awake, CheckConsistency, or OnValidate (XXXX: OnRectTransformDimensionsChange)","type":"rich","author_name":"baba_s","published":"2022-08-25 10:59:45"}