<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ja">
		<id>https://wiki.nonip.net/index.php?action=history&amp;feed=atom&amp;title=Unity%2F3d%2Fcollider%2F%E8%B7%9D%E9%9B%A2</id>
		<title>Unity/3d/collider/距離 - 変更履歴</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.nonip.net/index.php?action=history&amp;feed=atom&amp;title=Unity%2F3d%2Fcollider%2F%E8%B7%9D%E9%9B%A2"/>
		<link rel="alternate" type="text/html" href="https://wiki.nonip.net/index.php?title=Unity/3d/collider/%E8%B7%9D%E9%9B%A2&amp;action=history"/>
		<updated>2026-04-19T00:29:36Z</updated>
		<subtitle>このウィキのこのページに関する変更履歴</subtitle>
		<generator>MediaWiki 1.24.2</generator>

	<entry>
		<id>https://wiki.nonip.net/index.php?title=Unity/3d/collider/%E8%B7%9D%E9%9B%A2&amp;diff=17022&amp;oldid=prev</id>
		<title>Admin: /* サンプル */</title>
		<link rel="alternate" type="text/html" href="https://wiki.nonip.net/index.php?title=Unity/3d/collider/%E8%B7%9D%E9%9B%A2&amp;diff=17022&amp;oldid=prev"/>
				<updated>2023-04-22T14:31:09Z</updated>
		
		<summary type="html">&lt;p&gt;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;サンプル&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;←前の版&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;2023年4月22日 (土) 14:31時点における版&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;行25:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;行25:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160; &amp;#160; }&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160; &amp;#160; }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; }&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; // 範囲から抜けたとき&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; // 範囲から抜けたとき&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; void OnTriggerExit(Collider collider)&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; void OnTriggerExit(Collider collider)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	<entry>
		<id>https://wiki.nonip.net/index.php?title=Unity/3d/collider/%E8%B7%9D%E9%9B%A2&amp;diff=15143&amp;oldid=prev</id>
		<title>Admin: ページの作成:「==サンプル== 範囲内に入った際に、ある位置からの距離を測定する。  Unity/3d/collider/貫通 [ｼｮｰﾄｶｯﾄ]  上記参考に、一...」</title>
		<link rel="alternate" type="text/html" href="https://wiki.nonip.net/index.php?title=Unity/3d/collider/%E8%B7%9D%E9%9B%A2&amp;diff=15143&amp;oldid=prev"/>
				<updated>2022-04-22T06:30:38Z</updated>
		
		<summary type="html">&lt;p&gt;ページの作成:「==サンプル== 範囲内に入った際に、ある位置からの距離を測定する。  &lt;a href=&quot;/index.php/Unity/3d/collider/%E8%B2%AB%E9%80%9A&quot; title=&quot;Unity/3d/collider/貫通&quot;&gt;Unity/3d/collider/貫通&lt;/a&gt; [ｼｮｰﾄｶｯﾄ]  上記参考に、一...」&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新規ページ&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==サンプル==&lt;br /&gt;
範囲内に入った際に、ある位置からの距離を測定する。&lt;br /&gt;
&lt;br /&gt;
[[Unity/3d/collider/貫通]] [ｼｮｰﾄｶｯﾄ]&lt;br /&gt;
&lt;br /&gt;
上記参考に、一部改変する。&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
using UnityEngine;&lt;br /&gt;
public class SphereTrigger: MonoBehaviour&lt;br /&gt;
{&lt;br /&gt;
    // 範囲内に入ったとき&lt;br /&gt;
    void OnTriggerEnter(Collider collider)&lt;br /&gt;
    {&lt;br /&gt;
        Debug.Log(&amp;quot;OnTriggerEnter&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    // 範囲中のとき&lt;br /&gt;
    void OnTriggerStay(Collider collider)&lt;br /&gt;
    {&lt;br /&gt;
        Debug.Log(&amp;quot;OnCollisionStay collision.gameObject.name=&amp;quot; + collider.gameObject.name);&lt;br /&gt;
        if (collider.gameObject.name == &amp;quot;CharacterSphere&amp;quot;)&lt;br /&gt;
        {&lt;br /&gt;
            var distance = Vector3.Distance(transform.position, collider.gameObject.transform.position);&lt;br /&gt;
            Debug.Log(&amp;quot;distance=&amp;quot; + distance);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    // 範囲から抜けたとき&lt;br /&gt;
    void OnTriggerExit(Collider collider)&lt;br /&gt;
    {&lt;br /&gt;
        Debug.Log(&amp;quot;OnTriggerExit&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	</feed>