Wiki

Clone wiki

Core / kidvar

After we moved Spritey around I put things back the way we had them.

-- Use this function to perform your initial setup
function setup()
    print("Hello World!")
end

-- This function gets called once every frame
function draw()
    -- This sets the background color to black
    background(0, 0, 0)
    -- Do your drawing here
    sprite("SpaceCute:Background",374,374)
    sprite("Planet Cute:Character Boy",100,100)
end

First add two lines up top...

-- Use this function to perform your initial setup
function setup()
spx = 100 -- Spritey x
spy = 100 -- Spritey y
print("Hello World!")
end

...and we will change one line in the bottom...

sprite("Planet Cute:Character Boy",spx,spy)

Now play.

Spritey is in the same place.

Now you can move Spritey around like we did in Go, Spritey, Go like this:

spx = 200 -- Spritey x

I Think Spritey wants to go for a run

Updated