-
-
Internal debug which does not redirect to IPX if enabled.
Parameters:
Name |
Type |
Description |
str |
string
|
the message to print. |
-
-
get char code.
Parameters:
Name |
Type |
Description |
s |
string
|
a string |
Returns:
- the ASCII-code of the first character.
-
-
compare a keycode with a character.
Parameters:
Name |
Type |
Description |
k |
number
|
keycode from an Event |
s |
string
|
a string with one char |
-
-
print javascript debug output if DEBUG is true.
Parameters:
Name |
Type |
Description |
str |
string
|
the message to print. |
-
-
Run garbage collector, print statistics to logfile if 'info==true'.
Parameters:
Name |
Type |
Description |
info |
boolean
|
true to print collection stats to logfile. |
-
-
Current frame rate.
Returns:
number
- current framerate.
-
-
include a module. The exported functions are copied into global scope.
Parameters:
Name |
Type |
Description |
name |
string
|
module file name. |
-
-
read a byte value from a hardware io-port.
Parameters:
Name |
Type |
Description |
port |
number
|
port address to read from. |
Returns:
number
- 8-bit value read from port.
-
-
read a long value from a hardware io-port.
Parameters:
Name |
Type |
Description |
port |
number
|
port address to read from. |
Returns:
number
- 32-bit value read from port.
-
-
read a word value from a hardware io-port.
Parameters:
Name |
Type |
Description |
port |
number
|
port address to read from. |
Returns:
number
- 16-bit value read from port.
-
-
Get directory listing.
Parameters:
Name |
Type |
Description |
dname |
string
|
name of directory to list. |
Throws:
Throws an error if listing fails.
Returns:
Array.<string>
- array of entry names.
-
-
Get information system memory.
-
-
Change mode of the mouse cursor.
Parameters:
Name |
Type |
Description |
mode |
*
|
a mode from MOUSE. |
-
-
Limit mouse movement.
Parameters:
Name |
Type |
Description |
x1 |
number
|
start x coordinate. |
y1 |
number
|
start y coordinate. |
x2 |
number
|
end x coordinate. |
y2 |
number
|
end y coordinate. |
-
-
Set mouse speed.
Parameters:
Name |
Type |
Description |
x |
number
|
horizontal speed. |
y |
number
|
vertical speed. |
-
-
Show hide mouse cursor.
Parameters:
Name |
Type |
Description |
b |
boolean
|
true or false. |
-
-
Move mouse cursor.
Parameters:
Name |
Type |
Description |
x |
number
|
x coordinate. |
y |
number
|
y coordinate. |
-
-
Get ms timestamp.
Returns:
number
- ms time.
-
-
write a byte value to a hardware io-port.
Parameters:
Name |
Type |
Description |
port |
number
|
port address to write to. |
value |
number
|
8-bit value to write to port. |
-
-
write a long value to a hardware io-port.
Parameters:
Name |
Type |
Description |
port |
number
|
port address to write to. |
value |
number
|
32-bit value to write to port. |
-
-
write a word value to a hardware io-port.
Parameters:
Name |
Type |
Description |
port |
number
|
port address to write to. |
value |
number
|
16-bit value to write to port. |
-
-
Write the given value to io-port 80h to be displayed by a POST card.
Parameters:
Name |
Type |
Description |
val |
number
|
value to write to 0x80. |
-
-
Write data to JSLOG.TXT logfile.
Parameters:
Name |
Type |
Description |
s |
string
|
the string to print. |
-
-
Write data to JSLOG.TXT logfile with a newline.
Parameters:
Name |
Type |
Description |
s |
string
|
the string to print. |
-
-
get random integer between min and max (or between 0 and min if max is not provided).
Parameters:
Name |
Type |
Description |
min |
number
|
min |
max |
number
|
max |
Returns:
number
- an integer between min and max.
-
-
Load the contents of a file into a string. Throws exception if loading fails.
Parameters:
Name |
Type |
Description |
filename |
string
|
name of file to read. |
Throws:
Throws an error if reading fails.
Returns:
string
- the contents of the file.
-
-
import a module.
Parameters:
Name |
Type |
Description |
name |
string
|
module file name. |
Returns:
- the imported module.
-
-
Change the exit key from ESCAPE to any other keycode from KEY}.
Parameters:
Name |
Type |
Description |
key |
number
|
|
-
-
Set maximum frame rate. If
Loop takes longer than '1/rate' seconds then the framerate will not be reached.
Parameters:
Name |
Type |
Description |
rate |
number
|
max frame rate wanted. |
-
-
Sleep for the given number of ms.
Parameters:
Name |
Type |
Description |
ms |
number
|
time to sleep. |
-
-
print startup info with screen details.
-
-
Get information about a file / directory.
Parameters:
Name |
Type |
Description |
name |
string
|
name of the file to get info for. |
Throws:
Throws an error if stat fails.
-
-
DOjS will exit after the current call to
Loop.
-
-
Run a DOS command.
Parameters:
Name |
Type |
Description |
cmd |
string
|
the command to execute with its parameters. |
flags |
SYSTEM
|
flags indicating which subsystems to shutdown (if any) during execution of cmd. |
Returns:
number
- the return code of the command.