test1.nim 411 B

1234567891011121314151617
  1. # --- Test 1. Create a window and set up the main scene. --- #
  2. import nodesnim
  3. var
  4. window = newWindow(
  5. "hello world", # window title
  6. 640, # window width
  7. 360 # window height
  8. )
  9. main: SceneObj
  10. main_scene = Scene("Main", main) # create a new scene.
  11. window.setMainScene(main_scene)
  12. # ^ Try to remove the line above and see what happens
  13. window.launch() # start main loop