<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>nakahashi_h</author_name>
  <author_url>https://blog.hatena.ne.jp/nakahashi_h/</author_url>
  <blog_title>websandbag ブログ</blog_title>
  <blog_url>https://blog.websandbag.com/</blog_url>
  <categories>
    <anon>C#</anon>
    <anon>Unity</anon>
  </categories>
  <description>特定のオブジェクトの周りに、オブジェクトをランダム配置させたいという場面に遭遇しました。 今回は、中央にある赤いオブジェクトを起点にし、周囲に適当なオブジェクトを設定する方法について触れます。 数学的なお話 今回は円状に配置するので、ランダムで設定した座標XとYが指定した円の長さの中に含まれるかどうかを判定します。 半径Rの円の中に含まれるかどうかの判定は、次の公式を元にします。 半径の2乗は、X軸の2乗とY軸の2乗を足した値と同じ。 R2 = X2 + Y2 つまり、半径の２乗以内であれば円の中であると言えます。 実装方法 今回はオブジェクトに近すぎる場所には設定ませんのでドーナツ状になりま…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.websandbag.com%2Fentry%2F2018%2F08%2F02%2F230243&quot; title=&quot;【Unity】特定の位置から円状にオブジェクトランダム配置 - websandbag ブログ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url>https://cdn-ak.f.st-hatena.com/images/fotolife/n/nakahashi_h/20180824/20180824011830.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2018-08-02 23:02:43</published>
  <title>【Unity】特定の位置から円状にオブジェクトランダム配置</title>
  <type>rich</type>
  <url>https://blog.websandbag.com/entry/2018/08/02/230243</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
