mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-04-01 23:41:20 +00:00
Should now run programs in the browser, just need to compile the examples and load them up
This commit is contained in:
parent
4f4ef893f4
commit
ef80c6da7e
2 changed files with 6 additions and 7 deletions
|
@ -189,14 +189,12 @@ function update() {
|
|||
|
||||
doc.value = examples[sel[sel.selectedIndex].value - 1];
|
||||
}
|
||||
|
||||
function compile() {
|
||||
//run ([
|
||||
// document.getElementById("eg").selectedIndex.toString(),
|
||||
// document.getElementById("args")
|
||||
//]);
|
||||
//document.write("Hello World\n");
|
||||
run (["hello.dat"]);
|
||||
var args = [
|
||||
'dat/' + document.getElementById("eg").selectedIndex.toString() + '.dat'
|
||||
].concat(document.getElementById("args").value.split());
|
||||
document.getElementById("output").value = "Executing " + args.toString().replace(',', ' ');
|
||||
run (args);
|
||||
}
|
||||
|
||||
/* set initial */
|
||||
|
|
|
@ -48,6 +48,7 @@
|
|||
<textarea id="input" rows="25" cols="100%" disabled="disabled"></textarea>
|
||||
<br>
|
||||
<button onclick="compile()">Execute</button>
|
||||
<textarea id="args">Test</textarea>
|
||||
<h4>Execution Output:</h4>
|
||||
<textarea id="output" rows="25", cols="100%"></textarea>
|
||||
</section>
|
||||
|
|
Loading…
Reference in a new issue