<story><title>Untrusted – a user JavaScript adventure game</title><url>https://alexnisnevich.github.io/untrusted/</url></story><parent_chain></parent_chain><comment><author>alnis</author><text>Hey, (one of the) developers here.&lt;p&gt;It&amp;#x27;s really exciting to see that there&amp;#x27;s still interest in this little game Greg and I made all those years ago!&lt;p&gt;I wrote up a postmortem on Untrusted back in 2014 that may be of interest if you&amp;#x27;d like to learn more about how the game was created: &lt;a href=&quot;http:&amp;#x2F;&amp;#x2F;alex.nisnevich.com&amp;#x2F;blog&amp;#x2F;2014&amp;#x2F;10&amp;#x2F;17&amp;#x2F;some_words_on_untrusted.html&quot; rel=&quot;nofollow&quot;&gt;http:&amp;#x2F;&amp;#x2F;alex.nisnevich.com&amp;#x2F;blog&amp;#x2F;2014&amp;#x2F;10&amp;#x2F;17&amp;#x2F;some_words_on_untr...&lt;/a&gt;&lt;p&gt;I&amp;#x27;m happy to answer questions and help anyone&amp;#x27;s who&amp;#x27;s stuck and needs a hint, but it seems like the HN community has already been doing a good job of the latter :-)&lt;p&gt;I&amp;#x27;m still experimenting with the fascinating intersection of code, games, and language. Here&amp;#x27;s the latest thing I&amp;#x27;m working on in the area (albeit in a very different vein, and still very much a work-in-progress): &lt;a href=&quot;http:&amp;#x2F;&amp;#x2F;app.wordbots.io&amp;#x2F;&quot; rel=&quot;nofollow&quot;&gt;http:&amp;#x2F;&amp;#x2F;app.wordbots.io&amp;#x2F;&lt;/a&gt;&lt;p&gt;Alex&lt;p&gt;P.S. I though I&amp;#x27;d end with a shout-out to some super-cool games by other people that have been inspired by Untrusted:
- INJECTION by TOASTEngineer: &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;schilcote.itch.io&amp;#x2F;injection&quot; rel=&quot;nofollow&quot;&gt;https:&amp;#x2F;&amp;#x2F;schilcote.itch.io&amp;#x2F;injection&lt;/a&gt; 
- Programmer Adventure (interface in Russian): &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;programmeradventure.github.io&amp;#x2F;&quot; rel=&quot;nofollow&quot;&gt;https:&amp;#x2F;&amp;#x2F;programmeradventure.github.io&amp;#x2F;&lt;/a&gt;</text></comment>
<story><title>Untrusted – a user JavaScript adventure game</title><url>https://alexnisnevich.github.io/untrusted/</url></story><parent_chain></parent_chain><comment><author>umvi</author><text>I figured out how to do &amp;quot;SQL Injection&amp;quot; types of attacks against a lot of the levels. I figured this all out without examining any source, BTW - this solution was made purely from in game information. For example, I would never have known about &amp;quot;_endOfStartLevelReached&amp;quot; if the game didn&amp;#x27;t complain about it being &amp;quot;not a function&amp;quot;&lt;p&gt;For example, this was my Level 12 solution:&lt;p&gt;&lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;gist.github.com&amp;#x2F;Untrusted-Game&amp;#x2F;d0f0e7493b39d109a5fe9f224882a2cf&quot; rel=&quot;nofollow&quot;&gt;https:&amp;#x2F;&amp;#x2F;gist.github.com&amp;#x2F;Untrusted-Game&amp;#x2F;d0f0e7493b39d109a5fe9...&lt;/a&gt;&lt;p&gt;You are supposed to program a robot to traverse a maze, but instead I just ended the robot&amp;#x27;s function so I could get access to the main scope and do whatever I want:&lt;p&gt;&lt;pre&gt;&lt;code&gt;        }
     });

    map.placeObject(map.getWidth() - 2, 20, &amp;#x27;greenKey&amp;#x27;);
    map.placeObject(map.getWidth() - 1, map.getHeight() - 1, &amp;#x27;exit&amp;#x27;);
    
    var tmp = map._endOfStartLevelReached
    
    &amp;#x2F;&amp;#x2F;Needed so the rest of the function is ignored
    map = {
    &amp;quot;defineObject&amp;quot;: () =&amp;gt; {},
    &amp;quot;getWidth&amp;quot;: () =&amp;gt; {},
    &amp;quot;getHeight&amp;quot;: () =&amp;gt; {},
    &amp;quot;placeObject&amp;quot;: () =&amp;gt; {},
    &amp;quot;_endOfStartLevelReached&amp;quot;: tmp
    };
    
    map.defineObject(&amp;#x27;robot2&amp;#x27;, {
        &amp;#x27;behavior&amp;#x27;: function (me) {
        }
    });
&lt;/code&gt;&lt;/pre&gt;
I hope they don&amp;#x27;t fix this though, it was exhilarating (and rewarding) trying to outsmart the game</text></comment>