<div dir="auto">I don’t see how scripts are handled in the CD, or if scripts are actually nodes.</div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Dec 3, 2021 at 4:54 PM Joseph D Williams <<a href="mailto:joedwil@earthlink.net">joedwil@earthlink.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;padding-left:1ex;border-left-color:rgb(204,204,204)"><div lang="EN-US" link="blue" vlink="#954F72" style="word-wrap:break-word"><div class="m_-442342095952319720WordSection1"><p class="MsoNormal">To me, that example does not show how a script node in the scene fails.</p><p class="MsoNormal">Since this topic hardly sees this list (anymore), maybe need to hear from developers and what changes need to be made in x3d4 text up on the web.</p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal"><a href="https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-CD1/Part01/concepts.html#Eventmodel" target="_blank">https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-CD1/Part01/concepts.html#Eventmodel</a><u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">Joe</p><p class="MsoNormal">the </p></div></div><div lang="EN-US" link="blue" vlink="#954F72" style="word-wrap:break-word"><div class="m_-442342095952319720WordSection1"><p class="MsoNormal"><u></u> <u></u></p><div style="border-style:solid none none;border-top-width:1pt;padding:3pt 0in 0in;border-top-color:rgb(225,225,225)"><p class="MsoNormal" style="border:none;padding:0in"><b>From: </b><a href="mailto:yottzumm@gmail.com" target="_blank">John Carlson</a><br><b>Sent: </b>Friday, December 3, 2021 2:07 PM<br><b>To: </b><a href="mailto:joedwil@earthlink.net" target="_blank">Joseph D Williams</a><br><b>Cc: </b><a href="mailto:x3d-public@web3d.org" target="_blank">X3D Graphics public mailing list</a><br><b>Subject: </b>Re: [x3d-public] X3D Scripting for X3DOM w/o reading standard</p></div><p class="MsoNormal"><u></u> <u></u></p><p>For example, if we see this: <a href="https://www.kshell.com/pages/rosetta/rosetta_x3dom.html" target="_blank">https://www.kshell.com/pages/rosetta/rosetta_x3dom.html</a> copied from another email, we see that there are *no* script <field>s in the code.</p><p>Does the X3D4 standard eschew script <field>s?  And instead offer "onclick()" events?</p><p>Thanks!</p><p>John</p><div><p class="MsoNormal">On 12/3/21 15:33, John Carlson wrote:<u></u><u></u></p></div><blockquote style="margin-top:5pt;margin-bottom:5pt"><p class="MsoNormal"><u></u> <u></u></p><div><p class="MsoNormal"><br><br><u></u><u></u></p><blockquote style="margin-top:5pt;margin-bottom:5pt"><p class="MsoNormal" style="margin-bottom:12pt">On Dec 3, 2021, at 1:53 PM, Joseph D Williams <a href="mailto:joedwil@earthlink.net" target="_blank"><joedwil@earthlink.net></a> wrote:<u></u><u></u></p></blockquote></div><blockquote style="margin-top:5pt;margin-bottom:5pt"><div><p class="MsoNormal"> <u></u><u></u></p><ol style="margin-top:0in" start="1" type="1"><li class="m_-442342095952319720MsoListParagraph" style="margin-left:0in">2.  What are the stumbling blocks to getting script fields into the event model?<u></u><u></u></li></ol><p class="MsoNormal"> <u></u><u></u></p><p class="MsoNormal">Hi John,<u></u><u></u></p><p class="MsoNormal">Scripts are completely involved in the x3d sai event model. A script must receive an event to begin execution and then it is like an ’external’ in that when the script begins it essentially acts like a beginUpdate and when it completes it essentially gets an endUpdate and all outputs are sent with the same time stamp as kicked off the script. Think of it as script is like any other node that can receive and send events. Only exception is, I think, that a script directOut does not initiate a new cascade<u></u><u></u></p></div></blockquote><div><p class="MsoNormal"><u></u> <u></u></p></div><p class="MsoNormal">Part of the thing to do is try script fields in X3DOM and see if they work at all, and if they don’t, try to do a minimal amount of debugging to see what might be done. <u></u><u></u></p><div><p class="MsoNormal">I do not recall if Roy’s work on this is available still or not.<u></u><u></u></p></div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><div><blockquote style="margin-top:5pt;margin-bottom:5pt"><div><p class="MsoNormal"> <u></u><u></u></p><ol style="margin-top:0in" start="2" type="1"><li class="m_-442342095952319720MsoListParagraph" style="margin-left:0in">3.  If scripts are transformed, how?<u></u><u></u></li></ol><p class="MsoNormal"> <u></u><u></u></p><p class="MsoNormal">If it is ECMAScript then what do you do? What can be done? Break it down into json like any other node? For some reason I hope not.<u></u><u></u></p><p class="MsoNormal"> <u></u><u></u></p></div></blockquote><div><p class="MsoNormal"><u></u> <u></u></p></div><p class="MsoNormal">Well, one could potentially replace field access with a node attribute util get or set method.   But this can get really tricky, if not impossible to do in all cases.   It would be better to implement script field routes, if possible. See above.  If one could get script field routes into the HTML standard, much, much better…<br><br><u></u><u></u></p><blockquote style="margin-top:5pt;margin-bottom:5pt"><div><p class="MsoNormal">Joe <u></u><u></u></p><p class="MsoNormal"> <u></u><u></u></p><p class="MsoNormal"> <u></u><u></u></p><div style="border-style:solid none none;border-top-width:1pt;padding:3pt 0in 0in;border-top-color:rgb(225,225,225)"><p class="MsoNormal"><b>From: </b><a href="mailto:yottzumm@gmail.com" target="_blank">John Carlson</a><br><b>Sent: </b>Tuesday, November 30, 2021 11:40 AM<br><b>To: </b><a href="mailto:x3d-public@web3d.org" target="_blank">X3D Graphics public mailing list</a><br><b>Subject: </b>[x3d-public] X3D Scripting for X3DOM w/o reading standard<u></u><u></u></p></div><p class="MsoNormal"> <u></u><u></u></p><p class="MsoNormal">Information needed:<u></u><u></u></p><div><p class="MsoNormal"> <u></u><u></u></p></div><div><p class="MsoNormal"> <u></u><u></u></p></div><div><p class="MsoNormal">1.   Do scripts in proto bodies get copied?<u></u><u></u></p></div><div><p class="MsoNormal"> <u></u><u></u></p></div><div><p class="MsoNormal">2.  What are the stumbling blocks to getting script fields into the event model?<u></u><u></u></p></div><div><p class="MsoNormal"> <u></u><u></u></p></div><div><p class="MsoNormal">3.  If scripts are transformed, how?<u></u><u></u></p></div><div><p class="MsoNormal"> <u></u><u></u></p></div><div><p class="MsoNormal">4.  What is the new event model for X3D4?<u></u><u></u></p></div><div><p class="MsoNormal"> <u></u><u></u></p></div><p class="MsoNormal">John<u></u><u></u></p></div></blockquote></div></div></blockquote><p class="MsoNormal" style="margin-right:1in;margin-bottom:5pt;margin-left:1in"> <u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p></div></div></blockquote></div></div>