Results 1 to 2 of 2

Thread: Javascript in IE, Google Chrome en Firefox, online en off-line in jsrobowar

Hybrid View

  1. #1
    Join Date
    May 2013

    Javascript in IE, Google Chrome en Firefox, online en off-line in jsrobowar

    An implementation of Robowars (http://robowar.sourceforge.net/RoboWar5/index.html) in Javascript (http://statico.github.io/jsrobowar/) runs online without problems in IE, Google Chrome and Firefox.

    The code can be downloaded from GitHub (https://github.com/statico/jsrobowar) as jsrobowar-master.zip (https://github.com/statico/jsrobowar/archive/master.zip).

    After unpacking the off-line program only runs in IE; Firefox shows error messages "errror compiling ..." , Google Chrome ".... error at line undefined, undefined at".

    It seems that the robotcode text files in the robots subdirectory only IE reads correctly in HTML TEXTAREA 's and transmits to the robot code compiler in js / jsrobowar.js (cf single code fragment from js / gui.js)

    -------------------------------------------------- -----------------------------
    / / Load robot code into the editor when a robot is selected.
    select.change (function () {
    var name = $ (this) val ().;
    if (name) {
    var path = 'robots /' + name + 'txt.';
    textarea.val ((Loading '+ path +') ');
    textarea.attr ('disabled', 'disabled');
    $. get (path, function (src) {
    textarea.val (src);
    textarea.attr ("disabled", null);
    -------------------------------------------------- ------------

    I tried to clean up the javascript code in both files with JSLint and JSHint but no solace.
    On Internet forums I found items about problems with TEXTAREA in Javascript, but as a newbie it didn't help me much.

    I want to start a jsrobowar programming competition, and want to have a browser-independent implementation.

    Is there anyone who has a solution this problem ?


    v vriendelijke groet
    ^^ Peter Uilenreef

  2. #2
    Join Date
    May 2006
    Somewhere behind your screen
    why don't you start a jsrobowar programming competition between its authors?
    signature under construction

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center