Last active
October 21, 2018 13:36
-
-
Save kenwebb/0c07551a85b220eb6fc7c8a8d2b6a10b to your computer and use it in GitHub Desktop.
WebRTC Island Admin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!--Xholon Workbook http://www.primordion.com/Xholon/gwt/ MIT License, Copyright (C) Ken Webb, Sun Oct 21 2018 09:36:24 GMT-0400 (Eastern Daylight Time)--> | |
<XholonWorkbook> | |
<Notes><![CDATA[ | |
Xholon | |
------ | |
Title: WebRTC Island Admin | |
Description: | |
Url: http://www.primordion.com/Xholon/gwt/ | |
InternalName: 0c07551a85b220eb6fc7c8a8d2b6a10b based on 9c111d1ffac80a6905964d9433a532b7 based on bbb22a5cd9599e94f70a207118cf3ec5 | |
Keywords: | |
My Notes | |
-------- | |
October 21, 2018 | |
http://www.primordion.com/Xholon/gwt/XholonWebRTC.html?app=0c07551a85b220eb6fc7c8a8d2b6a10b&src=gist&gui=none&remoteid0=Daniel101&remoteid1=Johann101&remoteid2=Jules101 | |
http://www.primordion.com/Xholon/gwt/XholonWebRTC.html?app=0c07551a85b220eb6fc7c8a8d2b6a10b&src=gist&gui=none&remoteid0=Daniel101 | |
http://127.0.0.1:8888/XholonWebRTC.html?app=WebRTC+Island+Admin&src=lstr&gui=none&remoteid0=Daniel101&remoteid1=Johann101&remoteid2=Jules101 | |
http://127.0.0.1:8888/XholonWebRTC.html?app=WebRTC+Island+Admin&src=lstr&gui=none&remoteid0=Daniel101 | |
To run instances of the Island game: | |
http://www.primordion.com/Xholon/gwt/XholonWebRTC.html?app=40731e8f7a7ece0236e656fb24036e4a&apprev=17&src=gist&gui=none&hide=xhtop,xhtabs,xhsvg,xhfooter&localid0=Daniel101 | |
http://www.primordion.com/Xholon/gwt/XholonWebRTC.html?app=40731e8f7a7ece0236e656fb24036e4a&apprev=17&src=gist&gui=none&hide=xhtop,xhtabs,xhsvg,xhfooter&localid0=Johann101 | |
http://www.primordion.com/Xholon/gwt/XholonWebRTC.html?app=40731e8f7a7ece0236e656fb24036e4a&apprev=17&src=gist&gui=none&hide=xhtop,xhtabs,xhsvg,xhfooter&localid0=Jules101 | |
http://127.0.0.1:8888/XholonWebRTC.html?app=Island+B3&apprev=17&src=lstr&gui=none&hide=xhtop,xhtabs,xhsvg,xhfooter&localid0=Daniel101 | |
Drag this to Avatar: | |
<script> | |
var a = this.parent(); | |
a.action("script;\ngo port0;\ntakeclone dataExport;\ngo port0;\ndrop dataExport;\n"); | |
</script> | |
References | |
---------- | |
() http://peerjs.com/ | |
]]></Notes> | |
<_-.XholonClass> | |
<PhysicalSystem/> | |
<Universe/> | |
<DataCollection00/> | |
<DataCollection01/> | |
<DataCollection02/> | |
<!-- the Avatar collects this type of node from Island Game apps --> | |
<DataExport/> | |
</_-.XholonClass> | |
<xholonClassDetails> | |
<DataCollection00 xhType="XhtypePureActiveObject"> | |
<port name="port" index="0" connector="RemoteNodeService-PeerJS,remoteid0,delete,3,delete,9000,/"/> | |
</DataCollection00> | |
<DataCollection01 xhType="XhtypePureActiveObject"> | |
<port name="port" index="0" connector="RemoteNodeService-PeerJS,remoteid1,delete,3,delete,9000,/"/> | |
</DataCollection01> | |
<DataCollection02 xhType="XhtypePureActiveObject"> | |
<port name="port" index="0" connector="RemoteNodeService-PeerJS,remoteid2,delete,3,delete,9000,/"/> | |
</DataCollection02> | |
<Avatar><Color>red</Color></Avatar> | |
<DataExport><Color>green</Color></DataExport> | |
</xholonClassDetails> | |
<PhysicalSystem> | |
<Universe> | |
<DataCollection00 roleName="Player A"/> | |
<DataCollection01 roleName="Player B"/> | |
<DataCollection02 roleName="Player C"/> | |
</Universe> | |
<Animate duration="1" selection="#one" xpath="./PhysicalSystem/Universe" efParams="{"selection":"#one","sort":"disable","width":600,"height":600,"mode":"tween","labelContainers":true,"includeId":true,"shape":"circle","maxChars":4,"togglePortColors":false}"/> | |
</PhysicalSystem> | |
<PhysicalSystembehavior implName="org.primordion.xholon.base.Behavior_gwtjs"><![CDATA[ | |
var me, beh = { | |
postConfigure: function() { | |
me = this.cnode.parent(); | |
$wnd.xh.param("TimeStepInterval", 1000); | |
// SVG caption | |
$wnd.xh.svg = {}; | |
$wnd.xh.svg.caption = $doc.createElement("p"); | |
$wnd.xh.svg.caption.textContent = $wnd.xh.param("ModelName"); | |
var div = $doc.querySelector("#xhanim"); | |
// create a new div for this animation | |
var one = $doc.createElement("div"); | |
one.setAttribute("id", "one"); | |
div.appendChild(one); | |
one.appendChild($wnd.xh.svg.caption); | |
$wnd.xh.root().append(this.cnode.remove()); | |
var ava = $wnd.xh.avatar(); | |
//ava.action("param setCtxtOnselect false;start;"); | |
ava.action("param setCtxtOnselect false;enter physicalSystem;enter universe;enter *dataCollection00;appear;start;"); | |
if ($wnd.xh.html["selectTab"]) { | |
$wnd.xh.html.selectTab(0); // display contents of the "out" tab | |
} | |
} | |
} | |
//# sourceURL=PhysicalSystembehavior.js | |
]]></PhysicalSystembehavior> | |
<SvgClient><Attribute_String roleName="svgUri"><![CDATA[data:image/svg+xml, | |
<svg width="100" height="50" xmlns="http://www.w3.org/2000/svg"> | |
<g> | |
<title>PhysicalSystem</title> | |
<rect id="PhysicalSystem" fill="#98FB98" height="50" width="50" x="25" y="0"/> | |
<g> | |
<title>Hello</title> | |
<rect id="PhysicalSystem/Universe" fill="#6AB06A" height="50" width="10" x="80" y="0"/> | |
</g> | |
</g> | |
</svg> | |
]]></Attribute_String><Attribute_String roleName="setup">${MODELNAME_DEFAULT},${SVGURI_DEFAULT}</Attribute_String></SvgClient> | |
</XholonWorkbook> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment