0% found this document useful (0 votes)
69 views4 pages

Coding Notes

This document provides an overview of the key functions and properties available in the Game Lab environment for building games and simulations. It covers topics like drawing, sprites, groups, control flow, math operations, variables and functions.

Uploaded by

Aditya Ahuja
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
69 views4 pages

Coding Notes

This document provides an overview of the key functions and properties available in the Game Lab environment for building games and simulations. It covers topics like drawing, sprites, groups, control flow, math operations, variables and functions.

Uploaded by

Aditya Ahuja
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

Game Lab

function draw() {}
drawSprites()
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
playSound()
stopSound()
playSpeech()
keyDown()
keyWentDown()
keyWentUp()
mouseDidMove()
mouseDown()
mouseIsOver()
mouseWentDown()
mouseWentUp()
mousePressedOver()
[Link]()
[Link]()
[Link]
[Link]
[Link]
camera.x
camera.y
[Link]
comment
[Link]
Sprites
var sprite = createSprite()
createEdgeSprites()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]
[Link]
[Link]()
[Link]()
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
[Link]
sprite.x
sprite.y
comment
[Link]
Groups
var group = createGroup()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
comment
Drawing
background()
fill()
noFill()
stroke()
strokeWeight()
rgb()
noStroke()
arc()
ellipse()
line()
point()
rect()
regularPolygon()
shape()
text()
textAlign()
textFont()
textSize()
comment
Control
comment
For loop
While loop
If statement
If/else statement
getTime()
setTimeout()
clearTimeout()
setInterval()
clearInterval()
Math
comment
Add Operator
Subtract operator
Multiply operator
Divide operator
Equality operator
Inequality operator
Greater than operator
Greater than or equal operator
Less than operator
Less than or equal operator
And Operator
Or operator
Not operator
randomNumber()
randomNumber min/max
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
[Link]()
Modulo operator
Variables
comment
Assign x
[Link]()
Declare and assign an array to a variable
Declare and assign an array to a variable
Declare and assign a string to a variable
Declare and assign a value to a variable
Declare a variable
strincludes()
[Link]()
strlength
[Link]
[Link]()
[Link]()
[Link]()
Functions
Define a function
Define a function with parameters
Call a function
Call a function with parameters
return
Comment

You might also like