We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
🚀💬 Network module for Whitestorm.js (alpha)
There was an error while loading.Please reload this page.
Networking module for Whitestorm.js [Alpha]
Go toWhitestormJS/whitestorm.js
new NETWORK.Connection()
constapp=newWHS.App({// ...newNETWORK.Connection({host:'localhost',port:3000,protocol:'http'})});app.start();
new NETWORK.Identity()
constbox=newWHS.Box({geometry:{width:2,height:2,depth:2},modules:[newNETWORK.Identity()],material:newTHREE.MeshBasicMaterial({color:0xff0000})});box.addTo(app);
new NETWORK.Transform()
constbox=newWHS.Box({geometry:{width:2,height:2,depth:4},modules:[newNETWORK.Transform({position:true,rotation:true,scale:false,animation:true})],material:newTHREE.MeshBasicMaterial({color:0xff0000})});box.addTo(app);
new NETWORK.Event()
You can use this to allow for special events to be fired on objects. This is easy to do, and allows for great control over different objects.
constbox=newWHS.Box({geometry:{width:2,height:2,depth:4},modules:[newNETWORK.Event({name:'myCustomEvent'id:0,handler:(data)=>{doSomething();};})],material:newTHREE.MeshBasicMaterial({color:0xff0000})});box.addTo(app);