forked from marva/sumorobot-web
remove sumorobot object replacement
This commit is contained in:
parent
13d9a967d9
commit
4361448951
12
sumorobot.js
12
sumorobot.js
@ -410,16 +410,12 @@ window.onload = function() {
|
||||
sumostart = true;
|
||||
/* if we are in Python mode */
|
||||
if (pythonEnabled) {
|
||||
/* add the an empty block ID to the functions */
|
||||
var code = $("#blocklyCode").val().replace(/sumorobot./g, "").replace(/\)/g, ", \"\")");
|
||||
/* is_enemy doesn't need the , */
|
||||
code = code.replace(/\(, ""\)/g, "(\"\")");
|
||||
/* send the code to the SumoRobot */
|
||||
sumorobot.send("start:" + code);
|
||||
/* send the code from the textarea to the SumoRobot */
|
||||
sumorobot.send("start:" + $("#blocklyCode").val());
|
||||
/* otherwise when we are in blockly mode */
|
||||
} else {
|
||||
/* send the code to the SumoRobot */
|
||||
sumorobot.send("start:" + sumocode.replace(/sumorobot./g, ""));
|
||||
/* send the code from the blocks to the SumoRobot */
|
||||
sumorobot.send("start:" + sumocode);
|
||||
}
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user