diff --git a/ChatController.cs b/ChatController.cs
index 4aa27cb..d0c2b3e 100644
--- a/ChatController.cs
+++ b/ChatController.cs
@@ -5,18 +5,29 @@
using VRC.Udon.Common.Interfaces;
using UnityEngine.UI;
+///A controller for a button that will convert the product of an InputField to a ChatMessage event.
public class ChatController : UdonSharpBehaviour
{
+ ///The text input field for this controller.
public InputField input;
+ ///The manager we want to handle chat events.
public EventEmissionManager manager;
+ ///Send a ChatMessage using the product of an InputField.
public void SendMessage()
{
if (input.text == "" || input.text == null)
{
return;
}
- manager.SendChatMessage(input.text);
+
+ if (input.text.Length > 100)
+ {
+ input.text = input.text.Substring(0, 100);
+ }
+
+ string message = input.text;
+ manager.SendEvent("ChatMessage", message.Replace(",", "|"));
input.text = null;
}
}
diff --git a/ChatController.cs.meta b/ChatController.cs.meta
deleted file mode 100644
index 805a19b..0000000
--- a/ChatController.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 484ed35432fbd0b408f3373d1ccf1ac8
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/DiceRoller.cs b/DiceRoller.cs
deleted file mode 100644
index 0531052..0000000
--- a/DiceRoller.cs
+++ /dev/null
@@ -1,18 +0,0 @@
-// Roll dice!
-using UdonSharp;
-using UnityEngine;
-using VRC.SDKBase;
-using VRC.Udon;
-using VRC.Udon.Common.Interfaces;
-
-public class DiceRoller : UdonSharpBehaviour
-{
- public UdonLogger logger;
-
- public void Roll1D20()
- {
- int result = Random.Range(1, 21);
- logger.Notice("A 1D20 was rolled! Result was " + result);
- }
-
-}
diff --git a/DiceRoller.cs.meta b/DiceRoller.cs.meta
deleted file mode 100644
index cb5d3d7..0000000
--- a/DiceRoller.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: d106228739a53c1489509813195268e3
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/EventEmissionManager.cs b/EventEmissionManager.cs
index 127c698..5f55ade 100644
--- a/EventEmissionManager.cs
+++ b/EventEmissionManager.cs
@@ -6,54 +6,72 @@
using VRC.Udon;
using VRC.Udon.Common.Interfaces;
+///The point-of-contact for all users of the UdonStringEvent system.
public class EventEmissionManager : UdonSharpBehaviour
{
+ ///The receiver of events in this event system.
public EventReceiver receiver;
- private EventEmitter emitter;
private int clock;
+ private string displayName;
+ private bool gotEmitter;
public void Start()
{
clock = 0;
+ displayName = "";
+ gotEmitter = false;
+
+ if (Networking.LocalPlayer != null)
+ {
+ displayName = Networking.LocalPlayer.displayName;
+ }
+
}
public void Update()
{
- if (emitter == null)
+ if (gotEmitter == false)
{
- string displayName = "";
- GameObject ownedEmitter = null;
-
- if (Networking.LocalPlayer != null)
- {
- displayName = Networking.LocalPlayer.displayName;
- }
-
- ownedEmitter = receiver.GetEmitter(displayName);
-
- if (ownedEmitter != null)
- {
- Debug.Log("Emitter object has arrived in our care.");
- Networking.SetOwner(Networking.LocalPlayer, ownedEmitter);
- emitter = (EventEmitter)ownedEmitter.GetComponent(typeof(UdonBehaviour));
- }
+ GetEmitter();
+ //TODO: If gotemitter is false for a long time (5 seconds?) panic and alert the receiver that a reallocation has to happen.
}
}
+ ///Send a string event to all other players in the world.
public void SendEvent(string eventName, string eventPayload)
{
+ // An extension to this system might queue up events in the instance that we want to make sure they're sent on world load.
+ // For the time being a good modification might be to change SendEvent to return a bool.
+
+ // This can be bad in two ways: either the return is null or the return is not owned.
+ GameObject emitter = receiver.GetEmitter(displayName);
if (emitter == null)
{
- Debug.Log("emitter was null, could not handle " + eventName + " event");
+ Debug.Log("emitter was null: could not handle " + eventName + " event");
+ gotEmitter = false;
return;
}
- emitter.SetNewEvent(eventName, eventPayload);
+ if (!Networking.IsOwner(emitter.gameObject))
+ {
+ Debug.Log("emitter not owned by player: could not handle " + eventName + " event");
+ gotEmitter = false;
+ return;
+ }
+
+ emitter.GetComponent().SetNewEvent(eventName, eventPayload);
}
- public void SendChatMessage(string message)
+ private void GetEmitter()
{
- SendEvent("ChatMessage", message);
+ GameObject emitter = receiver.GetEmitter(displayName);
+
+ if (emitter != null)
+ {
+ Debug.Log("Emitter object has arrived in our care.");
+ Networking.SetOwner(Networking.LocalPlayer, emitter);
+ gotEmitter = true;
+ }
}
}
\ No newline at end of file
diff --git a/EventEmissionManager.cs.meta b/EventEmissionManager.cs.meta
deleted file mode 100644
index a6c70f4..0000000
--- a/EventEmissionManager.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 8f51f7a0dadc2ba4c9f0ef89c4e1efb0
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/EventEmitter.cs b/EventEmitter.cs
index f3dbb95..84a322c 100644
--- a/EventEmitter.cs
+++ b/EventEmitter.cs
@@ -6,22 +6,29 @@
using VRC.Udon;
using VRC.Udon.Common.Interfaces;
+/// A Behaviour that can emit events. An Emitter will check if this Emitter has emitted each update.
public class EventEmitter : UdonSharpBehaviour
{
+ // Designates who owns this Emitter.
[UdonSynced]
private string characterName;
+ // If newEvent doesn't match oldEvent, then a new event has been emitted.
[UdonSynced]
private string newEvent;
private string oldEvent;
+ private int clock;
+
public void Start()
{
characterName = "";
newEvent = "";
oldEvent = "";
+ clock = 0;
}
+ /// If a new event has been emitted, return the event. Otherwise return an empty string.
public string GetNewEvent()
{
if (newEvent == oldEvent)
@@ -33,20 +40,29 @@ public string GetNewEvent()
return newEvent;
}
+ /// Set a new event to be emitted.
public void SetNewEvent(string eventName, string payload)
{
+ // Leave this debug log on unless you have a lot of spam. It'll help with debugging.
Debug.Log("Sending event: " + eventName + ": " + payload);
- newEvent = eventName + "," + payload;
+ newEvent = eventName + "," + payload + "," + clock;
+
+ clock++;
}
+ /// Get the name of the character that owns this emitter.
public string GetCharacterName()
{
+ // Note that for Udon, even though we *can* get variables directly, don't. It's cleaner to rely on functions.
return characterName;
}
+ /// Set the owner of the emitter to the provided name.
public void SetCharacterName(string c)
{
- characterName = c;
- Debug.Log("Emitter's Character Name has been set to " + c);
+ if (Networking.IsOwner(gameObject))
+ {
+ characterName = c;
+ }
}
}
\ No newline at end of file
diff --git a/EventEmitter.cs.meta b/EventEmitter.cs.meta
deleted file mode 100644
index 0cc614c..0000000
--- a/EventEmitter.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 04309e376c7321e4fb44a3e6bc5958d0
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/EventReceiver.cs b/EventReceiver.cs
index 07bd30f..1f24088 100644
--- a/EventReceiver.cs
+++ b/EventReceiver.cs
@@ -5,17 +5,24 @@
using VRC.Udon;
using VRC.Udon.Common.Interfaces;
+///EventReceiver is the core of the UdonStringEvent system. One must exist per system.
public class EventReceiver : UdonSharpBehaviour
{
+ /// An array of all Emitters in the system.
public GameObject[] emitters;
+
+ /// A logger that events can be output to. This is optional.
public UdonLogger logger;
public void Update()
{
- for (int i = 0; i < 4; i++)
+ for (int i = 0; i < emitters.Length; i++)
{
+ // UdonSharp limitation - this can be refactored once the generic is handled correctly.
EventEmitter emitter = ((EventEmitter)emitters[i].GetComponent(typeof(UdonBehaviour)));
string newEv = emitter.GetNewEvent();
+
+ // GetNewEvent returns either a nil event (empty string) or an event.
if (newEv != "")
{
HandleUpdate(emitter.GetCharacterName(), newEv);
@@ -23,9 +30,10 @@ public void Update()
}
}
+ /// Retrieve an Emitter if one is found that belongs to the provied character name, or null if one isn't.
public GameObject GetEmitter(string characterName)
{
- for (int i = 0; i < 4; i++)
+ for (int i = 0; i < emitters.Length; i++)
{
if (emitters[i].GetComponent().GetCharacterName() == characterName)
{
@@ -39,12 +47,17 @@ public GameObject GetEmitter(string characterName)
private void HandleUpdate(string characterName, string eventString)
{
+ // As it stands, hard-code your events in this function.
+ // This is pretty basic. Once maps and lists exist in Udon, this can be improved.
string[] e = eventString.Split(',');
- Debug.Log("Got an event named " + e[0] + "with payload " + eventString);
+ Debug.Log("Got an event named " + e[0] + " with payload " + eventString);
switch (e[0])
{
case "ChatMessage":
- logger.Notice(characterName + ": " + e[1]);
+ string message = characterName + ": " + e[1];
+ message = message.Replace("|", ",");
+ Debug.Log("Notice: " + message);
+ logger.Notice(message);
break;
default:
logger.Notice("Got an event named " + e[0] + " but didn't know what to do with it.");
@@ -52,6 +65,7 @@ private void HandleUpdate(string characterName, string eventString)
}
}
+ /// Get an empty emitter and assign it to the new player.
public override void OnPlayerJoined(VRCPlayerApi player)
{
if (Networking.IsOwner(gameObject))
@@ -61,6 +75,7 @@ public override void OnPlayerJoined(VRCPlayerApi player)
}
}
+ /// Get the player's emitter and assign it to nobody.
public override void OnPlayerLeft(VRCPlayerApi player)
{
if (Networking.IsOwner(gameObject))
diff --git a/EventReceiver.cs.meta b/EventReceiver.cs.meta
deleted file mode 100644
index 146d6e1..0000000
--- a/EventReceiver.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 046711fcb3b389541b3eed09191b453d
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/KeyEventListener.cs b/KeyEventListener.cs
new file mode 100644
index 0000000..600b670
--- /dev/null
+++ b/KeyEventListener.cs
@@ -0,0 +1,27 @@
+using UdonSharp;
+using UnityEngine;
+using UnityEngine.UI;
+using VRC.SDKBase;
+using VRC.Udon;
+using VRC.Udon.Common.Interfaces;
+
+public class KeyEventListener : UdonSharpBehaviour
+{
+ public KeyboardManager keyboard;
+ public UdonLogger logger;
+
+ private void Update()
+ {
+ var player = Networking.LocalPlayer;
+ if (player != null && player.IsUserInVR())
+ {
+ return;
+ }
+
+ if (Input.GetKeyDown(KeyCode.K))
+ {
+ keyboard.Toggle();
+ logger.Toggle();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Keyboard/Backspace.cs b/Keyboard/Backspace.cs
new file mode 100644
index 0000000..0ff4204
--- /dev/null
+++ b/Keyboard/Backspace.cs
@@ -0,0 +1,16 @@
+using UdonSharp;
+using UnityEngine;
+using VRC.SDKBase;
+using VRC.Udon;
+using VRC.Udon.Common.Interfaces;
+using UnityEngine.UI;
+
+public class BackspaceKey : UdonSharpBehaviour
+{
+ public KeyboardManager manager;
+
+ public void PressKey()
+ {
+ manager.Backspace();
+ }
+}
\ No newline at end of file
diff --git a/Keyboard/CapsLock.cs b/Keyboard/CapsLock.cs
new file mode 100644
index 0000000..5da163f
--- /dev/null
+++ b/Keyboard/CapsLock.cs
@@ -0,0 +1,28 @@
+using UdonSharp;
+using UnityEngine;
+using VRC.SDKBase;
+using VRC.Udon;
+using VRC.Udon.Common.Interfaces;
+using UnityEngine.UI;
+
+public class CapsLockKey : UdonSharpBehaviour
+{
+ public KeyboardManager manager;
+ public Image buttonImage;
+ private bool toggle;
+
+ public void PressKey()
+ {
+ if (toggle)
+ {
+ manager.CapsOff();
+ toggle = false;
+ buttonImage.color = Color.white;
+ return;
+ }
+
+ manager.CapsOn();
+ toggle = true;
+ buttonImage.color = Color.blue;
+ }
+}
\ No newline at end of file
diff --git a/Keyboard/KeyboardKey.cs b/Keyboard/KeyboardKey.cs
new file mode 100644
index 0000000..07104ef
--- /dev/null
+++ b/Keyboard/KeyboardKey.cs
@@ -0,0 +1,48 @@
+using UdonSharp;
+using UnityEngine;
+using VRC.SDKBase;
+using VRC.Udon;
+using VRC.Udon.Common.Interfaces;
+using UnityEngine.UI;
+
+public class KeyboardKey : UdonSharpBehaviour
+{
+ public string lowCharacter;
+ public string upCharacter;
+ private string character;
+ public KeyboardManager manager;
+ public Text buttonText;
+ public void Start()
+ {
+ SetLower();
+ }
+
+ public void PressKey()
+ {
+ manager.SendKey(character);
+ }
+
+ public void SetLower()
+ {
+ character = lowCharacter;
+ if (character == "space")
+ {
+ buttonText.text = "Space";
+ character = " ";
+ return;
+ }
+ buttonText.text = character.ToUpper();
+ }
+
+ public void SetUpper()
+ {
+ character = upCharacter;
+ if (character == "space")
+ {
+ buttonText.text = "Space";
+ character = " ";
+ return;
+ }
+ buttonText.text = character.ToUpper();
+ }
+}
\ No newline at end of file
diff --git a/Keyboard/KeyboardManager.cs b/Keyboard/KeyboardManager.cs
new file mode 100644
index 0000000..579d034
--- /dev/null
+++ b/Keyboard/KeyboardManager.cs
@@ -0,0 +1,145 @@
+using UdonSharp;
+using UnityEngine;
+using VRC.SDKBase;
+using VRC.Udon;
+using VRC.Udon.Common.Interfaces;
+using UnityEngine.UI;
+
+///The manager for a keyboard.
+public class KeyboardManager : UdonSharpBehaviour
+{
+ ///The anchor on this keyboard for putting a Logger on it.
+ public GameObject keyboardAnchor;
+ ///The root of a Logger, used for anchoring it to the keyboard.
+ public UdonLogger logScreen;
+ ///The default anchor location for the Logger.
+ public GameObject logScreenAnchor;
+ ///The input field for this keyboard.
+ public InputField input;
+ ///All the keyboard keys this keyboard has.
+ public KeyboardKey[] keys;
+ ///The shift key for this keyboard.
+ public ShiftKey shiftKey;
+
+ private bool caps;
+ private bool shift;
+ private bool visible;
+
+ public void Start()
+ {
+ gameObject.SetActive(false);
+ }
+
+ public void Update()
+ {
+ VRCPlayerApi player = Networking.LocalPlayer;
+ if (player != null)
+ {
+ gameObject.transform.position = player.GetBonePosition(HumanBodyBones.Spine);
+ gameObject.transform.rotation = player.GetBoneRotation(HumanBodyBones.Spine);
+
+ // If the keyboard is active, the log screen should sit above the keyboard.
+ if (gameObject.activeSelf)
+ {
+ logScreen.transform.position = keyboardAnchor.transform.position;
+ logScreen.transform.rotation = keyboardAnchor.transform.rotation;
+ logScreen.transform.localScale = new Vector3(2, 2, 2);
+ }
+ }
+ }
+
+ ///Send a key's character to the keyboard. Deactivate shift if it's on.
+ public void SendKey(string character)
+ {
+ input.text += character;
+
+ if (shift)
+ {
+ shift = false;
+ shiftKey.PressKey();
+ }
+ }
+
+ ///Set caps to ON. Shift the keys to upper case if shift isn't on.
+ public void CapsOn()
+ {
+ caps = true;
+
+ if (!shift)
+ {
+ SetKeysUpper();
+ }
+ }
+
+ ///Set caps to off. Shift the keys to lower case if shift isn't on.
+ public void CapsOff()
+ {
+ caps = false;
+
+ if (!shift)
+ {
+ SetKeysLower();
+ }
+ }
+
+ ///Set shift to ON. Shift the keys to upper case if caps isn't on.
+ public void ShiftOn()
+ {
+ shift = true;
+
+ if (!caps)
+ {
+ SetKeysUpper();
+ }
+ }
+
+ ///Set shift to off. Shift the keys to lower case if caps isn't on.
+ public void ShiftOff()
+ {
+ shift = false;
+
+ if (!caps)
+ {
+ SetKeysLower();
+ }
+ }
+
+ ///Delete the last character in the input field.
+ public void Backspace()
+ {
+ if (input.text.Length > 0)
+ {
+ input.text = input.text.Remove(input.text.Length - 1);
+ }
+ }
+
+ ///Toggle the keyboard on or off.
+ public void Toggle()
+ {
+ gameObject.SetActive(!gameObject.activeSelf);
+
+ if (gameObject.activeSelf)
+ {
+ logScreen.Anchor();
+ return;
+ }
+
+ logScreen.Unanchor();
+ }
+
+ private void SetKeysUpper()
+ {
+ for (int i = 0; i < keys.Length; i++)
+ {
+ keys[i].SetUpper();
+ }
+ }
+
+ private void SetKeysLower()
+ {
+ for (int i = 0; i < keys.Length; i++)
+ {
+ keys[i].SetLower();
+ }
+ }
+}
\ No newline at end of file
diff --git a/Keyboard/Shift.cs b/Keyboard/Shift.cs
new file mode 100644
index 0000000..d828bac
--- /dev/null
+++ b/Keyboard/Shift.cs
@@ -0,0 +1,28 @@
+using UdonSharp;
+using UnityEngine;
+using VRC.SDKBase;
+using VRC.Udon;
+using VRC.Udon.Common.Interfaces;
+using UnityEngine.UI;
+
+public class ShiftKey : UdonSharpBehaviour
+{
+ public KeyboardManager manager;
+ public Image buttonImage;
+ private bool toggle;
+
+ public void PressKey()
+ {
+ if (toggle)
+ {
+ manager.ShiftOff();
+ toggle = false;
+ buttonImage.color = Color.white;
+ return;
+ }
+
+ manager.ShiftOn();
+ toggle = true;
+ buttonImage.color = Color.blue;
+ }
+}
\ No newline at end of file
diff --git a/Logger.meta b/Logger.meta
deleted file mode 100644
index 3077cfc..0000000
--- a/Logger.meta
+++ /dev/null
@@ -1,8 +0,0 @@
-fileFormatVersion: 2
-guid: 1c01da05d4af97d44b482d6a22b86d73
-folderAsset: yes
-DefaultImporter:
- externalObjects: {}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Logger/LoggerButtons.cs b/Logger/LoggerButtons.cs
new file mode 100644
index 0000000..ad9c7bc
--- /dev/null
+++ b/Logger/LoggerButtons.cs
@@ -0,0 +1,21 @@
+using UdonSharp;
+using UnityEngine;
+using UnityEngine.UI;
+using VRC.SDKBase;
+using VRC.Udon;
+using VRC.Udon.Common.Interfaces;
+
+///A Logger for Udon. Attaches to a player's hand if they're in VR, or sits at some point in space if they're in desktop mode.
+public class LoggerButtons : UdonSharpBehaviour
+{
+ public void Update()
+ {
+ VRCPlayerApi player = Networking.LocalPlayer;
+ if (player != null && player.IsUserInVR())
+ {
+ gameObject.transform.position = player.GetBonePosition(HumanBodyBones.RightHand);
+ gameObject.transform.rotation = player.GetBoneRotation(HumanBodyBones.RightHand);
+ }
+ }
+
+}
diff --git a/Logger/UdonLogger.asset b/Logger/UdonLogger.asset
deleted file mode 100644
index 7c3e3a2..0000000
--- a/Logger/UdonLogger.asset
+++ /dev/null
@@ -1,2623 +0,0 @@
-%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: c333ccfdd0cbdbc4ca30cef2dd6e6b9b, type: 3}
- m_Name: UdonLogger
- m_EditorClassIdentifier:
- serializedUdonProgramAsset: {fileID: 11400000, guid: f21c234380172a642975fb83839f1ae3,
- type: 2}
- udonAssembly: ".data_start\r\n\r\n .export logLinePrefab\r\n .export testObj\r\n
- \ .export logScreen\r\n .export playerUI\r\n .export isDev\r\n\r\n __refl_const_intnl_udonTypeID:
- %SystemInt64, null\r\n __refl_const_intnl_udonTypeName: %SystemString, null\r\n
- \ isDev: %SystemBoolean, null\r\n logScreen: %UnityEngineCanvas, null\r\n
- \ logLinePrefab: %UnityEngineGameObject, null\r\n playerUI: %UnityEngineGameObject,
- null\r\n testObj: %UnityEngineGameObject, null\r\n isActive: %SystemBoolean,
- null\r\n logs: %UnityEngineGameObjectArray, null\r\n count: %SystemInt32,
- null\r\n maxNumberOfLogLines: %SystemInt32, null\r\n update: %SystemSingle,
- null\r\n __0_this_intnl_UdonLogger: %VRCUdonUdonBehaviour, this\r\n __0_newLog_GameObject:
- %UnityEngineGameObject, null\r\n __0_i_Int32: %SystemInt32, null\r\n __0_logTrans_RectTransform:
- %UnityEngineRectTransform, null\r\n __0_transform_RectTransform: %UnityEngineRectTransform,
- null\r\n __0_log_String: %SystemString, null\r\n __0_logString_String: %SystemString,
- null\r\n __0_text_Text: %UnityEngineUIText, null\r\n __0_const_intnl_SystemBoolean:
- %SystemBoolean, null\r\n __1_const_intnl_SystemBoolean: %SystemBoolean, null\r\n
- \ __0_const_intnl_UnityEngineGameObject: %UnityEngineGameObject, null\r\n __0_const_intnl_SystemInt32:
- %SystemInt32, null\r\n __1_const_intnl_SystemInt32: %SystemInt32, null\r\n
- \ __2_const_intnl_SystemInt32: %SystemInt32, null\r\n __3_const_intnl_SystemInt32:
- %SystemInt32, null\r\n __4_const_intnl_SystemInt32: %SystemInt32, null\r\n
- \ __5_const_intnl_SystemInt32: %SystemInt32, null\r\n __6_const_intnl_SystemInt32:
- %SystemInt32, null\r\n __0_const_intnl_SystemObject: %SystemObject, null\r\n
- \ __0_const_intnl_UnityEngineQuaternion: %UnityEngineQuaternion, null\r\n __0_const_intnl_SystemString:
- %SystemString, null\r\n __0_const_intnl_SystemType: %SystemType, null\r\n __1_const_intnl_SystemType:
- %SystemType, null\r\n __0_const_intnl_exitJumpLoc_UInt32: %SystemUInt32, null\r\n
- \ __0_const_intnl_SystemUInt32: %SystemUInt32, null\r\n __1_const_intnl_exitJumpLoc_UInt32:
- %SystemUInt32, null\r\n __2_const_intnl_exitJumpLoc_UInt32: %SystemUInt32,
- null\r\n __0_intnl_SystemBoolean: %SystemBoolean, null\r\n __1_intnl_SystemBoolean:
- %SystemBoolean, null\r\n __2_intnl_SystemBoolean: %SystemBoolean, null\r\n
- \ __3_intnl_SystemBoolean: %SystemBoolean, null\r\n __0_intnl_UnityEngineGameObject:
- %UnityEngineGameObject, null\r\n __1_intnl_UnityEngineGameObject: %UnityEngineGameObject,
- null\r\n __2_intnl_UnityEngineGameObject: %UnityEngineGameObject, null\r\n
- \ __3_intnl_UnityEngineGameObject: %UnityEngineGameObject, null\r\n __4_intnl_UnityEngineGameObject:
- %UnityEngineGameObject, null\r\n __5_intnl_UnityEngineGameObject: %UnityEngineGameObject,
- null\r\n __0_intnl_UnityEngineGameObjectArray: %UnityEngineGameObjectArray,
- null\r\n __1_intnl_UnityEngineGameObjectArray: %UnityEngineGameObjectArray,
- null\r\n __0_intnl_SystemInt32: %SystemInt32, null\r\n __1_intnl_SystemInt32:
- %SystemInt32, null\r\n __2_intnl_SystemInt32: %SystemInt32, null\r\n __3_intnl_SystemInt32:
- %SystemInt32, null\r\n __0_intnl_UnityEngineRectTransform: %UnityEngineRectTransform,
- null\r\n __0_intnl_SystemSingle: %SystemSingle, null\r\n __1_intnl_SystemSingle:
- %SystemSingle, null\r\n __2_intnl_SystemSingle: %SystemSingle, null\r\n __3_intnl_SystemSingle:
- %SystemSingle, null\r\n __4_intnl_SystemSingle: %SystemSingle, null\r\n __5_intnl_SystemSingle:
- %SystemSingle, null\r\n __0_intnl_SystemString: %SystemString, null\r\n __0_intnl_UnityEngineUIText:
- %UnityEngineUIText, null\r\n __0_intnl_UnityEngineTransform: %UnityEngineTransform,
- null\r\n __1_intnl_UnityEngineTransform: %UnityEngineTransform, null\r\n __2_intnl_UnityEngineTransform:
- %UnityEngineTransform, null\r\n __3_intnl_UnityEngineTransform: %UnityEngineTransform,
- null\r\n __0_intnl_oldReturnLoc_UInt32: %SystemUInt32, null\r\n __0_intnl_returnTarget_UInt32:
- %SystemUInt32, null\r\n __1_intnl_oldReturnLoc_UInt32: %SystemUInt32, null\r\n
- \ __0_intnl_UnityEngineVector3: %UnityEngineVector3, null\r\n __1_intnl_UnityEngineVector3:
- %UnityEngineVector3, null\r\n\r\n.data_end\r\n\r\n \r\n # using
- UdonSharp;\r\n \r\n # using UnityEngine;\r\n \r\n #
- using UnityEngine.UI;\r\n \r\n # using VRC.SDKBase;\r\n \r\n
- \ # using VRC.Udon;\r\n \r\n # using VRC.Udon.Common.Interfaces;\r\n
- \ \r\n # public class UdonLogger : UdonSharpBehaviour\r\n.code_start\r\n
- \ \r\n # public GameObject logLinePrefab;\r\n \r\n #
- public GameObject testObj;\r\n \r\n # public Canvas logScreen;\r\n
- \ \r\n # public GameObject playerUI;\r\n \r\n # public
- bool isDev;\r\n \r\n # private bool isActive;\r\n \r\n #
- private int maxNumberOfLogLines;\r\n \r\n # private GameObject[]
- logs;\r\n \r\n # private float update;\r\n \r\n #
- private int count;\r\n \r\n # void Start()\r\n .export _start\r\n
- \ \r\n _start:\r\n \r\n PUSH, __0_const_intnl_SystemUInt32\r\n
- \ PUSH, __0_intnl_returnTarget_UInt32\r\n COPY\r\n \r\n #
- {\r\n \r\n # count = 0;\r\n PUSH, __0_const_intnl_SystemInt32\r\n
- \ PUSH, count\r\n COPY\r\n \r\n # maxNumberOfLogLines
- = 5;\r\n PUSH, __1_const_intnl_SystemInt32\r\n PUSH, maxNumberOfLogLines\r\n
- \ COPY\r\n \r\n # logs = new GameObject[maxNumberOfLogLines];\r\n
- \ PUSH, maxNumberOfLogLines\r\n PUSH, __1_intnl_UnityEngineGameObjectArray\r\n
- \ EXTERN, \"UnityEngineGameObjectArray.__ctor__SystemInt32__UnityEngineGameObjectArray\"\r\n
- \ PUSH, __1_intnl_UnityEngineGameObjectArray\r\n PUSH, __0_intnl_UnityEngineGameObjectArray\r\n
- \ COPY\r\n PUSH, __0_intnl_UnityEngineGameObjectArray\r\n PUSH,
- logs\r\n COPY\r\n JUMP_INDIRECT, __0_intnl_returnTarget_UInt32\r\n
- \ \r\n \r\n # public void Update()\r\n .export _update\r\n
- \ \r\n _update:\r\n \r\n PUSH, __0_const_intnl_SystemUInt32\r\n
- \ PUSH, __0_intnl_returnTarget_UInt32\r\n COPY\r\n \r\n #
- {\r\n JUMP_INDIRECT, __0_intnl_returnTarget_UInt32\r\n \r\n \r\n
- \ # public void Toggle()\r\n .export Toggle\r\n \r\n Toggle:\r\n
- \ \r\n PUSH, __0_const_intnl_SystemUInt32\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ COPY\r\n \r\n # {\r\n \r\n # if (isActive
- == true)\r\n PUSH, isActive\r\n PUSH, __0_const_intnl_SystemBoolean\r\n
- \ PUSH, __0_intnl_SystemBoolean\r\n EXTERN, \"SystemBoolean.__op_Equality__SystemBoolean_SystemBoolean__SystemBoolean\"\r\n
- \ PUSH, __0_intnl_SystemBoolean\r\n JUMP_IF_FALSE, 0x00000130\r\n
- \ \r\n # {\r\n \r\n # Hide();\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ PUSH, __0_intnl_oldReturnLoc_UInt32\r\n COPY\r\n PUSH, __0_const_intnl_exitJumpLoc_UInt32\r\n
- \ PUSH, __0_intnl_returnTarget_UInt32\r\n COPY\r\n JUMP, 0x00000190\r\n
- \ PUSH, __0_intnl_oldReturnLoc_UInt32\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ COPY\r\n JUMP, 0x00000174\r\n \r\n # else\r\n \r\n
- \ # {\r\n \r\n # Show();\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ PUSH, __0_intnl_oldReturnLoc_UInt32\r\n COPY\r\n PUSH, __1_const_intnl_exitJumpLoc_UInt32\r\n
- \ PUSH, __0_intnl_returnTarget_UInt32\r\n COPY\r\n JUMP, 0x000001F0\r\n
- \ PUSH, __0_intnl_oldReturnLoc_UInt32\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ COPY\r\n JUMP_INDIRECT, __0_intnl_returnTarget_UInt32\r\n \r\n
- \ \r\n # private void Hide()\r\n Hide:\r\n \r\n PUSH,
- __0_const_intnl_SystemUInt32\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ COPY\r\n \r\n # {\r\n \r\n # logScreen.gameObject.SetActive(false);\r\n
- \ PUSH, logScreen\r\n PUSH, __0_intnl_UnityEngineGameObject\r\n EXTERN,
- \"UnityEngineCanvas.__get_gameObject__UnityEngineGameObject\"\r\n PUSH,
- __0_intnl_UnityEngineGameObject\r\n PUSH, __1_const_intnl_SystemBoolean\r\n
- \ EXTERN, \"UnityEngineGameObject.__SetActive__SystemBoolean__SystemVoid\"\r\n
- \ \r\n # isActive = false;\r\n PUSH, __1_const_intnl_SystemBoolean\r\n
- \ PUSH, isActive\r\n COPY\r\n JUMP_INDIRECT, __0_intnl_returnTarget_UInt32\r\n
- \ \r\n \r\n # private void Show()\r\n Show:\r\n \r\n
- \ PUSH, __0_const_intnl_SystemUInt32\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ COPY\r\n \r\n # {\r\n \r\n # logScreen.gameObject.SetActive(true);\r\n
- \ PUSH, logScreen\r\n PUSH, __1_intnl_UnityEngineGameObject\r\n EXTERN,
- \"UnityEngineCanvas.__get_gameObject__UnityEngineGameObject\"\r\n PUSH,
- __1_intnl_UnityEngineGameObject\r\n PUSH, __0_const_intnl_SystemBoolean\r\n
- \ EXTERN, \"UnityEngineGameObject.__SetActive__SystemBoolean__SystemVoid\"\r\n
- \ \r\n # isActive = true;\r\n PUSH, __0_const_intnl_SystemBoolean\r\n
- \ PUSH, isActive\r\n COPY\r\n JUMP_INDIRECT, __0_intnl_returnTarget_UInt32\r\n
- \ \r\n \r\n # public void Notice(string log)\r\n .export
- Notice\r\n \r\n Notice:\r\n \r\n PUSH, __0_const_intnl_SystemUInt32\r\n
- \ PUSH, __0_intnl_returnTarget_UInt32\r\n COPY\r\n \r\n #
- {\r\n \r\n # Debug.Log(\"Updating log to say: \" + log);\r\n PUSH,
- __0_const_intnl_SystemString\r\n PUSH, __0_log_String\r\n PUSH,
- __0_intnl_SystemString\r\n EXTERN, \"SystemString.__op_Addition__SystemString_SystemString__SystemString\"\r\n
- \ PUSH, __0_intnl_SystemString\r\n EXTERN, \"UnityEngineDebug.__Log__SystemObject__SystemVoid\"\r\n
- \ \r\n # UpdateLog(log);\r\n PUSH, __0_log_String\r\n PUSH,
- __0_logString_String\r\n COPY\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ PUSH, __1_intnl_oldReturnLoc_UInt32\r\n COPY\r\n PUSH, __2_const_intnl_exitJumpLoc_UInt32\r\n
- \ PUSH, __0_intnl_returnTarget_UInt32\r\n COPY\r\n JUMP, 0x000002F4\r\n
- \ PUSH, __1_intnl_oldReturnLoc_UInt32\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ COPY\r\n JUMP_INDIRECT, __0_intnl_returnTarget_UInt32\r\n \r\n
- \ \r\n # private void UpdateLog(string logString)\r\n UpdateLog:\r\n
- \ \r\n PUSH, __0_const_intnl_SystemUInt32\r\n PUSH, __0_intnl_returnTarget_UInt32\r\n
- \ COPY\r\n \r\n # {\r\n \r\n # if (logs[4]
- != null)\r\n PUSH, logs\r\n PUSH, __2_const_intnl_SystemInt32\r\n
- \ PUSH, __2_intnl_UnityEngineGameObject\r\n EXTERN, \"UnityEngineGameObjectArray.__Get__SystemInt32__UnityEngineGameObject\"\r\n
- \ PUSH, __2_intnl_UnityEngineGameObject\r\n PUSH, __0_const_intnl_UnityEngineGameObject\r\n
- \ PUSH, __1_intnl_SystemBoolean\r\n EXTERN, \"UnityEngineObject.__op_Inequality__UnityEngineObject_UnityEngineObject__SystemBoolean\"\r\n
- \ PUSH, __1_intnl_SystemBoolean\r\n JUMP_IF_FALSE, 0x00000394\r\n
- \ \r\n # {\r\n \r\n # Destroy(logs[4]);\r\n PUSH,
- logs\r\n PUSH, __2_const_intnl_SystemInt32\r\n PUSH, __3_intnl_UnityEngineGameObject\r\n
- \ EXTERN, \"UnityEngineGameObjectArray.__Get__SystemInt32__UnityEngineGameObject\"\r\n
- \ PUSH, __3_intnl_UnityEngineGameObject\r\n EXTERN, \"UnityEngineObject.__Destroy__UnityEngineObject__SystemVoid\"\r\n
- \ \r\n # logs[4] = null;\r\n PUSH, logs\r\n PUSH,
- __2_const_intnl_SystemInt32\r\n PUSH, __0_const_intnl_SystemObject\r\n
- \ EXTERN, \"UnityEngineGameObjectArray.__Set__SystemInt32_UnityEngineGameObject__SystemVoid\"\r\n
- \ \r\n # for (int i = maxNumberOfLogLines - 2; i > -1; i--)\r\n
- \ PUSH, maxNumberOfLogLines\r\n PUSH, __3_const_intnl_SystemInt32\r\n
- \ PUSH, __0_intnl_SystemInt32\r\n EXTERN, \"SystemInt32.__op_Subtraction__SystemInt32_SystemInt32__SystemInt32\"\r\n
- \ PUSH, __0_intnl_SystemInt32\r\n PUSH, __0_i_Int32\r\n COPY\r\n
- \ PUSH, __4_const_intnl_SystemInt32\r\n PUSH, __1_intnl_SystemInt32\r\n
- \ EXTERN, \"SystemInt32.__op_UnaryMinus__SystemInt32__SystemInt32\"\r\n
- \ PUSH, __0_i_Int32\r\n PUSH, __1_intnl_SystemInt32\r\n PUSH,
- __2_intnl_SystemBoolean\r\n EXTERN, \"SystemInt32.__op_GreaterThan__SystemInt32_SystemInt32__SystemBoolean\"\r\n
- \ PUSH, __2_intnl_SystemBoolean\r\n JUMP_IF_FALSE, 0x0000066C\r\n
- \ \r\n # {\r\n \r\n # if (logs[i] != null)\r\n PUSH,
- logs\r\n PUSH, __0_i_Int32\r\n PUSH, __3_intnl_UnityEngineGameObject\r\n
- \ EXTERN, \"UnityEngineGameObjectArray.__Get__SystemInt32__UnityEngineGameObject\"\r\n
- \ PUSH, __3_intnl_UnityEngineGameObject\r\n PUSH, __0_const_intnl_UnityEngineGameObject\r\n
- \ PUSH, __3_intnl_SystemBoolean\r\n EXTERN, \"UnityEngineObject.__op_Inequality__UnityEngineObject_UnityEngineObject__SystemBoolean\"\r\n
- \ PUSH, __3_intnl_SystemBoolean\r\n JUMP_IF_FALSE, 0x0000061C\r\n
- \ \r\n # {\r\n \r\n # RectTransform logTrans = logs[i].GetComponent();\r\n
- \ PUSH, logs\r\n PUSH, __0_i_Int32\r\n PUSH, __4_intnl_UnityEngineGameObject\r\n
- \ EXTERN, \"UnityEngineGameObjectArray.__Get__SystemInt32__UnityEngineGameObject\"\r\n
- \ PUSH, __4_intnl_UnityEngineGameObject\r\n PUSH, __0_intnl_UnityEngineTransform\r\n
- \ EXTERN, \"UnityEngineGameObject.__get_transform__UnityEngineTransform\"\r\n
- \ PUSH, __0_intnl_UnityEngineTransform\r\n PUSH, __0_const_intnl_SystemType\r\n
- \ PUSH, __0_intnl_UnityEngineRectTransform\r\n EXTERN, \"UnityEngineRectTransform.__GetComponent__T\"\r\n
- \ PUSH, __0_intnl_UnityEngineRectTransform\r\n PUSH, __0_logTrans_RectTransform\r\n
- \ COPY\r\n \r\n # logTrans.anchoredPosition3D = new Vector3(0,
- logTrans.anchoredPosition3D.y + 200, -1);\r\n PUSH, __0_logTrans_RectTransform\r\n
- \ PUSH, __0_intnl_UnityEngineVector3\r\n EXTERN, \"UnityEngineRectTransform.__get_anchoredPosition3D__UnityEngineVector3\"\r\n
- \ PUSH, __0_intnl_UnityEngineVector3\r\n PUSH, __0_intnl_SystemSingle\r\n
- \ EXTERN, \"UnityEngineVector3.__get_y__SystemSingle\"\r\n PUSH,
- __5_const_intnl_SystemInt32\r\n PUSH, __1_intnl_SystemSingle\r\n EXTERN,
- \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n PUSH, __0_intnl_SystemSingle\r\n
- \ PUSH, __1_intnl_SystemSingle\r\n PUSH, __2_intnl_SystemSingle\r\n
- \ EXTERN, \"SystemSingle.__op_Addition__SystemSingle_SystemSingle__SystemSingle\"\r\n
- \ PUSH, __4_const_intnl_SystemInt32\r\n PUSH, __2_intnl_SystemInt32\r\n
- \ EXTERN, \"SystemInt32.__op_UnaryMinus__SystemInt32__SystemInt32\"\r\n
- \ PUSH, __0_const_intnl_SystemInt32\r\n PUSH, __3_intnl_SystemSingle\r\n
- \ EXTERN, \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n PUSH,
- __2_intnl_SystemInt32\r\n PUSH, __4_intnl_SystemSingle\r\n EXTERN,
- \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n PUSH, __3_intnl_SystemSingle\r\n
- \ PUSH, __2_intnl_SystemSingle\r\n PUSH, __4_intnl_SystemSingle\r\n
- \ PUSH, __1_intnl_UnityEngineVector3\r\n EXTERN, \"UnityEngineVector3.__ctor__SystemSingle_SystemSingle_SystemSingle__UnityEngineVector3\"\r\n
- \ PUSH, __0_logTrans_RectTransform\r\n PUSH, __1_intnl_UnityEngineVector3\r\n
- \ EXTERN, \"UnityEngineRectTransform.__set_anchoredPosition3D__UnityEngineVector3__SystemVoid\"\r\n
- \ \r\n # logs[i + 1] = logs[i];\r\n PUSH, logs\r\n PUSH,
- __0_i_Int32\r\n PUSH, __5_intnl_UnityEngineGameObject\r\n EXTERN,
- \"UnityEngineGameObjectArray.__Get__SystemInt32__UnityEngineGameObject\"\r\n PUSH,
- __0_i_Int32\r\n PUSH, __4_const_intnl_SystemInt32\r\n PUSH, __3_intnl_SystemInt32\r\n
- \ EXTERN, \"SystemInt32.__op_Addition__SystemInt32_SystemInt32__SystemInt32\"\r\n
- \ PUSH, logs\r\n PUSH, __3_intnl_SystemInt32\r\n PUSH, __5_intnl_UnityEngineGameObject\r\n
- \ EXTERN, \"UnityEngineGameObjectArray.__Set__SystemInt32_UnityEngineGameObject__SystemVoid\"\r\n
- \ PUSH, __0_i_Int32\r\n PUSH, __2_intnl_SystemInt32\r\n COPY\r\n
- \ PUSH, __0_i_Int32\r\n PUSH, __4_const_intnl_SystemInt32\r\n PUSH,
- __3_intnl_SystemInt32\r\n EXTERN, \"SystemInt32.__op_Subtraction__SystemInt32_SystemInt32__SystemInt32\"\r\n
- \ PUSH, __3_intnl_SystemInt32\r\n PUSH, __0_i_Int32\r\n COPY\r\n
- \ JUMP, 0x000003C8\r\n \r\n # GameObject newLog = VRCInstantiate(logLinePrefab);\r\n
- \ PUSH, logLinePrefab\r\n PUSH, __3_intnl_UnityEngineGameObject\r\n
- \ EXTERN, \"VRCInstantiate.__Instantiate__UnityEngineGameObject__UnityEngineGameObject\"\r\n
- \ PUSH, __3_intnl_UnityEngineGameObject\r\n PUSH, __0_newLog_GameObject\r\n
- \ COPY\r\n \r\n # Text text = newLog.GetComponent();\r\n
- \ PUSH, __0_newLog_GameObject\r\n PUSH, __0_intnl_UnityEngineTransform\r\n
- \ EXTERN, \"UnityEngineGameObject.__get_transform__UnityEngineTransform\"\r\n
- \ PUSH, __0_intnl_UnityEngineTransform\r\n PUSH, __1_const_intnl_SystemType\r\n
- \ PUSH, __0_intnl_UnityEngineUIText\r\n EXTERN, \"UnityEngineUIText.__GetComponent__T\"\r\n
- \ PUSH, __0_intnl_UnityEngineUIText\r\n PUSH, __0_text_Text\r\n COPY\r\n
- \ \r\n # text.text = logString;\r\n PUSH, __0_text_Text\r\n
- \ PUSH, __0_logString_String\r\n EXTERN, \"UnityEngineUIText.__set_text__SystemString__SystemVoid\"\r\n
- \ \r\n # logs[0] = newLog;\r\n PUSH, logs\r\n PUSH,
- __0_const_intnl_SystemInt32\r\n PUSH, __0_newLog_GameObject\r\n EXTERN,
- \"UnityEngineGameObjectArray.__Set__SystemInt32_UnityEngineGameObject__SystemVoid\"\r\n
- \ \r\n # newLog.transform.SetParent(logScreen.transform);\r\n PUSH,
- logScreen\r\n PUSH, __1_intnl_UnityEngineTransform\r\n EXTERN, \"UnityEngineCanvas.__get_transform__UnityEngineTransform\"\r\n
- \ PUSH, __0_newLog_GameObject\r\n PUSH, __2_intnl_UnityEngineTransform\r\n
- \ EXTERN, \"UnityEngineGameObject.__get_transform__UnityEngineTransform\"\r\n
- \ PUSH, __2_intnl_UnityEngineTransform\r\n PUSH, __1_intnl_UnityEngineTransform\r\n
- \ EXTERN, \"UnityEngineTransform.__SetParent__UnityEngineTransform__SystemVoid\"\r\n
- \ \r\n # RectTransform transform = newLog.GetComponent();\r\n
- \ PUSH, __0_newLog_GameObject\r\n PUSH, __3_intnl_UnityEngineTransform\r\n
- \ EXTERN, \"UnityEngineGameObject.__get_transform__UnityEngineTransform\"\r\n
- \ PUSH, __3_intnl_UnityEngineTransform\r\n PUSH, __0_const_intnl_SystemType\r\n
- \ PUSH, __0_intnl_UnityEngineRectTransform\r\n EXTERN, \"UnityEngineRectTransform.__GetComponent__T\"\r\n
- \ PUSH, __0_intnl_UnityEngineRectTransform\r\n PUSH, __0_transform_RectTransform\r\n
- \ COPY\r\n \r\n # transform.anchoredPosition3D = new Vector3(0,
- 300, -1);\r\n PUSH, __4_const_intnl_SystemInt32\r\n PUSH, __0_intnl_SystemInt32\r\n
- \ EXTERN, \"SystemInt32.__op_UnaryMinus__SystemInt32__SystemInt32\"\r\n
- \ PUSH, __0_const_intnl_SystemInt32\r\n PUSH, __0_intnl_SystemSingle\r\n
- \ EXTERN, \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n PUSH,
- __6_const_intnl_SystemInt32\r\n PUSH, __1_intnl_SystemSingle\r\n EXTERN,
- \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n PUSH, __0_intnl_SystemInt32\r\n
- \ PUSH, __2_intnl_SystemSingle\r\n EXTERN, \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n
- \ PUSH, __0_intnl_SystemSingle\r\n PUSH, __1_intnl_SystemSingle\r\n
- \ PUSH, __2_intnl_SystemSingle\r\n PUSH, __0_intnl_UnityEngineVector3\r\n
- \ EXTERN, \"UnityEngineVector3.__ctor__SystemSingle_SystemSingle_SystemSingle__UnityEngineVector3\"\r\n
- \ PUSH, __0_transform_RectTransform\r\n PUSH, __0_intnl_UnityEngineVector3\r\n
- \ EXTERN, \"UnityEngineRectTransform.__set_anchoredPosition3D__UnityEngineVector3__SystemVoid\"\r\n
- \ \r\n # transform.localRotation = new Quaternion();\r\n PUSH,
- __0_transform_RectTransform\r\n PUSH, __0_const_intnl_UnityEngineQuaternion\r\n
- \ EXTERN, \"UnityEngineRectTransform.__set_localRotation__UnityEngineQuaternion__SystemVoid\"\r\n
- \ \r\n # transform.localScale = new Vector3(1, 1, 1);\r\n PUSH,
- __4_const_intnl_SystemInt32\r\n PUSH, __3_intnl_SystemSingle\r\n EXTERN,
- \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n PUSH, __4_const_intnl_SystemInt32\r\n
- \ PUSH, __4_intnl_SystemSingle\r\n EXTERN, \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n
- \ PUSH, __4_const_intnl_SystemInt32\r\n PUSH, __5_intnl_SystemSingle\r\n
- \ EXTERN, \"SystemConvert.__ToSingle__SystemInt32__SystemSingle\"\r\n PUSH,
- __3_intnl_SystemSingle\r\n PUSH, __4_intnl_SystemSingle\r\n PUSH,
- __5_intnl_SystemSingle\r\n PUSH, __1_intnl_UnityEngineVector3\r\n EXTERN,
- \"UnityEngineVector3.__ctor__SystemSingle_SystemSingle_SystemSingle__UnityEngineVector3\"\r\n
- \ PUSH, __0_transform_RectTransform\r\n PUSH, __1_intnl_UnityEngineVector3\r\n
- \ EXTERN, \"UnityEngineRectTransform.__set_localScale__UnityEngineVector3__SystemVoid\"\r\n
- \ JUMP_INDIRECT, __0_intnl_returnTarget_UInt32\r\n \r\n.code_end\r\n"
- assemblyError:
- sourceCsScript: {fileID: 11500000, guid: 75074386178276344969fc58ae293549, type: 3}
- behaviourIDHeapVarName: __refl_const_intnl_udonTypeID
- compileErrors: []
- debugInfo:
- serializedDebugSpans:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 0
- endSourceChar: 521
- line: 0
- lineChar: 0
- spanCodeSection: "// Logger for Udon\r\n\r\n// This system maintains a log event
- system in Udon, similar to normal logging systems.\r\n// It has four levels:
- error, warning, info and notice.\r\n// Error: something has gone fatally wrong
- and the behaviour needs to terminate.\r\n// Warning: something is probably
- wrong and the developer might want to know about it.\r\n// Info: A view's
- state has changed and a deloper might want to know about it.\r\n// Notice:
- A view's state has changed and anyone - including a player - might want to
- know about it. \r\n"
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 521
- endSourceChar: 521
- line: 8
- lineChar: 0
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 521
- endSourceChar: 527
- line: 8
- lineChar: 0
- spanCodeSection: 'using '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 527
- endSourceChar: 539
- line: 8
- lineChar: 6
- spanCodeSection: "UdonSharp;\r\n"
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 539
- endSourceChar: 545
- line: 9
- lineChar: 0
- spanCodeSection: 'using '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 545
- endSourceChar: 559
- line: 9
- lineChar: 6
- spanCodeSection: "UnityEngine;\r\n"
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 559
- endSourceChar: 565
- line: 10
- lineChar: 0
- spanCodeSection: 'using '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 565
- endSourceChar: 565
- line: 10
- lineChar: 6
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 565
- endSourceChar: 577
- line: 10
- lineChar: 6
- spanCodeSection: UnityEngine.
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 577
- endSourceChar: 582
- line: 10
- lineChar: 18
- spanCodeSection: "UI;\r\n"
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 582
- endSourceChar: 588
- line: 11
- lineChar: 0
- spanCodeSection: 'using '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 588
- endSourceChar: 588
- line: 11
- lineChar: 6
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 588
- endSourceChar: 592
- line: 11
- lineChar: 6
- spanCodeSection: VRC.
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 592
- endSourceChar: 602
- line: 11
- lineChar: 10
- spanCodeSection: "SDKBase;\r\n"
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 602
- endSourceChar: 608
- line: 12
- lineChar: 0
- spanCodeSection: 'using '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 608
- endSourceChar: 608
- line: 12
- lineChar: 6
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 608
- endSourceChar: 612
- line: 12
- lineChar: 6
- spanCodeSection: VRC.
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 612
- endSourceChar: 619
- line: 12
- lineChar: 10
- spanCodeSection: "Udon;\r\n"
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 619
- endSourceChar: 625
- line: 13
- lineChar: 0
- spanCodeSection: 'using '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 625
- endSourceChar: 625
- line: 13
- lineChar: 6
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 625
- endSourceChar: 625
- line: 13
- lineChar: 6
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 625
- endSourceChar: 625
- line: 13
- lineChar: 6
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 625
- endSourceChar: 629
- line: 13
- lineChar: 6
- spanCodeSection: VRC.
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 629
- endSourceChar: 634
- line: 13
- lineChar: 10
- spanCodeSection: Udon.
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 634
- endSourceChar: 641
- line: 13
- lineChar: 15
- spanCodeSection: Common.
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 641
- endSourceChar: 656
- line: 13
- lineChar: 22
- spanCodeSection: "Interfaces;\r\n\r\n"
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 656
- endSourceChar: 680
- line: 15
- lineChar: 0
- spanCodeSection: 'public class UdonLogger '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 680
- endSourceChar: 682
- line: 15
- lineChar: 24
- spanCodeSection: ': '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 682
- endSourceChar: 682
- line: 15
- lineChar: 26
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 682
- endSourceChar: 709
- line: 15
- lineChar: 26
- spanCodeSection: "UdonSharpBehaviour\r\n{\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 709
- endSourceChar: 716
- line: 17
- lineChar: 4
- spanCodeSection: 'public '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 716
- endSourceChar: 716
- line: 17
- lineChar: 11
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 716
- endSourceChar: 747
- line: 17
- lineChar: 11
- spanCodeSection: "GameObject logLinePrefab;\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 747
- endSourceChar: 754
- line: 18
- lineChar: 4
- spanCodeSection: 'public '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 754
- endSourceChar: 754
- line: 18
- lineChar: 11
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 754
- endSourceChar: 779
- line: 18
- lineChar: 11
- spanCodeSection: "GameObject testObj;\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 779
- endSourceChar: 786
- line: 19
- lineChar: 4
- spanCodeSection: 'public '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 786
- endSourceChar: 786
- line: 19
- lineChar: 11
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 786
- endSourceChar: 809
- line: 19
- lineChar: 11
- spanCodeSection: "Canvas logScreen;\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 809
- endSourceChar: 816
- line: 20
- lineChar: 4
- spanCodeSection: 'public '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 816
- endSourceChar: 816
- line: 20
- lineChar: 11
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 816
- endSourceChar: 844
- line: 20
- lineChar: 11
- spanCodeSection: "GameObject playerUI;\r\n\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 844
- endSourceChar: 851
- line: 22
- lineChar: 4
- spanCodeSection: 'public '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 851
- endSourceChar: 851
- line: 22
- lineChar: 11
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 851
- endSourceChar: 870
- line: 22
- lineChar: 11
- spanCodeSection: "bool isDev;\r\n\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 870
- endSourceChar: 878
- line: 24
- lineChar: 4
- spanCodeSection: 'private '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 878
- endSourceChar: 878
- line: 24
- lineChar: 12
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 878
- endSourceChar: 1181
- line: 24
- lineChar: 12
- spanCodeSection: "bool isActive;\r\n\r\n // [UdonSynced]\r\n // private
- string latestError;\r\n // private string lastError;\r\n\r\n // [UdonSynced]\r\n
- \ // private string latestWarning;\r\n // private string lastWarning;\r\n\r\n
- \ // [UdonSynced]\r\n // private string latestInfo;\r\n // private
- string lastInfo;\r\n\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1181
- endSourceChar: 1189
- line: 38
- lineChar: 4
- spanCodeSection: 'private '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1189
- endSourceChar: 1189
- line: 38
- lineChar: 12
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1189
- endSourceChar: 1219
- line: 38
- lineChar: 12
- spanCodeSection: "int maxNumberOfLogLines;\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1219
- endSourceChar: 1227
- line: 39
- lineChar: 4
- spanCodeSection: 'private '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1227
- endSourceChar: 1227
- line: 39
- lineChar: 12
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1227
- endSourceChar: 1227
- line: 39
- lineChar: 12
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1227
- endSourceChar: 1253
- line: 39
- lineChar: 12
- spanCodeSection: "GameObject[] logs;\r\n\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1253
- endSourceChar: 1261
- line: 41
- lineChar: 4
- spanCodeSection: 'private '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1261
- endSourceChar: 1261
- line: 41
- lineChar: 12
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1261
- endSourceChar: 1282
- line: 41
- lineChar: 12
- spanCodeSection: "float update;\r\n\r\n "
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1282
- endSourceChar: 1290
- line: 43
- lineChar: 4
- spanCodeSection: 'private '
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1290
- endSourceChar: 1290
- line: 43
- lineChar: 12
- spanCodeSection:
- - startInstruction: 0
- endInstruction: -1
- startSourceChar: 1290
- endSourceChar: 1308
- line: 43
- lineChar: 12
- spanCodeSection: "int count;\r\n\r\n "
- - startInstruction: 0
- endInstruction: 19
- startSourceChar: 1308
- endSourceChar: 1326
- line: 45
- lineChar: 4
- spanCodeSection: "void Start()\r\n "
- - startInstruction: 20
- endInstruction: 19
- startSourceChar: 1326
- endSourceChar: 1356
- line: 46
- lineChar: 4
- spanCodeSection: "{\r\n //Hide();\r\n "
- - startInstruction: 20
- endInstruction: 19
- startSourceChar: 1356
- endSourceChar: 1356
- line: 48
- lineChar: 8
- spanCodeSection:
- - startInstruction: 20
- endInstruction: 19
- startSourceChar: 1356
- endSourceChar: 1364
- line: 48
- lineChar: 8
- spanCodeSection: 'count = '
- - startInstruction: 20
- endInstruction: 39
- startSourceChar: 1364
- endSourceChar: 1376
- line: 48
- lineChar: 16
- spanCodeSection: "0;\r\n "
- - startInstruction: 40
- endInstruction: 39
- startSourceChar: 1376
- endSourceChar: 1376
- line: 49
- lineChar: 8
- spanCodeSection:
- - startInstruction: 40
- endInstruction: 39
- startSourceChar: 1376
- endSourceChar: 1398
- line: 49
- lineChar: 8
- spanCodeSection: 'maxNumberOfLogLines = '
- - startInstruction: 40
- endInstruction: 59
- startSourceChar: 1398
- endSourceChar: 1410
- line: 49
- lineChar: 30
- spanCodeSection: "5;\r\n "
- - startInstruction: 60
- endInstruction: 59
- startSourceChar: 1410
- endSourceChar: 1410
- line: 50
- lineChar: 8
- spanCodeSection:
- - startInstruction: 60
- endInstruction: 59
- startSourceChar: 1410
- endSourceChar: 1417
- line: 50
- lineChar: 8
- spanCodeSection: 'logs = '
- - startInstruction: 60
- endInstruction: 59
- startSourceChar: 1417
- endSourceChar: 1421
- line: 50
- lineChar: 15
- spanCodeSection: 'new '
- - startInstruction: 60
- endInstruction: 59
- startSourceChar: 1421
- endSourceChar: 1421
- line: 50
- lineChar: 19
- spanCodeSection:
- - startInstruction: 60
- endInstruction: 59
- startSourceChar: 1421
- endSourceChar: 1431
- line: 50
- lineChar: 19
- spanCodeSection: GameObject
- - startInstruction: 60
- endInstruction: 59
- startSourceChar: 1431
- endSourceChar: 1432
- line: 50
- lineChar: 29
- spanCodeSection: '['
- - startInstruction: 60
- endInstruction: 131
- startSourceChar: 1432
- endSourceChar: 1468
- line: 50
- lineChar: 30
- spanCodeSection: "maxNumberOfLogLines];\r\n }\r\n\r\n "
- - startInstruction: 132
- endInstruction: 151
- startSourceChar: 1468
- endSourceChar: 1494
- line: 53
- lineChar: 4
- spanCodeSection: "public void Update()\r\n "
- - startInstruction: 152
- endInstruction: 159
- startSourceChar: 1494
- endSourceChar: 1810
- line: 54
- lineChar: 4
- spanCodeSection: "{\r\n // if (Networking.LocalPlayer != null)\r\n //
- {\r\n // playerUI.transform.position = Networking.LocalPlayer.GetBonePosition(HumanBodyBones.RightHand);\r\n
- \ // playerUI.transform.rotation = Networking.LocalPlayer.GetBoneRotation(HumanBodyBones.RightHand);\r\n
- \ // }\r\n }\r\n\r\n "
- - startInstruction: 160
- endInstruction: 179
- startSourceChar: 1810
- endSourceChar: 1836
- line: 62
- lineChar: 4
- spanCodeSection: "public void Toggle()\r\n "
- - startInstruction: 180
- endInstruction: 179
- startSourceChar: 1836
- endSourceChar: 1847
- line: 63
- lineChar: 4
- spanCodeSection: "{\r\n "
- - startInstruction: 180
- endInstruction: 179
- startSourceChar: 1847
- endSourceChar: 1851
- line: 64
- lineChar: 8
- spanCodeSection: if (
- - startInstruction: 180
- endInstruction: 179
- startSourceChar: 1851
- endSourceChar: 1863
- line: 64
- lineChar: 12
- spanCodeSection: 'isActive == '
- - startInstruction: 180
- endInstruction: 227
- startSourceChar: 1863
- endSourceChar: 1878
- line: 64
- lineChar: 24
- spanCodeSection: "true)\r\n "
- - startInstruction: 228
- endInstruction: 227
- startSourceChar: 1878
- endSourceChar: 1893
- line: 65
- lineChar: 8
- spanCodeSection: "{\r\n "
- - startInstruction: 228
- endInstruction: 227
- startSourceChar: 1893
- endSourceChar: 1893
- line: 66
- lineChar: 12
- spanCodeSection:
- - startInstruction: 228
- endInstruction: 227
- startSourceChar: 1893
- endSourceChar: 1893
- line: 66
- lineChar: 12
- spanCodeSection:
- - startInstruction: 228
- endInstruction: 303
- startSourceChar: 1893
- endSourceChar: 1921
- line: 66
- lineChar: 12
- spanCodeSection: "Hide();\r\n }\r\n "
- - startInstruction: 304
- endInstruction: 303
- startSourceChar: 1921
- endSourceChar: 1935
- line: 68
- lineChar: 8
- spanCodeSection: "else\r\n "
- - startInstruction: 304
- endInstruction: 303
- startSourceChar: 1935
- endSourceChar: 1950
- line: 69
- lineChar: 8
- spanCodeSection: "{\r\n "
- - startInstruction: 304
- endInstruction: 303
- startSourceChar: 1950
- endSourceChar: 1950
- line: 70
- lineChar: 12
- spanCodeSection:
- - startInstruction: 304
- endInstruction: 303
- startSourceChar: 1950
- endSourceChar: 1950
- line: 70
- lineChar: 12
- spanCodeSection:
- - startInstruction: 304
- endInstruction: 379
- startSourceChar: 1950
- endSourceChar: 1983
- line: 70
- lineChar: 12
- spanCodeSection: "Show();\r\n }\r\n }\r\n\r\n "
- - startInstruction: 380
- endInstruction: 399
- startSourceChar: 1983
- endSourceChar: 2008
- line: 74
- lineChar: 4
- spanCodeSection: "private void Hide()\r\n "
- - startInstruction: 400
- endInstruction: 399
- startSourceChar: 2008
- endSourceChar: 2019
- line: 75
- lineChar: 4
- spanCodeSection: "{\r\n "
- - startInstruction: 400
- endInstruction: 399
- startSourceChar: 2019
- endSourceChar: 2019
- line: 76
- lineChar: 8
- spanCodeSection:
- - startInstruction: 400
- endInstruction: 399
- startSourceChar: 2019
- endSourceChar: 2050
- line: 76
- lineChar: 8
- spanCodeSection: logScreen.gameObject.SetActive(
- - startInstruction: 400
- endInstruction: 447
- startSourceChar: 2050
- endSourceChar: 2067
- line: 76
- lineChar: 39
- spanCodeSection: "false);\r\n "
- - startInstruction: 448
- endInstruction: 447
- startSourceChar: 2067
- endSourceChar: 2067
- line: 77
- lineChar: 8
- spanCodeSection:
- - startInstruction: 448
- endInstruction: 447
- startSourceChar: 2067
- endSourceChar: 2078
- line: 77
- lineChar: 8
- spanCodeSection: 'isActive = '
- - startInstruction: 448
- endInstruction: 475
- startSourceChar: 2078
- endSourceChar: 2099
- line: 77
- lineChar: 19
- spanCodeSection: "false;\r\n }\r\n\r\n "
- - startInstruction: 476
- endInstruction: 495
- startSourceChar: 2099
- endSourceChar: 2124
- line: 80
- lineChar: 4
- spanCodeSection: "private void Show()\r\n "
- - startInstruction: 496
- endInstruction: 495
- startSourceChar: 2124
- endSourceChar: 2135
- line: 81
- lineChar: 4
- spanCodeSection: "{\r\n "
- - startInstruction: 496
- endInstruction: 495
- startSourceChar: 2135
- endSourceChar: 2135
- line: 82
- lineChar: 8
- spanCodeSection:
- - startInstruction: 496
- endInstruction: 495
- startSourceChar: 2135
- endSourceChar: 2166
- line: 82
- lineChar: 8
- spanCodeSection: logScreen.gameObject.SetActive(
- - startInstruction: 496
- endInstruction: 543
- startSourceChar: 2166
- endSourceChar: 2182
- line: 82
- lineChar: 39
- spanCodeSection: "true);\r\n "
- - startInstruction: 544
- endInstruction: 543
- startSourceChar: 2182
- endSourceChar: 2182
- line: 83
- lineChar: 8
- spanCodeSection:
- - startInstruction: 544
- endInstruction: 543
- startSourceChar: 2182
- endSourceChar: 2193
- line: 83
- lineChar: 8
- spanCodeSection: 'isActive = '
- - startInstruction: 544
- endInstruction: 571
- startSourceChar: 2193
- endSourceChar: 2213
- line: 83
- lineChar: 19
- spanCodeSection: "true;\r\n }\r\n\r\n "
- - startInstruction: 572
- endInstruction: 591
- startSourceChar: 2213
- endSourceChar: 2249
- line: 86
- lineChar: 4
- spanCodeSection: "public void Notice(string log)\r\n "
- - startInstruction: 592
- endInstruction: 591
- startSourceChar: 2249
- endSourceChar: 2260
- line: 87
- lineChar: 4
- spanCodeSection: "{\r\n "
- - startInstruction: 592
- endInstruction: 591
- startSourceChar: 2260
- endSourceChar: 2260
- line: 88
- lineChar: 8
- spanCodeSection:
- - startInstruction: 592
- endInstruction: 591
- startSourceChar: 2260
- endSourceChar: 2270
- line: 88
- lineChar: 8
- spanCodeSection: Debug.Log(
- - startInstruction: 592
- endInstruction: 591
- startSourceChar: 2270
- endSourceChar: 2296
- line: 88
- lineChar: 18
- spanCodeSection: '"Updating log to say: " + '
- - startInstruction: 592
- endInstruction: 639
- startSourceChar: 2296
- endSourceChar: 2311
- line: 88
- lineChar: 44
- spanCodeSection: "log);\r\n "
- - startInstruction: 640
- endInstruction: 639
- startSourceChar: 2311
- endSourceChar: 2311
- line: 89
- lineChar: 8
- spanCodeSection:
- - startInstruction: 640
- endInstruction: 639
- startSourceChar: 2311
- endSourceChar: 2321
- line: 89
- lineChar: 8
- spanCodeSection: UpdateLog(
- - startInstruction: 640
- endInstruction: 735
- startSourceChar: 2321
- endSourceChar: 2343
- line: 89
- lineChar: 18
- spanCodeSection: "log);\r\n }\r\n\r\n\r\n "
- - startInstruction: 736
- endInstruction: 755
- startSourceChar: 2343
- endSourceChar: 2389
- line: 93
- lineChar: 4
- spanCodeSection: "private void UpdateLog(string logString)\r\n "
- - startInstruction: 756
- endInstruction: 755
- startSourceChar: 2389
- endSourceChar: 2400
- line: 94
- lineChar: 4
- spanCodeSection: "{\r\n "
- - startInstruction: 756
- endInstruction: 755
- startSourceChar: 2400
- endSourceChar: 2404
- line: 95
- lineChar: 8
- spanCodeSection: if (
- - startInstruction: 756
- endInstruction: 755
- startSourceChar: 2404
- endSourceChar: 2415
- line: 95
- lineChar: 12
- spanCodeSection: 'logs[4] != '
- - startInstruction: 756
- endInstruction: 835
- startSourceChar: 2415
- endSourceChar: 2430
- line: 95
- lineChar: 23
- spanCodeSection: "null)\r\n "
- - startInstruction: 836
- endInstruction: 835
- startSourceChar: 2430
- endSourceChar: 2445
- line: 96
- lineChar: 8
- spanCodeSection: "{\r\n "
- - startInstruction: 836
- endInstruction: 835
- startSourceChar: 2445
- endSourceChar: 2445
- line: 97
- lineChar: 12
- spanCodeSection:
- - startInstruction: 836
- endInstruction: 835
- startSourceChar: 2445
- endSourceChar: 2453
- line: 97
- lineChar: 12
- spanCodeSection: Destroy(
- - startInstruction: 836
- endInstruction: 835
- startSourceChar: 2453
- endSourceChar: 2453
- line: 97
- lineChar: 20
- spanCodeSection:
- - startInstruction: 836
- endInstruction: 835
- startSourceChar: 2453
- endSourceChar: 2458
- line: 97
- lineChar: 20
- spanCodeSection: logs[
- - startInstruction: 836
- endInstruction: 835
- startSourceChar: 2458
- endSourceChar: 2458
- line: 97
- lineChar: 25
- spanCodeSection:
- - startInstruction: 836
- endInstruction: 883
- startSourceChar: 2458
- endSourceChar: 2476
- line: 97
- lineChar: 25
- spanCodeSection: "4]);\r\n "
- - startInstruction: 884
- endInstruction: 883
- startSourceChar: 2476
- endSourceChar: 2476
- line: 98
- lineChar: 12
- spanCodeSection:
- - startInstruction: 884
- endInstruction: 883
- startSourceChar: 2476
- endSourceChar: 2486
- line: 98
- lineChar: 12
- spanCodeSection: 'logs[4] = '
- - startInstruction: 884
- endInstruction: 915
- startSourceChar: 2486
- endSourceChar: 2514
- line: 98
- lineChar: 22
- spanCodeSection: "null;\r\n }\r\n\r\n "
- - startInstruction: 916
- endInstruction: 915
- startSourceChar: 2514
- endSourceChar: 2519
- line: 101
- lineChar: 8
- spanCodeSection: for (
- - startInstruction: 916
- endInstruction: 915
- startSourceChar: 2519
- endSourceChar: 2519
- line: 101
- lineChar: 13
- spanCodeSection:
- - startInstruction: 916
- endInstruction: 915
- startSourceChar: 2519
- endSourceChar: 2519
- line: 101
- lineChar: 13
- spanCodeSection:
- - startInstruction: 916
- endInstruction: 915
- startSourceChar: 2519
- endSourceChar: 2525
- line: 101
- lineChar: 13
- spanCodeSection: 'int i '
- - startInstruction: 916
- endInstruction: 915
- startSourceChar: 2525
- endSourceChar: 2527
- line: 101
- lineChar: 19
- spanCodeSection: '= '
- - startInstruction: 916
- endInstruction: 915
- startSourceChar: 2527
- endSourceChar: 2549
- line: 101
- lineChar: 21
- spanCodeSection: 'maxNumberOfLogLines - '
- - startInstruction: 916
- endInstruction: 967
- startSourceChar: 2549
- endSourceChar: 2552
- line: 101
- lineChar: 43
- spanCodeSection: '2; '
- - startInstruction: 968
- endInstruction: 967
- startSourceChar: 2552
- endSourceChar: 2556
- line: 101
- lineChar: 46
- spanCodeSection: 'i > '
- - startInstruction: 968
- endInstruction: 967
- startSourceChar: 2556
- endSourceChar: 2557
- line: 101
- lineChar: 50
- spanCodeSection: '-'
- - startInstruction: 968
- endInstruction: 1039
- startSourceChar: 2557
- endSourceChar: 2574
- line: 101
- lineChar: 51
- spanCodeSection: "1; i--)\r\n "
- - startInstruction: 1040
- endInstruction: 1039
- startSourceChar: 2574
- endSourceChar: 2589
- line: 102
- lineChar: 8
- spanCodeSection: "{\r\n "
- - startInstruction: 1040
- endInstruction: 1039
- startSourceChar: 2589
- endSourceChar: 2593
- line: 103
- lineChar: 12
- spanCodeSection: if (
- - startInstruction: 1040
- endInstruction: 1039
- startSourceChar: 2593
- endSourceChar: 2604
- line: 103
- lineChar: 16
- spanCodeSection: 'logs[i] != '
- - startInstruction: 1040
- endInstruction: 1119
- startSourceChar: 2604
- endSourceChar: 2623
- line: 103
- lineChar: 27
- spanCodeSection: "null)\r\n "
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2623
- endSourceChar: 2642
- line: 104
- lineChar: 12
- spanCodeSection: "{\r\n "
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2642
- endSourceChar: 2642
- line: 105
- lineChar: 16
- spanCodeSection:
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2642
- endSourceChar: 2642
- line: 105
- lineChar: 16
- spanCodeSection:
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2642
- endSourceChar: 2642
- line: 105
- lineChar: 16
- spanCodeSection:
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2642
- endSourceChar: 2665
- line: 105
- lineChar: 16
- spanCodeSection: 'RectTransform logTrans '
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2665
- endSourceChar: 2667
- line: 105
- lineChar: 39
- spanCodeSection: '= '
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2667
- endSourceChar: 2667
- line: 105
- lineChar: 41
- spanCodeSection:
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2667
- endSourceChar: 2667
- line: 105
- lineChar: 41
- spanCodeSection:
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2667
- endSourceChar: 2667
- line: 105
- lineChar: 41
- spanCodeSection:
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2667
- endSourceChar: 2672
- line: 105
- lineChar: 41
- spanCodeSection: logs[
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2672
- endSourceChar: 2672
- line: 105
- lineChar: 46
- spanCodeSection:
- - startInstruction: 1120
- endInstruction: 1119
- startSourceChar: 2672
- endSourceChar: 2675
- line: 105
- lineChar: 46
- spanCodeSection: i].
- - startInstruction: 1120
- endInstruction: 1151
- startSourceChar: 2675
- endSourceChar: 2687
- line: 105
- lineChar: 49
- spanCodeSection: GetComponent
- - startInstruction: 1152
- endInstruction: 1151
- startSourceChar: 2687
- endSourceChar: 2688
- line: 105
- lineChar: 61
- spanCodeSection: <
- - startInstruction: 1152
- endInstruction: 1227
- startSourceChar: 2688
- endSourceChar: 2723
- line: 105
- lineChar: 62
- spanCodeSection: "RectTransform>();\r\n "
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2723
- endSourceChar: 2723
- line: 106
- lineChar: 16
- spanCodeSection:
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2723
- endSourceChar: 2753
- line: 106
- lineChar: 16
- spanCodeSection: 'logTrans.anchoredPosition3D = '
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2753
- endSourceChar: 2757
- line: 106
- lineChar: 46
- spanCodeSection: 'new '
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2757
- endSourceChar: 2765
- line: 106
- lineChar: 50
- spanCodeSection: Vector3(
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2765
- endSourceChar: 2765
- line: 106
- lineChar: 58
- spanCodeSection:
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2765
- endSourceChar: 2768
- line: 106
- lineChar: 58
- spanCodeSection: '0, '
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2768
- endSourceChar: 2768
- line: 106
- lineChar: 61
- spanCodeSection:
- - startInstruction: 1228
- endInstruction: 1227
- startSourceChar: 2768
- endSourceChar: 2800
- line: 106
- lineChar: 61
- spanCodeSection: 'logTrans.anchoredPosition3D.y + '
- - startInstruction: 1228
- endInstruction: 1331
- startSourceChar: 2800
- endSourceChar: 2805
- line: 106
- lineChar: 93
- spanCodeSection: '200, '
- - startInstruction: 1332
- endInstruction: 1331
- startSourceChar: 2805
- endSourceChar: 2805
- line: 106
- lineChar: 98
- spanCodeSection:
- - startInstruction: 1332
- endInstruction: 1331
- startSourceChar: 2805
- endSourceChar: 2806
- line: 106
- lineChar: 98
- spanCodeSection: '-'
- - startInstruction: 1332
- endInstruction: 1467
- startSourceChar: 2806
- endSourceChar: 2827
- line: 106
- lineChar: 99
- spanCodeSection: "1);\r\n "
- - startInstruction: 1468
- endInstruction: 1467
- startSourceChar: 2827
- endSourceChar: 2827
- line: 107
- lineChar: 16
- spanCodeSection:
- - startInstruction: 1468
- endInstruction: 1467
- startSourceChar: 2827
- endSourceChar: 2841
- line: 107
- lineChar: 16
- spanCodeSection: 'logs[i + 1] = '
- - startInstruction: 1468
- endInstruction: 1467
- startSourceChar: 2841
- endSourceChar: 2841
- line: 107
- lineChar: 30
- spanCodeSection:
- - startInstruction: 1468
- endInstruction: 1467
- startSourceChar: 2841
- endSourceChar: 2846
- line: 107
- lineChar: 30
- spanCodeSection: logs[
- - startInstruction: 1468
- endInstruction: 1467
- startSourceChar: 2846
- endSourceChar: 2846
- line: 107
- lineChar: 35
- spanCodeSection:
- - startInstruction: 1468
- endInstruction: 1643
- startSourceChar: 2846
- endSourceChar: 2887
- line: 107
- lineChar: 35
- spanCodeSection: "i];\r\n }\r\n }\r\n\r\n "
- - startInstruction: 1644
- endInstruction: 1643
- startSourceChar: 2887
- endSourceChar: 2887
- line: 111
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1644
- endInstruction: 1643
- startSourceChar: 2887
- endSourceChar: 2887
- line: 111
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1644
- endInstruction: 1643
- startSourceChar: 2887
- endSourceChar: 2887
- line: 111
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1644
- endInstruction: 1643
- startSourceChar: 2887
- endSourceChar: 2905
- line: 111
- lineChar: 8
- spanCodeSection: 'GameObject newLog '
- - startInstruction: 1644
- endInstruction: 1643
- startSourceChar: 2905
- endSourceChar: 2907
- line: 111
- lineChar: 26
- spanCodeSection: '= '
- - startInstruction: 1644
- endInstruction: 1643
- startSourceChar: 2907
- endSourceChar: 2922
- line: 111
- lineChar: 28
- spanCodeSection: VRCInstantiate(
- - startInstruction: 1644
- endInstruction: 1687
- startSourceChar: 2922
- endSourceChar: 2947
- line: 111
- lineChar: 43
- spanCodeSection: "logLinePrefab);\r\n "
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2947
- endSourceChar: 2947
- line: 112
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2947
- endSourceChar: 2947
- line: 112
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2947
- endSourceChar: 2947
- line: 112
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2947
- endSourceChar: 2957
- line: 112
- lineChar: 8
- spanCodeSection: 'Text text '
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2957
- endSourceChar: 2959
- line: 112
- lineChar: 18
- spanCodeSection: '= '
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2959
- endSourceChar: 2959
- line: 112
- lineChar: 20
- spanCodeSection:
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2959
- endSourceChar: 2959
- line: 112
- lineChar: 20
- spanCodeSection:
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2959
- endSourceChar: 2966
- line: 112
- lineChar: 20
- spanCodeSection: newLog.
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2966
- endSourceChar: 2978
- line: 112
- lineChar: 27
- spanCodeSection: GetComponent
- - startInstruction: 1688
- endInstruction: 1687
- startSourceChar: 2978
- endSourceChar: 2979
- line: 112
- lineChar: 39
- spanCodeSection: <
- - startInstruction: 1688
- endInstruction: 1763
- startSourceChar: 2979
- endSourceChar: 2997
- line: 112
- lineChar: 40
- spanCodeSection: "Text>();\r\n "
- - startInstruction: 1764
- endInstruction: 1763
- startSourceChar: 2997
- endSourceChar: 2997
- line: 113
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1764
- endInstruction: 1763
- startSourceChar: 2997
- endSourceChar: 3009
- line: 113
- lineChar: 8
- spanCodeSection: 'text.text = '
- - startInstruction: 1764
- endInstruction: 1787
- startSourceChar: 3009
- endSourceChar: 3031
- line: 113
- lineChar: 20
- spanCodeSection: "logString;\r\n\r\n "
- - startInstruction: 1788
- endInstruction: 1787
- startSourceChar: 3031
- endSourceChar: 3031
- line: 115
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1788
- endInstruction: 1787
- startSourceChar: 3031
- endSourceChar: 3041
- line: 115
- lineChar: 8
- spanCodeSection: 'logs[0] = '
- - startInstruction: 1788
- endInstruction: 1819
- startSourceChar: 3041
- endSourceChar: 3058
- line: 115
- lineChar: 18
- spanCodeSection: "newLog;\r\n "
- - startInstruction: 1820
- endInstruction: 1819
- startSourceChar: 3058
- endSourceChar: 3058
- line: 116
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1820
- endInstruction: 1819
- startSourceChar: 3058
- endSourceChar: 3085
- line: 116
- lineChar: 8
- spanCodeSection: newLog.transform.SetParent(
- - startInstruction: 1820
- endInstruction: 1819
- startSourceChar: 3085
- endSourceChar: 3085
- line: 116
- lineChar: 35
- spanCodeSection:
- - startInstruction: 1820
- endInstruction: 1819
- startSourceChar: 3085
- endSourceChar: 3095
- line: 116
- lineChar: 35
- spanCodeSection: logScreen.
- - startInstruction: 1820
- endInstruction: 1891
- startSourceChar: 3095
- endSourceChar: 3118
- line: 116
- lineChar: 45
- spanCodeSection: "transform);\r\n\r\n "
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3118
- endSourceChar: 3118
- line: 118
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3118
- endSourceChar: 3118
- line: 118
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3118
- endSourceChar: 3118
- line: 118
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3118
- endSourceChar: 3142
- line: 118
- lineChar: 8
- spanCodeSection: 'RectTransform transform '
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3142
- endSourceChar: 3144
- line: 118
- lineChar: 32
- spanCodeSection: '= '
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3144
- endSourceChar: 3144
- line: 118
- lineChar: 34
- spanCodeSection:
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3144
- endSourceChar: 3144
- line: 118
- lineChar: 34
- spanCodeSection:
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3144
- endSourceChar: 3151
- line: 118
- lineChar: 34
- spanCodeSection: newLog.
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3151
- endSourceChar: 3163
- line: 118
- lineChar: 41
- spanCodeSection: GetComponent
- - startInstruction: 1892
- endInstruction: 1891
- startSourceChar: 3163
- endSourceChar: 3164
- line: 118
- lineChar: 53
- spanCodeSection: <
- - startInstruction: 1892
- endInstruction: 1967
- startSourceChar: 3164
- endSourceChar: 3191
- line: 118
- lineChar: 54
- spanCodeSection: "RectTransform>();\r\n "
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3191
- endSourceChar: 3191
- line: 119
- lineChar: 8
- spanCodeSection:
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3191
- endSourceChar: 3222
- line: 119
- lineChar: 8
- spanCodeSection: 'transform.anchoredPosition3D = '
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3222
- endSourceChar: 3226
- line: 119
- lineChar: 39
- spanCodeSection: 'new '
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3226
- endSourceChar: 3234
- line: 119
- lineChar: 43
- spanCodeSection: Vector3(
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3234
- endSourceChar: 3234
- line: 119
- lineChar: 51
- spanCodeSection:
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3234
- endSourceChar: 3237
- line: 119
- lineChar: 51
- spanCodeSection: '0, '
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3237
- endSourceChar: 3237
- line: 119
- lineChar: 54
- spanCodeSection:
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3237
- endSourceChar: 3242
- line: 119
- lineChar: 54
- spanCodeSection: '300, '
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3242
- endSourceChar: 3242
- line: 119
- lineChar: 59
- spanCodeSection:
- - startInstruction: 1968
- endInstruction: 1967
- startSourceChar: 3242
- endSourceChar: 3243
- line: 119
- lineChar: 59
- spanCodeSection: '-'
- - startInstruction: 1968
- endInstruction: 2127
- startSourceChar: 3243
- endSourceChar: 3256
- line: 119
- lineChar: 60
- spanCodeSection: "1);\r\n "
- - startInstruction: 2128
- endInstruction: 2127
- startSourceChar: 3256
- endSourceChar: 3256
- line: 120
- lineChar: 8
- spanCodeSection:
- - startInstruction: 2128
- endInstruction: 2127
- startSourceChar: 3256
- endSourceChar: 3282
- line: 120
- lineChar: 8
- spanCodeSection: 'transform.localRotation = '
- - startInstruction: 2128
- endInstruction: 2127
- startSourceChar: 3282
- endSourceChar: 3286
- line: 120
- lineChar: 34
- spanCodeSection: 'new '
- - startInstruction: 2128
- endInstruction: 2151
- startSourceChar: 3286
- endSourceChar: 3309
- line: 120
- lineChar: 38
- spanCodeSection: "Quaternion();\r\n "
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3309
- endSourceChar: 3309
- line: 121
- lineChar: 8
- spanCodeSection:
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3309
- endSourceChar: 3332
- line: 121
- lineChar: 8
- spanCodeSection: 'transform.localScale = '
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3332
- endSourceChar: 3336
- line: 121
- lineChar: 31
- spanCodeSection: 'new '
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3336
- endSourceChar: 3344
- line: 121
- lineChar: 35
- spanCodeSection: Vector3(
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3344
- endSourceChar: 3344
- line: 121
- lineChar: 43
- spanCodeSection:
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3344
- endSourceChar: 3347
- line: 121
- lineChar: 43
- spanCodeSection: '1, '
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3347
- endSourceChar: 3347
- line: 121
- lineChar: 46
- spanCodeSection:
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3347
- endSourceChar: 3350
- line: 121
- lineChar: 46
- spanCodeSection: '1, '
- - startInstruction: 2152
- endInstruction: 2151
- startSourceChar: 3350
- endSourceChar: 3350
- line: 121
- lineChar: 49
- spanCodeSection:
- - startInstruction: 2152
- endInstruction: 2152
- startSourceChar: 3350
- endSourceChar: 3350
- line: 121
- lineChar: 49
- spanCodeSection:
- serializationData:
- SerializedFormat: 2
- SerializedBytes:
- ReferencedUnityObjects: []
- SerializedBytesString:
- Prefab: {fileID: 0}
- PrefabModificationsReferencedUnityObjects: []
- PrefabModifications: []
- SerializationNodes:
- - Name: fieldDefinitions
- Entry: 7
- Data: 0|System.Collections.Generic.Dictionary`2[[System.String, mscorlib],[UdonSharp.FieldDefinition,
- UdonSharp.Editor]], mscorlib
- - Name: comparer
- Entry: 7
- Data: 1|System.Collections.Generic.GenericEqualityComparer`1[[System.String,
- mscorlib]], mscorlib
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 12
- Data: 10
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: logLinePrefab
- - Name: $v
- Entry: 7
- Data: 2|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 3|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 7
- Data: 4|System.RuntimeType, mscorlib
- - Name:
- Entry: 1
- Data: UnityEngine.GameObject, UnityEngine.CoreModule
- - Name:
- Entry: 8
- Data:
- - Name: declarationType
- Entry: 3
- Data: 1
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: UnityEngineGameObject
- - Name: symbolOriginalName
- Entry: 1
- Data: logLinePrefab
- - Name: symbolUniqueName
- Entry: 1
- Data: logLinePrefab
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 5|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: testObj
- - Name: $v
- Entry: 7
- Data: 6|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 7|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 9
- Data: 4
- - Name: declarationType
- Entry: 3
- Data: 1
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: UnityEngineGameObject
- - Name: symbolOriginalName
- Entry: 1
- Data: testObj
- - Name: symbolUniqueName
- Entry: 1
- Data: testObj
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 8|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: logScreen
- - Name: $v
- Entry: 7
- Data: 9|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 10|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 7
- Data: 11|System.RuntimeType, mscorlib
- - Name:
- Entry: 1
- Data: UnityEngine.Canvas, UnityEngine.UIModule
- - Name:
- Entry: 8
- Data:
- - Name: declarationType
- Entry: 3
- Data: 1
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: UnityEngineCanvas
- - Name: symbolOriginalName
- Entry: 1
- Data: logScreen
- - Name: symbolUniqueName
- Entry: 1
- Data: logScreen
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 12|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: playerUI
- - Name: $v
- Entry: 7
- Data: 13|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 14|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 9
- Data: 4
- - Name: declarationType
- Entry: 3
- Data: 1
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: UnityEngineGameObject
- - Name: symbolOriginalName
- Entry: 1
- Data: playerUI
- - Name: symbolUniqueName
- Entry: 1
- Data: playerUI
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 15|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: isDev
- - Name: $v
- Entry: 7
- Data: 16|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 17|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 7
- Data: 18|System.RuntimeType, mscorlib
- - Name:
- Entry: 1
- Data: System.Boolean, mscorlib
- - Name:
- Entry: 8
- Data:
- - Name: declarationType
- Entry: 3
- Data: 1
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: SystemBoolean
- - Name: symbolOriginalName
- Entry: 1
- Data: isDev
- - Name: symbolUniqueName
- Entry: 1
- Data: isDev
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 19|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: isActive
- - Name: $v
- Entry: 7
- Data: 20|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 21|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 9
- Data: 18
- - Name: declarationType
- Entry: 3
- Data: 2
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: SystemBoolean
- - Name: symbolOriginalName
- Entry: 1
- Data: isActive
- - Name: symbolUniqueName
- Entry: 1
- Data: isActive
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 22|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: maxNumberOfLogLines
- - Name: $v
- Entry: 7
- Data: 23|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 24|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 7
- Data: 25|System.RuntimeType, mscorlib
- - Name:
- Entry: 1
- Data: System.Int32, mscorlib
- - Name:
- Entry: 8
- Data:
- - Name: declarationType
- Entry: 3
- Data: 2
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: SystemInt32
- - Name: symbolOriginalName
- Entry: 1
- Data: maxNumberOfLogLines
- - Name: symbolUniqueName
- Entry: 1
- Data: maxNumberOfLogLines
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 26|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: logs
- - Name: $v
- Entry: 7
- Data: 27|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 28|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 7
- Data: 29|System.RuntimeType, mscorlib
- - Name:
- Entry: 1
- Data: UnityEngine.GameObject[], UnityEngine.CoreModule
- - Name:
- Entry: 8
- Data:
- - Name: declarationType
- Entry: 3
- Data: 2
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: UnityEngineGameObjectArray
- - Name: symbolOriginalName
- Entry: 1
- Data: logs
- - Name: symbolUniqueName
- Entry: 1
- Data: logs
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 30|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: update
- - Name: $v
- Entry: 7
- Data: 31|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 32|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 7
- Data: 33|System.RuntimeType, mscorlib
- - Name:
- Entry: 1
- Data: System.Single, mscorlib
- - Name:
- Entry: 8
- Data:
- - Name: declarationType
- Entry: 3
- Data: 2
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: SystemSingle
- - Name: symbolOriginalName
- Entry: 1
- Data: update
- - Name: symbolUniqueName
- Entry: 1
- Data: update
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 34|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 7
- Data:
- - Name: $k
- Entry: 1
- Data: count
- - Name: $v
- Entry: 7
- Data: 35|UdonSharp.FieldDefinition, UdonSharp.Editor
- - Name: fieldSymbol
- Entry: 7
- Data: 36|UdonSharp.SymbolDefinition, UdonSharp.Editor
- - Name: internalType
- Entry: 9
- Data: 25
- - Name: declarationType
- Entry: 3
- Data: 2
- - Name: syncMode
- Entry: 3
- Data: 0
- - Name: symbolResolvedTypeName
- Entry: 1
- Data: SystemInt32
- - Name: symbolOriginalName
- Entry: 1
- Data: count
- - Name: symbolUniqueName
- Entry: 1
- Data: count
- - Name: symbolDefaultValue
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: fieldAttributes
- Entry: 7
- Data: 37|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- - Name:
- Entry: 12
- Data: 0
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
- - Name: userBehaviourSource
- Entry: 6
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 8
- Data:
- - Name:
- Entry: 13
- Data:
- - Name:
- Entry: 8
- Data:
diff --git a/Logger/UdonLogger.asset.meta b/Logger/UdonLogger.asset.meta
deleted file mode 100644
index 9f1ea40..0000000
--- a/Logger/UdonLogger.asset.meta
+++ /dev/null
@@ -1,8 +0,0 @@
-fileFormatVersion: 2
-guid: 560934ef61593c34eb85e1187096894d
-NativeFormatImporter:
- externalObjects: {}
- mainObjectFileID: 11400000
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Logger/UdonLogger.cs b/Logger/UdonLogger.cs
index ed7e89b..ff37427 100644
--- a/Logger/UdonLogger.cs
+++ b/Logger/UdonLogger.cs
@@ -1,11 +1,3 @@
-// Logger for Udon
-
-// This system maintains a log event system in Udon, similar to normal logging systems.
-// It has four levels: error, warning, info and notice.
-// Error: something has gone fatally wrong and the behaviour needs to terminate.
-// Warning: something is probably wrong and the developer might want to know about it.
-// Info: A view's state has changed and a deloper might want to know about it.
-// Notice: A view's state has changed and anyone - including a player - might want to know about it.
using UdonSharp;
using UnityEngine;
using UnityEngine.UI;
@@ -13,31 +5,20 @@
using VRC.Udon;
using VRC.Udon.Common.Interfaces;
+///A Logger for Udon. Attaches to a player's hand if they're in VR, or sits at some point in space if they're in desktop mode.
public class UdonLogger : UdonSharpBehaviour
{
+ ///The prefab for a line in the logger.
public GameObject logLinePrefab;
- public GameObject testObj;
- public Canvas logScreen;
- public GameObject playerUI;
-
- public bool isDev;
+ ///The canvas that log lines should be printed on.
+ public Canvas logScreenCanvas;
+ ///The root object of the buttons that manipulate the logger. Used to anchor the logger to things.
+ public GameObject buttons;
private bool isActive;
-
- // [UdonSynced]
- // private string latestError;
- // private string lastError;
-
- // [UdonSynced]
- // private string latestWarning;
- // private string lastWarning;
-
- // [UdonSynced]
- // private string latestInfo;
- // private string lastInfo;
-
private int maxNumberOfLogLines;
private GameObject[] logs;
+ private bool anchored;
private float update;
@@ -45,80 +26,91 @@ public class UdonLogger : UdonSharpBehaviour
void Start()
{
- //Hide();
+ gameObject.SetActive(false);
count = 0;
- maxNumberOfLogLines = 5;
+ maxNumberOfLogLines = 10;
logs = new GameObject[maxNumberOfLogLines];
- }
- public void Update()
- {
- // if (Networking.LocalPlayer != null)
- // {
- // playerUI.transform.position = Networking.LocalPlayer.GetBonePosition(HumanBodyBones.RightHand);
- // playerUI.transform.rotation = Networking.LocalPlayer.GetBoneRotation(HumanBodyBones.RightHand);
- // }
- }
-
- public void Toggle()
- {
- if (isActive == true)
- {
- Hide();
- }
- else
+ VRCPlayerApi player = Networking.LocalPlayer;
+ if (player != null && !player.IsUserInVR())
{
- Show();
+ buttons.SetActive(false);
}
}
- private void Hide()
+ public void Update()
{
- logScreen.gameObject.SetActive(false);
- isActive = false;
+ VRCPlayerApi player = Networking.LocalPlayer;
+ if (player != null && player.IsUserInVR() && !anchored)
+ {
+ gameObject.transform.position = player.GetBonePosition(HumanBodyBones.RightHand);
+ gameObject.transform.rotation = player.GetBoneRotation(HumanBodyBones.RightHand);
+ gameObject.transform.localScale = new Vector3(1, 1, 1);
+ }
}
- private void Show()
+ ///Show or hide the Logger.
+ public void Toggle()
{
- logScreen.gameObject.SetActive(true);
- isActive = true;
+ gameObject.SetActive(!gameObject.activeSelf);
}
+ ///Update the logger to output something.
public void Notice(string log)
{
- Debug.Log("Updating log to say: " + log);
- UpdateLog(log);
- }
+ // This was written with zero knowledge of how Unity's UI features can be better leveraged.
+ // If any experts want to improve this code, put a PR in!
-
- private void UpdateLog(string logString)
- {
- if (logs[4] != null)
+ // Kill the top log line if it's gone off screen.
+ // An improvement to this system would be a scroll ability!
+ if (logs[maxNumberOfLogLines - 1] != null)
{
- Destroy(logs[4]);
- logs[4] = null;
+ Destroy(logs[maxNumberOfLogLines - 1]);
+ logs[maxNumberOfLogLines - 1] = null;
}
+ // For each log, shift it up by 100.
+ // An improvement would be to shift it up by its height, rather than using 100 as a magic number.
for (int i = maxNumberOfLogLines - 2; i > -1; i--)
{
if (logs[i] != null)
{
RectTransform logTrans = logs[i].GetComponent();
- logTrans.anchoredPosition3D = new Vector3(0, logTrans.anchoredPosition3D.y + 200, -1);
+ logTrans.anchoredPosition3D = new Vector3(0, logTrans.anchoredPosition3D.y + 100, -1);
logs[i + 1] = logs[i];
}
}
GameObject newLog = VRCInstantiate(logLinePrefab);
Text text = newLog.GetComponent();
- text.text = logString;
+ text.text = log;
logs[0] = newLog;
- newLog.transform.SetParent(logScreen.transform);
+ newLog.transform.SetParent(logScreenCanvas.transform);
RectTransform transform = newLog.GetComponent();
- transform.anchoredPosition3D = new Vector3(0, 300, -1);
+ transform.anchoredPosition3D = new Vector3(0, 100, -1);
transform.localRotation = new Quaternion();
transform.localScale = new Vector3(1, 1, 1);
}
+
+ public override void OnPlayerJoined(VRCPlayerApi player)
+ {
+ Notice(player.displayName + " joined.");
+ }
+
+ public override void OnPlayerLeft(VRCPlayerApi player)
+ {
+ Notice(player.displayName + " left.");
+ }
+
+ public void Anchor()
+ {
+ anchored = true;
+ }
+
+ public void Unanchor()
+ {
+ anchored = false;
+ }
}
diff --git a/Logger/UdonLogger.cs.meta b/Logger/UdonLogger.cs.meta
deleted file mode 100644
index d5f9bc1..0000000
--- a/Logger/UdonLogger.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 75074386178276344969fc58ae293549
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant: