Wikia

Petit Computer Wiki

List of Commands

Comments11
771pages on
this wiki

The following is a list of built-in commands, adapted from the help file:

V1 V2 V3 Command
n Y Y ACLS
n Y n APPEND string
n n Y ATTR parameter
n n Y BACKTRACE
Y Y Y BEEP [sound effect[, pitch[, volume[, balance] ] ] ]
Y Y n BGCLIP x start point, y start point, x end point, y end point
n n Y BGCLIP Layer [,x start point, y start point, x end point, y end point]
n Y Y BGCLR [Layer]
n Y Y BGCOPY layer, start point x, start point y, end point x, end point y, transfer destination x, transfer destination y
n Y n BGFILL layer, start point x, start point y, end point x, end point y, character number, palette number, horizontal rotation, vertical rotation
n Y Y BGFILL layer, start point x, start point y, end point x, end point y, screen data
n Y n BGFILL layer, start point x, start point y, end point x, end point y, screen data string
n n Y BGLOAD
n Y Y BGMCLEAR [song number]
Y Y Y BGMPLAY song number
n Y Y BGMPLAY track number, song number[, track volume]
n Y Y BGMPLAY MML string[, MML string...]
n Y n BGMPRG waveform number, A, D, S, R, waveform string
n Y Y BGMSET song number, MML string[, MML string...]
n Y Y BGMSETD song number, @label
n Y n BGMSETD song number, string
n Y n BGMSETV track number, variable number, value
Y Y Y BGMSTOP
n Y Y BGMSTOP track number[, fade time]
n Y Y BGMVOL [track number,] volume
Y Y n BGOFS layer, x, y[, interpolation time]
n n Y BGOFS layer, [x], [y], [z]
Y Y Y BGPAGE screen
Y Y n BGPUT layer, x, y, character number, palette number, horizontal rotation, vertical rotation
n Y Y BGPUT layer, x, y, screen data
n Y n BGPUT layer, x, y, screen data string
Y Y n BGREAD (layer, x, y), CHR, PAL, H, V
n Y n BGREAD (layer, x, y), SC
n Y n BGREAD (layer, x, y), SC$
n n Y BGSAVE
n n Y BREAK
n Y Y BREPEAT button ID[, start time, interval]
n n Y CALL parameter[, parameter...]
Y Y n CHRINIT character name
Y Y n CHRREAD (character name, character number), C$
Y Y n CHRSET character name, character number, graphic string
Y Y Y CLEAR
Y Y Y CLS
Y Y n COLINIT [color bank name[, color number] ]
Y Y Y COLOR number
n Y Y COLOR number, number
Y Y n COLREAD (color bank name, color number), variableR, variableG, variableB
Y Y n COLSET color bank name, color number, color data string
Y Y Y CONT
n n Y CONTINUE
Y Y Y DATA data[, data...]
n n Y DEC variable[, value]
Y Y Y DELETE string
n n Y DEF FunctionName [parameter1[, parameter2...] ]
Y Y Y DIM variable1(dimension 1[, dimension 2])[, variable2(dimension3[, dimension4])...]
Y Y n DTREAD (string), variableY, variableM, variableD
n n Y DTREAD [string] OUT variableY, variableM, variableD
Y Y Y END
Y Y Y EXEC string
Y Y Y FILES [resource name[, resource name...] ]
n n Y FONTDEF number, parameter
Y Y Y FOR numerical variable = numerical value TO numerical expression [STEP numerical expression]
Y Y Y GBOX x1, y1, x2, y2[, color]
Y Y Y GCIRCLE x, y, radius[, color[, initial angle, final angle] ]
Y Y Y GCLS [color]
Y Y Y GCOLOR color number
n Y Y GCOPY [transfer page,] start point x, start point y, end point x, end point y, transfer destination x, transfer destination y, copy mode
n Y n GDRAWMD status
Y Y Y GFILL x1, y1, x2, y2[, color]
Y Y Y GLINE x1, y1, x2, y2[, color]
n n Y GLOAD
Y Y Y GOSUB @label
n Y Y GOSUB string
Y Y Y GOTO @label
n Y Y GOTO string
Y Y n GPAGE screen[, drawing page, display screen]
n n Y GPAGE parameter 1, parameter 2
Y Y Y GPAINT x, y[, color[, border color] ]
n Y Y GPRIO number
Y Y Y GPSET x, y[, color]
Y Y n GPUTCHR x, y, character name, number, palette number, scale
n n Y GSAVE
n n Y GYROSYNC
n n Y GYROV (), variableY, variableP, variableR
Y Y n ICONCLR [icon position]
Y Y n ICONSET icon position, icon number
Y Y n IF numerical value GOTO label [ELSE command(s)]
Y Y Y IF numerical value THEN label [ELSE command(s)]
Y Y Y IF numerical value THEN command(s) [ELSE command(s)]
n n Y INC variable[, value]
Y Y Y INPUT [string;] variable[, variable...]
Y Y Y KEY number, string
Y Y Y LINPUT [string;] string variable
Y Y Y LIST [line number]
Y Y Y LIST @label
n n Y LIST [0-3:][line number]
n n Y LIST [0-3:] @label
Y Y Y LOAD string[, display control]
Y Y Y LOCATE x,y
n n Y LOCATE x,y,z
n n Y MICSAVE
n n Y MICSTART
n n Y MICSTOP
n n Y MPEND
n n Y MPRECV
n n Y MPSEND
n n Y MPSET
n n Y MPSTART
Y Y Y NEW
n n Y NEW [0-3]
Y Y Y NEXT [variable]
Y Y Y ON numerical value GOTO label[, label...]
Y Y Y ON numerical value GOSUB label[, label...]
n n Y OPTION parameter
Y Y n PNLSTR x coordinate, y coordinate, string[, palette number]
Y Y n PNLTYPE panel name
n n Y PRGDEL
n n Y PRGGET
n n Y PRGINS string
n n Y PRGSET string
Y Y Y PRINT value[; value[, value...] ]
n n Y PROJECT parameter
n n Y PUSH parameter, parameter
Y Y Y READ variable 1[, variable 2...]
n Y n REBOOT
Y Y n RECVFILE string
Y Y Y REM [comment]
Y Y Y RENAME string 1, string 2
n n Y REPEAT
Y Y Y RESTORE @label
n Y Y RESTORE string
Y Y Y RETURN
n n Y RETURN parameter
n Y Y RSORT start point, number of elements, array 1[, array 2...]
Y Y Y RUN
n n Y RUN 0-3
Y Y Y SAVE string
n Y Y SAVE string, string
n n Y SAVE string, string, array
n n Y SCROLL number, number
Y Y n SENDFILE string
n Y Y SORT start point, number of elements, array 1[, array 2...]
Y Y n SPANGLE control number, angle[, interpolation time, change direction]
Y Y Y SPANIM control number, number of frames, time[, loop]
Y Y Y SPCHR control number, sprite character number
Y Y n SPCHR control number, sprite character number, palette number, horizontal rotation, vertical rotation, order of precedence
n n Y SPCHR control number, sprite character number, template x, template y[, horizontal rotation, vertical rotation], attribute
n n Y SPCHR control number, OUT, sprite character number, template x, template y[, horizontal rotation, vertical rotation][, attribute]
n n Y SPCLIP
Y Y Y SPCLR [control number]
n Y n SPCOL control number, x, y, w, h, scale adjustment[, group]
n n Y SPCOL control number[, x, y, w, h][,[ scale adjustment][, group]]
n n Y SPCOLOR
n Y Y SPCOLVEC control number[, displacement x, displacement y]
n n Y SPDEF
n n Y SPHIDE control number
n Y Y SPHOME control number, x, y
n n Y SPLINK number, number
Y Y Y SPOFS control number, x, y[, interpolation time]
n n Y SPOFS control number, x, y, z[, interpolation time]
Y Y Y SPPAGE screen
n Y n SPREAD (control number), X, Y[, A, S, C]
n n Y SPROT value1, value2
Y Y Y SPSCALE control number, scale[, interpolation time]
Y Y Y SPSET control number, sprite character number, palette number, horizontal rotation, vertical rotation, order of precedence[, width, height]
n Y n SPSETV control number, variable number, value
n n Y SPSTART
n n Y SPSTOP
n n Y SPUNLINK
n n Y SPVAR
n n Y STICK
n n Y STICKEX
Y Y Y STOP
n Y Y SWAP variable, variable
n J Y TALK string[, string... ]
n J Y TALKSTOP
Y Y n TMREAD (string), variableH, variableM, variableS
n n Y TMREAD [string] OUT variableH, variableM, variableS
n n Y TOUCH
n n Y UNSHIFT parameter, parameter
n n Y UNTIL boolean condition
n n Y VAR parameter[, parameter...]
Y Y n VISIBLE console, panel, BG0, BG1, SPRITE, 256 color graphics
n n Y VISIBLE number, number, number, number
Y Y Y VSYNC frame number
n Y Y WAIT frame number
n n Y WEND
n n Y WHILE boolean condition
n n Y XOFF parameter
n n Y XON parameter
n n Y XSCREEN number[, number, number]
Y Y Y Assignment
n Y Y ? (PRINT)
Y Y Y ' (REM)

The first three columns indicate whether the command is implemented in the corresponding version of SmileBasic: "Y" indicates the command is implemented, "n" indicates it is not, "J" indicates the command works in the Japanese release of Petit Computer, but not for the North American release.

List of TermsEdit

  • Control Number - Control numbers are identification numbers that are used to refer to the sprite after it is created with SPSET.

OthersEdit

  • ACLS was not present in V3 at Tokyo Game Show 2014 (demo version), but many people became confused without ACLS. The release version re-adds ACLS and BACKTRACE.
  • GTRI (paint to triangle graphic) and PRGLINE (maybe about program generating) were removed on release version of V3.

External LinkEdit

Start a Discussion Discussions about List of Commands

Around Wikia's network

Random Wiki