・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success and 0 for failure.
Specify when you want to display a specific file type.
・If not specified, all files will be displayed.
The name of the project for which you want to get a list
・If not specified, a list of files in the current project will be displayed.
FILES FILES "TXT:PROJECT"
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success and 0 for failure.
If "//" is specified, the project list is displayed.
FILES "//"
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success and 0 for failure.
Specify when you want to get a specific file type
・If not specified, all files are acquired.
The name of the project for which you want to get a list
・If not specified, get a list of files in the current project.
A string array containing a list of files
NAMETBL$ = FILES() FOR I=0 TO LAST(NAMETBL$) ?NAMETBL$[I] NEXT
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success and 0 for failure.
If "//" is specified, the project list is acquired.
A string array containing a list of projects
NAMETBL$ = FILES("//") FOR I=0 TO LAST(NAMETBL$) ?NAMETBL$[I] NEXT
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success and 0 for failure.
Specify when you want to get a specific file type
The name of the project for which you want to get a list.
・If not specified, get a list of files in the current project.
・A string array that stores the file names in the file list.
・In the case of a one-dimensional array, it is automatically expanded according to the number of acquired files.
DIM NAMETBL$[] FILES NAMETBL$ FOR I=0 TO LAST(NAMETBL$) ?NAMETBL$[I] NEXT
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success and 0 for failure.
If "//" is specified, the project list is acquired.
・A string array that stores the project names in the project list.
・In the case of a one-dimensional array, it is automatically expanded according to the number of acquired files.
DIM NAMETBL$[] FILES "//", NAMETBL$ FOR I=0 TO LAST(NAMETBL$) ?NAMETBL$[I] NEXT
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
Only TXT can be specified as the file type
・If not specified, TXT is specified.
File name to read
Slot to read program: 0-3
・0, if not specified.
LOAD "PROGNAME" LOAD "SUBPROG",1
・When the offset is specified, the protruding part is ignored.
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
GRP, JPG or DAT can be specified
・If not specified, GRP is specified.
・If DAT is specified, files other than 2D Int arrays will result in an error.
File name to read
Graphic pages for storing read image data: 0 to 5
Destination coordinates for an image
・If not specified, 0,0 is specified.
The width and height of the loaded image data
LOADG "GRPDATA",1 LOADG "DAT:DATA",2,0,64 LOADG "GRPDATA",2 OUT W,H
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
DAT, TXT, GRP can be specified
・Cannot be omitted.
File name to read
Contents of the read file
・If DAT and GRP are specified, it returns an array containing the data in the DAT and GRP files.
・If reading DAT and GRP files fails, it returns a 1D Int solution with 0 number of elements.
・When TXT is specified, it returns the string of the TXT file contents.
・If reading the TXT file fails, it returns an empty string.
TX$=LOADV("TXT:MEMOFILE") DT=LOADV("DAT:DATAFILE")
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
DAT, GRP can be specified
・Cannot be omitted.
File name to read
Array variable that stores the read data
・The dimension of the array data stored in the file to be read must match the dimension of the target array.
・When specifying a string array, the data in the file must also be saved from the string array.
・The number of array elements is automatically expanded according to the information in the file.
DIM MARRAY[] LOADV "DAT:MDATA",MARRAY
・When overwriting, the file before overwriting is saved as @BACKUP.PRG.
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
Only TXT can be specified
・If not specified, TXT is specified.
File name to give to the program to save
Slot number for programs to save: 0-3
・0, if not specified.
SAVE "TEST" SAVE "TEST2",2
・When overwriting, the file before overwriting is saved as @BACKUP.GRP.
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
Only GRP can be specified
・If not specified, GRP is specified.
Name to give the save file
Graphic pages to save: 0-5
Specify the upper left coordinate of the area you want to save (0 and 2047 for both X and Y)
・If not specified, 0,0 is specified.
Specify the size of the area you want to save (both width and height are 1 to 2048)
・An error occurs if the result of adding the start point X and width or the start point Y and height exceeds 2048.
・If not specified, 2048,2048 is specified.
SAVEG "GRP:GAZOU",0 SAVEG "GAZOU_ICHIBU",3,100,100,300,300
・The high compression format can be saved in a smaller file than the normal compression format, but the image quality decreases each time when it is saved (lossy compression).
・When overwriting, the file before overwriting is saved as @BACKUP.JPG.
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
Only JPG can be specified
Name to give the save file
Graphic pages to save: 0-5
Specify the upper left coordinate of the area you want to save (0 and 2047 for both X and Y)
・If not specified, 0,0 is specified.
Specify the size of the area you want to save (both width and height are 1 to 2048)
・An error occurs if the result of adding the start point X and width or the start point Y and height exceeds 2048.
・If not specified, 2048,2048 is specified.
Specify a value that represents the compression amount and image quality (1 to 100)
・The smaller the number, the higher the compression ratio, but the image quality decreases.
・The default is 60.
SAVEG "JPG:GAZOU",0,80 SAVEG "JPG:GAZOU_ICHIBU",3,100,100,300,300
・When overwriting, the file before overwriting is saved as @BACKUP.TXT or @BACKUP.DAT.
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
TXT, DAT, GRP can be specified
・Cannot be omitted.
Name to give to saved file
Variables that stores the data you want to save
・For TXT, specify a string variable.
・For DAT, specify an array. There are no restrictions on the type or dimension of the array.
・For GRP, specify a 2D Int array.
SAVEV "TXT:MEMO",TX$ DIM MAP[10,10] SAVEV "DAT:MAP",MAP DIM IMG%[32,32] SAVEV "GRP:IMG",IMG%
The name of the current project
・Cannot be executed in DIRECT mode.
・The variables of the specified slot, SPFUNC, TFUNC setting contents will be cleared.
・If the currently executing slot is specified, the currently executing program will be replaced by the specified program, and execution will end at END of the specified program.
・If a slot other than the currently executing slot is specified, the program in the specified slot is executed, and when the END command is executed, it returns to the next command of EXEC.
・When specifying a slot, only the slot that is currently executing and the slot where there is no code that may be executed can be specified.
Only TXT can be specified
・If not specified, TXT is specified.
File name of program to be read
Slot to read program
・If not specified, the currently executing slot is specified.
EXEC "SAMPLE" EXEC "SBGED",1
・Cannot be executed in DIRECT mode.
・The variables of the specified slot, SPFUNC, TFUNC setting contents will be cleared.
・If the currently executing slot is specified, the currently executing program is executed again from the beginning.
・If a slot other than the currently executing slot is specified, the program in the specified slot is executed, and when the END command is executed, it returns to the next command of EXEC.
・When specifying a slot, only the slot that is currently executing and the slot where there is no code that may be executed can be specified.
Slot number of program to execute: 0-3
・The currently executing slot cannot be specified.
EXEC 2
File type to check
・If not specified, TXT is specified.
File name to check
Returns 1 if it exists, 0 if it does not exist
A=CHKFILE("SBATTACK") B=CHKFILE("GRP:SBATTACK")
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
The type of files you want to delete
・If not specified, TXT is specified.
File name to be deleted
DELETE "TEST" DELETE "GRP:PICTURE"
・The execution result can be obtained with the RESULT function.
・The value of RESULT is 1 for success, 0 for failure, and -1 for cancellation.
The type of file you want to rename
・If not specified, TXT is specified.
The name of the file you want to rename
File type of the destination file
・An error ocurrs if the file type is different from FileType1.
・If not specified, it'll be the same as FileType1.
Destination file name
RENAME "TEST1","TEST2" RENAME "GRP:PICTURE1","PICTURE2"