use main.m and SDL_main functionality

This commit is contained in:
Alex Zenla
2024-09-03 05:00:28 -04:00
parent e4194ff2ec
commit b0ccd3b335
5 changed files with 29 additions and 16 deletions

View File

@ -0,0 +1,17 @@
import Foundation
@objc public class Program: NSObject {
@objc public static func run() -> Int32 {
Thread.current.qualityOfService = .userInteractive
let app = Application(
delegate: Game(),
configuration: ApplicationConfiguration(
frame: Size(1280, 720),
title: "Voxelotl Demo",
flags: [ .resizable, .highDPI ],
vsyncMode: .on(interval: 1)))
return app.run()
}
}