Files
Silly-Home/Packages/com.vrchat.worlds/Samples/AINavmeshScene/AINavmeshSceneExample_UdonProgramSources/NPC Program.asset
2026-06-07 16:58:24 +01:00

382 lines
18 KiB
Plaintext

%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4f11136daadff0b44ac2278a314682ab, type: 3}
m_Name: NPC Program
m_EditorClassIdentifier:
serializedUdonProgramAsset: {fileID: 11400000, guid: d374eaca11eacc34b8d96507df6c6289, type: 2}
udonAssembly: ".data_start\r\n\r\n .export agent\r\n .export destination\r\n
\r\n __instance_0: %UnityEngineTransform, this\r\n __instance_1: %VRCUdonUdonBehaviour,
this\r\n __eventName_0: %SystemString, null\r\n __Boolean_0: %SystemBoolean,
null\r\n __Boolean_1: %SystemBoolean, null\r\n __instance_2: %UnityEngineAINavMeshAgent,
null\r\n __newPosition_0: %UnityEngineVector3, null\r\n __instance_3: %VRCUdonUdonBehaviour,
this\r\n __eventName_1: %SystemString, null\r\n __instance_4: %UnityEngineAINavMeshAgent,
null\r\n __value_0: %SystemBoolean, null\r\n __Boolean_2: %SystemBoolean,
null\r\n __obj_0: %UnityEngineGameObject, this\r\n __instance_5: %UnityEngineAINavMeshAgent,
null\r\n __value_1: %UnityEngineVector3, null\r\n __instance_6: %UnityEngineTransform,
this\r\n __instance_7: %VRCUdonUdonBehaviour, this\r\n __eventName_2: %SystemString,
null\r\n agent: %UnityEngineAINavMeshAgent, null\r\n destination: %UnityEngineTransform,
this\r\n startPosition: %UnityEngineVector3, null\r\n\r\n.data_end\r\n\r\n.code_start\r\n\r\n
.export _start\r\n \r\n _start:\r\n \r\n PUSH, __instance_0\r\n
PUSH, startPosition\r\n EXTERN, \"UnityEngineTransform.__get_position__UnityEngineVector3\"\r\n
PUSH, __instance_1\r\n PUSH, __eventName_0\r\n EXTERN, \"VRCUdonCommonInterfacesIUdonEventReceiver.__SendCustomEvent__SystemString__SystemVoid\"\r\n
JUMP, 0xFFFFFFFC\r\n \r\n .export Reset\r\n \r\n Reset:\r\n \r\n
PUSH, agent\r\n PUSH, __instance_2\r\n COPY\r\n PUSH, __instance_2\r\n
PUSH, startPosition\r\n PUSH, __Boolean_0\r\n EXTERN, \"UnityEngineAINavMeshAgent.__Warp__UnityEngineVector3__SystemBoolean\"\r\n
PUSH, agent\r\n PUSH, __instance_2\r\n COPY\r\n PUSH, __Boolean_0\r\n
PUSH, __Boolean_1\r\n COPY\r\n PUSH, __Boolean_0\r\n JUMP_IF_FALSE,
0x000000C4\r\n PUSH, __instance_3\r\n PUSH, __eventName_1\r\n
EXTERN, \"VRCUdonCommonInterfacesIUdonEventReceiver.__SendCustomEvent__SystemString__SystemVoid\"\r\n
JUMP, 0x000000C4\r\n JUMP, 0xFFFFFFFC\r\n \r\n .export Initialize\r\n
\r\n Initialize:\r\n \r\n PUSH, agent\r\n PUSH, __instance_4\r\n
COPY\r\n PUSH, __obj_0\r\n PUSH, __value_0\r\n EXTERN, \"VRCSDKBaseNetworking.__IsOwner__UnityEngineGameObject__SystemBoolean\"\r\n
PUSH, __instance_4\r\n PUSH, __value_0\r\n EXTERN, \"UnityEngineAINavMeshAgent.__set_enabled__SystemBoolean__SystemVoid\"\r\n
PUSH, __value_0\r\n PUSH, __Boolean_2\r\n COPY\r\n PUSH,
__value_0\r\n JUMP_IF_FALSE, 0x00000194\r\n PUSH, agent\r\n
PUSH, __instance_5\r\n COPY\r\n PUSH, destination\r\n PUSH,
__instance_6\r\n COPY\r\n PUSH, __instance_6\r\n PUSH, __value_1\r\n
EXTERN, \"UnityEngineTransform.__get_position__UnityEngineVector3\"\r\n
PUSH, __instance_5\r\n PUSH, __value_1\r\n EXTERN, \"UnityEngineAINavMeshAgent.__set_destination__UnityEngineVector3__SystemVoid\"\r\n
JUMP, 0x00000194\r\n JUMP, 0xFFFFFFFC\r\n \r\n .export _onOwnershipTransferred\r\n
\r\n _onOwnershipTransferred:\r\n \r\n PUSH, __instance_7\r\n
PUSH, __eventName_2\r\n EXTERN, \"VRCUdonCommonInterfacesIUdonEventReceiver.__SendCustomEvent__SystemString__SystemVoid\"\r\n
JUMP, 0xFFFFFFFC\r\n \r\n\r\n.code_end\r\n"
assemblyError:
graphData:
name:
description:
nodes:
- fullName: Variable_UnityEngineAINavMeshAgent
uid: 5c75abd2-9826-4cbf-afc7-651527dc85d7
position: {x: -461.32507, y: -470.50006}
nodeUIDs:
-
-
-
-
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|agent
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|True
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|none
- fullName: Event_Start
uid: 770508d9-a4ff-4b11-9145-fc911708fbbc
position: {x: 438.50995, y: 181.72116}
nodeUIDs: []
flowUIDs:
- 0df40823-73d5-42b6-87b1-782d46ecbe99
nodeValues: []
- fullName: Get_Variable
uid: 870800f5-5a40-4fb2-bdc8-df27d2c299c3
position: {x: 1966.4125, y: 92.50004}
nodeUIDs:
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|5c75abd2-9826-4cbf-afc7-651527dc85d7
- unityObjectValue: {fileID: 0}
stringValue:
- fullName: UnityEngineAINavMeshAgent.__set_destination__UnityEngineVector3__SystemVoid
uid: 72d6c586-439c-4c15-af99-7770adda5dbd
position: {x: 2172.29, y: 176}
nodeUIDs:
- 870800f5-5a40-4fb2-bdc8-df27d2c299c3|0
- 2d947fb5-8c44-469e-ba2e-69ad5220965e|0
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: UnityEngine.Vector3, UnityEngine.CoreModule, Version=0.0.0.0,
Culture=neutral, PublicKeyToken=null|{"x":0.0,"y":0.0,"z":0.0}
- fullName: Variable_UnityEngineTransform
uid: 32fd7a5e-2cdd-4fc7-9655-dce23b763d97
position: {x: 0, y: 0}
nodeUIDs:
-
-
-
-
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|destination
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|True
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|none
- fullName: Get_Variable
uid: f8ffe52d-3132-4efa-b813-a889c0019be3
position: {x: 1806.9999, y: 291.49997}
nodeUIDs:
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|32fd7a5e-2cdd-4fc7-9655-dce23b763d97
- unityObjectValue: {fileID: 0}
stringValue:
- fullName: UnityEngineTransform.__get_position__UnityEngineVector3
uid: 2d947fb5-8c44-469e-ba2e-69ad5220965e
position: {x: 1987, y: 292}
nodeUIDs:
- f8ffe52d-3132-4efa-b813-a889c0019be3|0
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- fullName: Event_Custom
uid: 5d914ad1-5a9b-4aa3-a2c6-337796e9e65d
position: {x: 864.63824, y: 492.66104}
nodeUIDs:
-
flowUIDs:
- 59a2527e-351d-4634-80fe-d5b2bce50a2c
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|Reset
- fullName: Variable_UnityEngineVector3
uid: 91f02f5f-658a-4599-89e8-d554fec7d244
position: {x: 0, y: 0}
nodeUIDs:
-
-
-
-
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|startPosition
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|none
- fullName: Set_Variable
uid: 0df40823-73d5-42b6-87b1-782d46ecbe99
position: {x: 622.50995, y: 181.72116}
nodeUIDs:
-
- b8e7c80b-4022-4302-b0e3-df5c4cf4c81e|0
-
flowUIDs:
- 2f3b8517-e5df-4bcb-9762-7358960a884b
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|91f02f5f-658a-4599-89e8-d554fec7d244
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- fullName: UnityEngineTransform.__get_position__UnityEngineVector3
uid: b8e7c80b-4022-4302-b0e3-df5c4cf4c81e
position: {x: 438.50995, y: 291.72116}
nodeUIDs:
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- fullName: Get_Variable
uid: 76ac6ea7-edbb-44ab-8896-27f41aae0fe8
position: {x: 884.63824, y: 608.661}
nodeUIDs:
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|5c75abd2-9826-4cbf-afc7-651527dc85d7
- unityObjectValue: {fileID: 0}
stringValue:
- fullName: UnityEngineAINavMeshAgent.__Warp__UnityEngineVector3__SystemBoolean
uid: 59a2527e-351d-4634-80fe-d5b2bce50a2c
position: {x: 1105.6382, y: 585.661}
nodeUIDs:
- 76ac6ea7-edbb-44ab-8896-27f41aae0fe8|0
- 614c373f-bb54-4d20-b3c7-19faf476b3b7|0
flowUIDs:
- 1efaa5b0-4fd3-47d5-b2dd-dfcd31883512
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: UnityEngine.Vector3, UnityEngine.CoreModule, Version=0.0.0.0,
Culture=neutral, PublicKeyToken=null|{"x":0.0,"y":0.0,"z":0.0}
- fullName: Get_Variable
uid: 614c373f-bb54-4d20-b3c7-19faf476b3b7
position: {x: 892.63824, y: 702.661}
nodeUIDs:
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|91f02f5f-658a-4599-89e8-d554fec7d244
- unityObjectValue: {fileID: 0}
stringValue:
- fullName: VRCUdonCommonInterfacesIUdonEventReceiver.__SendCustomEvent__SystemString__SystemVoid
uid: c39f2dad-9e29-4fec-9d60-a3a661764253
position: {x: 1470.6382, y: 585.661}
nodeUIDs:
-
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|Initialize
- fullName: Branch
uid: 1efaa5b0-4fd3-47d5-b2dd-dfcd31883512
position: {x: 1322.6382, y: 585.661}
nodeUIDs:
- 59a2527e-351d-4634-80fe-d5b2bce50a2c|0
flowUIDs:
- c39f2dad-9e29-4fec-9d60-a3a661764253
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- fullName: Event_Custom
uid: 3e7fe849-ee66-4baa-b2da-0bd51d978924
position: {x: 1093.499, y: 50.749496}
nodeUIDs:
-
flowUIDs:
- 29f40623-2582-4546-9800-3a6ccf20ff5c
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|Initialize
- fullName: VRCUdonCommonInterfacesIUdonEventReceiver.__SendCustomEvent__SystemString__SystemVoid
uid: 2f3b8517-e5df-4bcb-9762-7358960a884b
position: {x: 806.50995, y: 181.72116}
nodeUIDs:
-
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|Initialize
- fullName: Event_OnOwnershipTransferred
uid: 36475b30-ca04-440c-984f-a15714b5b06d
position: {x: 864, y: 887.74896}
nodeUIDs: []
flowUIDs:
- a95d7c35-c57e-47b8-9414-66432cd93515
nodeValues: []
- fullName: VRCUdonCommonInterfacesIUdonEventReceiver.__SendCustomEvent__SystemString__SystemVoid
uid: a95d7c35-c57e-47b8-9414-66432cd93515
position: {x: 1118, y: 887.74896}
nodeUIDs:
-
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|Initialize
- fullName: Get_Variable
uid: ebae33fe-1d10-40d6-ba4e-df40f7f5e55c
position: {x: 1102.499, y: 140.7495}
nodeUIDs:
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089|5c75abd2-9826-4cbf-afc7-651527dc85d7
- unityObjectValue: {fileID: 0}
stringValue:
- fullName: UnityEngineAINavMeshAgent.__set_enabled__SystemBoolean__SystemVoid
uid: 29f40623-2582-4546-9800-3a6ccf20ff5c
position: {x: 1499.499, y: 50.749496}
nodeUIDs:
- ebae33fe-1d10-40d6-ba4e-df40f7f5e55c
- 9164da0a-a7c3-40c9-9a9a-83fee69be123|0
flowUIDs:
- 500bc155-fc29-4405-8f59-1befa0d70f78
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- fullName: Branch
uid: 500bc155-fc29-4405-8f59-1befa0d70f78
position: {x: 1669, y: 182}
nodeUIDs:
- 9164da0a-a7c3-40c9-9a9a-83fee69be123|0
flowUIDs:
- 72d6c586-439c-4c15-af99-7770adda5dbd
-
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue: System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089|False
- fullName: VRCSDKBaseNetworking.__IsOwner__UnityEngineGameObject__SystemBoolean
uid: 9164da0a-a7c3-40c9-9a9a-83fee69be123
position: {x: 1313, y: 204}
nodeUIDs:
-
-
flowUIDs: []
nodeValues:
- unityObjectValue: {fileID: 0}
stringValue:
- unityObjectValue: {fileID: 0}
stringValue:
updateOrder: 0
graphElementData:
- type: 2
uid: 025e8a92-e9e0-4f9f-8681-9c757cd1a509
jsonData: '{"uid":"025e8a92-e9e0-4f9f-8681-9c757cd1a509","layout":{"serializedVersion":"2","x":1069.0,"y":-8.0,"width":1305.0,"height":408.0},"containedElements":["2d947fb5-8c44-469e-ba2e-69ad5220965e","f8ffe52d-3132-4efa-b813-a889c0019be3","72d6c586-439c-4c15-af99-7770adda5dbd","870800f5-5a40-4fb2-bdc8-df27d2c299c3","3e7fe849-ee66-4baa-b2da-0bd51d978924","9164da0a-a7c3-40c9-9a9a-83fee69be123","500bc155-fc29-4405-8f59-1befa0d70f78","29f40623-2582-4546-9800-3a6ccf20ff5c","ebae33fe-1d10-40d6-ba4e-df40f7f5e55c"],"title":"Enable
Agent for Owner, set Destination. Disable for Others.","layer":-1,"elementTypeColor":{"r":0.0,"g":0.0,"b":0.0,"a":1.0}}'
- type: 2
uid: 94e885ec-454f-4832-b7be-19d835ddcfe5
jsonData: '{"uid":"94e885ec-454f-4832-b7be-19d835ddcfe5","layout":{"serializedVersion":"2","x":414.0000305175781,"y":122.99995422363281,"width":637.0,"height":277.0},"containedElements":["b8e7c80b-4022-4302-b0e3-df5c4cf4c81e","0df40823-73d5-42b6-87b1-782d46ecbe99","770508d9-a4ff-4b11-9145-fc911708fbbc","2f3b8517-e5df-4bcb-9762-7358960a884b"],"title":"Save
startPosition on Start","layer":-1,"elementTypeColor":{"r":0.0,"g":0.0,"b":0.0,"a":1.0}}'
- type: 2
uid: faaf1a1a-54a5-45f4-a4e3-5f1d54f94394
jsonData: '{"uid":"faaf1a1a-54a5-45f4-a4e3-5f1d54f94394","layout":{"serializedVersion":"2","x":840.0000610351563,"y":434.0000305175781,"width":875.0,"height":377.0},"containedElements":["614c373f-bb54-4d20-b3c7-19faf476b3b7","59a2527e-351d-4634-80fe-d5b2bce50a2c","76ac6ea7-edbb-44ab-8896-27f41aae0fe8","5d914ad1-5a9b-4aa3-a2c6-337796e9e65d","1efaa5b0-4fd3-47d5-b2dd-dfcd31883512","c39f2dad-9e29-4fec-9d60-a3a661764253"],"title":"Warp
Agent to startPosition on Reset","layer":-1,"elementTypeColor":{"r":0.0,"g":0.0,"b":0.0,"a":1.0}}'
- type: 2
uid: 9f67c65d-bacd-4030-94a6-517ec52e6620
jsonData: '{"uid":"9f67c65d-bacd-4030-94a6-517ec52e6620","layout":{"serializedVersion":"2","x":838.9999389648438,"y":828.9999389648438,"width":523.0,"height":215.0},"containedElements":["a95d7c35-c57e-47b8-9414-66432cd93515","36475b30-ca04-440c-984f-a15714b5b06d"],"title":"Toggle
Agent on Transfer if Needed","layer":-1,"elementTypeColor":{"r":0.0,"g":0.0,"b":0.0,"a":1.0}}'
version: 1.0.0
showAssembly: 0