Files
website/assets/js/2bb13bfd.2fa1605f.js
2022-02-14 21:45:01 -05:00

1 line
5.7 KiB
JavaScript

"use strict";(self.webpackChunkstardust_website=self.webpackChunkstardust_website||[]).push([[993],{3905:function(e,t,r){r.d(t,{Zo:function(){return p},kt:function(){return f}});var n=r(7294);function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function a(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){o(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function s(e,t){if(null==e)return{};var r,n,o=function(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}var c=n.createContext({}),l=function(e){var t=n.useContext(c),r=t;return e&&(r="function"==typeof e?e(t):a(a({},t),e)),r},p=function(e){var t=l(e.components);return n.createElement(c.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return n.createElement(n.Fragment,{},t)}},d=n.forwardRef((function(e,t){var r=e.components,o=e.mdxType,i=e.originalType,c=e.parentName,p=s(e,["components","mdxType","originalType","parentName"]),d=l(r),f=o,g=d["".concat(c,".").concat(f)]||d[f]||u[f]||i;return r?n.createElement(g,a(a({ref:t},p),{},{components:r})):n.createElement(g,a({ref:t},p))}));function f(e,t){var r=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=r.length,a=new Array(i);a[0]=d;var s={};for(var c in t)hasOwnProperty.call(t,c)&&(s[c]=t[c]);s.originalType=e,s.mdxType="string"==typeof e?e:o,a[1]=s;for(var l=2;l<i;l++)a[l]=r[l];return n.createElement.apply(null,a)}return n.createElement.apply(null,r)}d.displayName="MDXCreateElement"},9255:function(e,t,r){r.r(t),r.d(t,{frontMatter:function(){return s},contentTitle:function(){return c},metadata:function(){return l},toc:function(){return p},default:function(){return d}});var n=r(7462),o=r(3366),i=(r(7294),r(3905)),a=["components"],s={},c="/input",l={unversionedId:"stardust-protocol/server/objects/input",id:"stardust-protocol/server/objects/input",isDocsHomePage:!1,title:"/input",description:"Object managing input and interaction.",source:"@site/docs/stardust-protocol/server/objects/input.md",sourceDirName:"stardust-protocol/server/objects",slug:"/stardust-protocol/server/objects/input",permalink:"/docs/stardust-protocol/server/objects/input",editUrl:"https://github.com/StardustXR/website/edit/main/docs/stardust-protocol/server/objects/input.md",version:"current",frontMatter:{},sidebar:"tutorialSidebar",previous:{title:"/hmd",permalink:"/docs/stardust-protocol/server/objects/hmd"},next:{title:"/",permalink:"/docs/stardust-protocol/server/objects/root"}},p=[{value:"Signals",id:"signals",children:[{value:"<code>registerInputHandler(string name, string field, string spacePath, Vector3 position, Quat rotation, string callbackPath, string callbackMethod)</code>",id:"registerinputhandlerstring-name-string-field-string-spacepath-vector3-position-quat-rotation-string-callbackpath-string-callbackmethod",children:[]}]},{value:"Methods",id:"methods",children:[{value:"<code>Vector&lt;Vector&lt;string inputHandlerUUID, Vector3 position&gt;&gt; getInputHandlers(string spacePath, bool excludeSelf)</code>",id:"vectorvectorstring-inputhandleruuid-vector3-position-getinputhandlersstring-spacepath-bool-excludeself",children:[]}]}],u={toc:p};function d(e){var t=e.components,r=(0,o.Z)(e,a);return(0,i.kt)("wrapper",(0,n.Z)({},u,r,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("h1",{id:"input"},"/input"),(0,i.kt)("p",null,"Object managing input and interaction."),(0,i.kt)("h2",{id:"signals"},"Signals"),(0,i.kt)("h3",{id:"registerinputhandlerstring-name-string-field-string-spacepath-vector3-position-quat-rotation-string-callbackpath-string-callbackmethod"},(0,i.kt)("inlineCode",{parentName:"h3"},"registerInputHandler(string name, string field, string spacePath, Vector3 position, Quat rotation, string callbackPath, string callbackMethod)")),(0,i.kt)("p",null,"Creates a new ",(0,i.kt)("a",{parentName:"p",href:"/docs/stardust-protocol/server/types/input/InputHandler"},"InputHandler")," with the specified ",(0,i.kt)("inlineCode",{parentName:"p"},"name")," and ",(0,i.kt)("inlineCode",{parentName:"p"},"field"),", located relative to the space referenced in ",(0,i.kt)("inlineCode",{parentName:"p"},"spacePath")," and the ",(0,i.kt)("inlineCode",{parentName:"p"},"postion")," + ",(0,i.kt)("inlineCode",{parentName:"p"},"rotation"),"."),(0,i.kt)("h2",{id:"methods"},"Methods"),(0,i.kt)("h3",{id:"vectorvectorstring-inputhandleruuid-vector3-position-getinputhandlersstring-spacepath-bool-excludeself"},(0,i.kt)("inlineCode",{parentName:"h3"},"Vector<Vector<string inputHandlerUUID, Vector3 position>> getInputHandlers(string spacePath, bool excludeSelf)")),(0,i.kt)("p",null,"Returns a list of all ",(0,i.kt)("a",{parentName:"p",href:"/docs/stardust-protocol/server/types/input/InputHandler"},"InputHandler")," UUIDs and their positions (relative to the space at ",(0,i.kt)("inlineCode",{parentName:"p"},"spacePath"),"), as well as puts aliases to those handlers in ",(0,i.kt)("inlineCode",{parentName:"p"},"/input/global_handler/[UUID]"),". Excludes handlers from this client if ",(0,i.kt)("inlineCode",{parentName:"p"},"excludeSelf")," is true."))}d.isMDXComponent=!0}}]);