Discord
Login
Community
DARK THEME

Can I change the black bars?

Is it possible to change the black bars to an image or a different color? Is it possible to draw over it too?

Provide more details about what you want to do.

Look at this projects

https://microstudio.dev/i/JimB007/spritefunctions2/

https://microstudio.dev/i/TinkerSmith/spritegenerator2/

the black bars when the game is set to have a certains ration and you have more space than the game can take

When you start the MicroScript program, a canva is created with parameters taken from the project settings.

You can't exit this canva.

The only idea I have is to put something under this canva (add the canva to the document).

Maybe in your case it will be enough to change the project parameters and select "free" in the graphic settings.

it doesn't work.

get_canvas = function()
  system.javascript("""
    global.window = window
    global.canvas = window.player.runtime.screen.canvas
    global.context = global.canvas.getContext("2d")
  """)  
end

init = function()
  get_canvas()
end

update = function()
end

draw = function()
  context.fillStyle = "green"
  context.fillRect( 0, 0, canvas.width, canvas.height)
 // screen.clear(999)
end

Post a reply

Progress

Status

Preview
Cancel
Post
Validate your e-mail address to participate in the community