Warning
You're browsing the old v2.x documentation. This version is no longer maintained. Click here to go the v3.x documentation.
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
command_reference [2019/12/09 21:26] – neils | command_reference [2021/02/18 14:28] (current) – neils | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== XC=BASIC command reference ====== | ====== XC=BASIC command reference ====== | ||
- | The following is the list of all commands, functions and directives supported by the current version of **XC=BASIC**, in alphabetical order: | + | The following is the list of all commands, functions and directives supported by the current version of **XC=BASIC**: |
+ | |||
+ | ===== Core commands ===== | ||
+ | |||
+ | <tabbox Alphabetical order> | ||
< | < | ||
Line 68: | Line 72: | ||
* [[WATCH|WATCH]] | * [[WATCH|WATCH]] | ||
* [[while|WHILE ... ENDWHILE]] | * [[while|WHILE ... ENDWHILE]] | ||
+ | |||
+ | < | ||
+ | |||
+ | <tabbox By category> | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[ABS|ABS()]] | ||
+ | * [[RND|RND()]] | ||
+ | * [[SGN|SGN()]] | ||
+ | * [[SQR|SQR()]] | ||
+ | * [[ATN|ATN()]] | ||
+ | * [[COS|COS()]] | ||
+ | * [[SIN|SIN()]] | ||
+ | * [[TAN|TAN()]] | ||
+ | * [[LSHIFT|LSHIFT()]] | ||
+ | * [[RSHIFT|RSHIFT()]] | ||
+ | * [[DEC|DEC]] | ||
+ | * [[INC|INC]] | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[STRCMP|STRCMP()]] | ||
+ | * [[STRCPY|STRCPY]] | ||
+ | * [[STRLEN|STRLEN()]] | ||
+ | * [[STRNCPY|STRNCPY]] | ||
+ | * [[STRPOS|STRPOS()]] | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[AT|@ (address of)]] | ||
+ | * [[CAST|CAST()]] | ||
+ | * [[CONST|CONST]] | ||
+ | * [[DATA|DATA]] | ||
+ | * [[DIM|DIM]] | ||
+ | * [[LET|LET]] | ||
+ | * [[VAL|VAL()]] | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[CALL|CALL]] | ||
+ | * [[PROC|PROC ... ENDPROC]] | ||
+ | * [[END|END]] | ||
+ | * [[FORNEXT|FOR ... NEXT]] | ||
+ | * [[fun|FUN ... ENDFUN]] | ||
+ | * [[GOSUBRETURN|GOSUB ... RETURN]] | ||
+ | * [[GOTO|GOTO]] | ||
+ | * [[IFTHENELSE|IF ... THEN ... ELSE]] | ||
+ | * [[ON|ON]] | ||
+ | * [[repeat|REPEAT ... UNTIL]] | ||
+ | * [[while|WHILE ... ENDWHILE]] | ||
+ | * [[REM|REM]] | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[pragma|PRAGMA]] | ||
+ | * [[ASM|ASM]] | ||
+ | * [[ORIGIN|ORIGIN]] | ||
+ | * [[INCBIN|INCBIN]] | ||
+ | * [[INCLUDE|INCLUDE]] | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[DISABLEIRQ|DISABLEIRQ]] | ||
+ | * [[ENABLEIRQ|ENABLEIRQ]] | ||
+ | * [[SYS|SYS]] | ||
+ | * [[USR|USR()]] | ||
+ | * [[WAIT|WAIT]] | ||
+ | * [[WATCH|WATCH]] | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[CHARAT|CHARAT]] | ||
+ | * [[CURPOS|CURPOS]] | ||
+ | * [[TEXTAT|TEXTAT]] | ||
+ | * [[PRINT|PRINT]] | ||
+ | * [[INKEY|INKEY()]] | ||
+ | * [[INPUT|INPUT]] | ||
+ | * [[FERR|FERR()]] | ||
+ | * [[LOAD|LOAD]] | ||
+ | * [[SAVE|SAVE]] | ||
+ | |||
+ | < | ||
+ | |||
+ | < | ||
+ | < | ||
+ | |||
+ | * [[DEEK|DEEK()]] | ||
+ | * [[DOKE|DOKE]] | ||
+ | * [[PEEK|PEEK()]] | ||
+ | * [[POKE|POKE]] | ||
+ | * [[memcpy|MEMCPY]] | ||
+ | * [[memset|MEMSET]] | ||
+ | * [[memshift|MEMSHIFT]] | ||
+ | |||
+ | < | ||
+ | |||
+ | ---- | ||
+ | |||
+ | </ | ||
+ | |||
+ | ===== Extended commands ===== | ||
+ | |||
+ | The following commands are provided with extensions. You can read more about extensions [[extensions|here]]. | ||
+ | |||
+ | ==== Sprites ==== | ||
+ | |||
+ | < | ||
+ | |||
+ | * [[SPR_BEHINDBG|SPR_BEHINDBG]] | ||
+ | * [[SPR_CLEARDBLHEIGHT|SPR_CLEARDBLHEIGHT]] | ||
+ | * [[SPR_CLEARDBLWIDTH|SPR_CLEARDBLWIDTH]] | ||
+ | * [[SPR_DATA_COLLISION|SPR_DATA_COLLISION()]] | ||
+ | * [[SPR_DISABLE|SPR_DISABLE]] | ||
+ | * [[SPR_ENABLE|SPR_ENABLE]] | ||
+ | * [[SPR_OVERBG|SPR_OVERBG]] | ||
+ | * [[SPR_SETCOLOR|SPR_SETCOLOR]] | ||
+ | * [[SPR_SETDBLHEIGHT|SPR_SETDBLHEIGHT]] | ||
+ | * [[SPR_SETDBLWIDTH|SPR_SETDBLWIDTH]] | ||
+ | * [[SPR_SETHIRES|SPR_SETHIRES]] | ||
+ | * [[SPR_SETMULTI|SPR_SETMULTI]] | ||
+ | * [[SPR_SETPOS|SPR_SETPOS]] | ||
+ | * [[SPR_SETPOSX|SPR_SETPOSX]] | ||
+ | * [[SPR_SETPOSY|SPR_SETPOSY]] | ||
+ | * [[SPR_SETSHAPE|SPR_SETSHAPE]] | ||
+ | * [[SPR_SPR_COLLISION|SPR_SPR_COLLISION()]] | ||
+ | |||
+ | < | ||
+ | |||
+ | ==== Joystick ==== | ||
+ | |||
+ | < | ||
+ | |||
+ | * [[JOY_1_UP|JOY_1_UP()]] | ||
+ | * [[JOY_1_DOWN|JOY_1_DOWN()]] | ||
+ | * [[JOY_1_LEFT|JOY_1_LEFT()]] | ||
+ | * [[JOY_1_RIGHT|JOY_1_RIGHT()]] | ||
+ | * [[JOY_1_FIRE|JOY_1_FIRE()]] | ||
+ | * [[JOY_2_UP|JOY_2_UP()]] | ||
+ | * [[JOY_2_DOWN|JOY_2_DOWN()]] | ||
+ | * [[JOY_2_LEFT|JOY_2_LEFT()]] | ||
+ | * [[JOY_2_RIGHT|JOY_2_RIGHT()]] | ||
+ | * [[JOY_2_FIRE|JOY_2_FIRE()]] | ||
+ | |||
+ | < | ||
+ | |||
+ | ==== Raster interrupts ==== | ||
+ | |||
+ | < | ||
+ | |||
+ | * [[RI_ON|RI_ON]] | ||
+ | * [[RI_OFF|RI_OFF]] | ||
+ | * [[RI_SET_ISR|RI_SET_ISR]] | ||
+ | * [[RI_SYSHANDLER_ON|RI_SYSHANDLER_ON]] | ||
+ | * [[RI_SYSHANDLER_OFF|RI_SYSHANDLER_OFF]] | ||
+ | |||
+ | < | ||
+ | |||
+ | ==== Sound effects ==== | ||
+ | |||
+ | < | ||
+ | |||
+ | * [[SFX_INIT|SFX_INIT]] | ||
+ | * [[SFX_PLAY|SFX_PLAY]] | ||
+ | * [[SFX_START|SFX_START]] | ||
+ | |||
+ | < | ||
+ | |||
+ | ==== Hi-Res graphics ==== | ||
+ | |||
+ | < | ||
+ | |||
+ | * [[hi_bitmapon|HI_BITMAPON]] | ||
+ | * [[hi_bitmapoff|HI_BITMAPOFF]] | ||
+ | * [[hi_box|HI_BOX]] | ||
+ | * [[hi_circle|HI_CIRCLE]] | ||
+ | * [[hi_clear|HI_CLEAR]] | ||
+ | * [[hi_dot|HI_DOT]] | ||
+ | * [[hi_dotset|HI_DOTSET()]] | ||
+ | * [[hi_fill|HI_FILL]] | ||
+ | * [[hi_line|HI_LINE]] | ||
+ | * [[hi_rect|HI_RECT]] | ||
< | < |